{"id":24915613,"url":"https://github.com/bachp/git-credential-rs","last_synced_at":"2025-10-03T21:07:07.746Z","repository":{"id":35074048,"uuid":"203669291","full_name":"bachp/git-credential-rs","owner":"bachp","description":"Crate that provides types that help to implement git-credential helpers","archived":false,"fork":false,"pushed_at":"2024-01-01T07:24:47.000Z","size":20,"stargazers_count":5,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-01-11T11:19:57.246Z","etag":null,"topics":["git","git-credential-helper","rust","rust-crate"],"latest_commit_sha":null,"homepage":null,"language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bachp.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE-APACHE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-08-21T21:48:40.000Z","updated_at":"2023-01-08T09:05:05.000Z","dependencies_parsed_at":"2022-08-08T06:00:16.628Z","dependency_job_id":null,"html_url":"https://github.com/bachp/git-credential-rs","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bachp%2Fgit-credential-rs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bachp%2Fgit-credential-rs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bachp%2Fgit-credential-rs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bachp%2Fgit-credential-rs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bachp","download_url":"https://codeload.github.com/bachp/git-credential-rs/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":236761999,"owners_count":19200705,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["git","git-credential-helper","rust","rust-crate"],"created_at":"2025-02-02T07:18:41.241Z","updated_at":"2025-10-03T21:07:02.696Z","avatar_url":"https://github.com/bachp.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Git Credential\n\n[![Build Status](https://img.shields.io/endpoint.svg?url=https%3A%2F%2Factions-badge.atrox.dev%2Fbachp%2Fgit-credential-rs%2Fbadge%3Fref%3Dmaster\u0026style=flat)](https://actions-badge.atrox.dev/bachp/git-credential-rs/goto?ref=master)\n[![Crate](https://img.shields.io/crates/v/git-credential.svg)](https://crates.io/crates/git-credential)\n[![API](https://docs.rs/git-credential/badge.svg)](https://docs.rs/git-credential)\n\nA Rust library that provides types that help to implement git-credential helpers.\n\n## Usage\n\nAdd this to your `Cargo.toml`:\n\n```toml\n[dependencies]\ngit-credential = \"*\"\n```\n\nThis crates provides types that are able to parse input and produce output in the format\ndescribed in [git-credential[1] ](https://git-scm.com/docs/git-credential).\n\nThe following shows an example on how create a `GitCredential` struct\nfrom an input, modify it and write it back to an output:\n\n```rust\nuse git_credential::GitCredential;\n\nlet input = \"username=me\\npassword=%sec\u0026ret!\\n\\n\".as_bytes();\nlet mut output: Vec\u003cu8\u003e = Vec::new();\n\nlet mut g = GitCredential::from_reader(input).unwrap();\n\nassert_eq!(g.username.unwrap(), \"me\");\nassert_eq!(g.password.unwrap(), \"%sec\u0026ret!\");\n\ng.username = Some(\"you\".into());\ng.password = Some(\"easy\".into());\n\ng.to_writer(\u0026mut output).unwrap();\n\nassert_eq!(\"username=you\\npassword=easy\\n\\n\", String::from_utf8(output).unwrap())\n```\n\nSee the [API documentation](https://docs.rs/git-credential) for more details.\n\n# License\n\nRand is distributed under the terms of both the MIT license and the\nApache License (Version 2.0).\n\nSee [LICENSE-APACHE](LICENSE-APACHE) and [LICENSE-MIT](LICENSE-MIT), and\n[COPYRIGHT](COPYRIGHT) for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbachp%2Fgit-credential-rs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbachp%2Fgit-credential-rs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbachp%2Fgit-credential-rs/lists"}