{"id":16724288,"url":"https://github.com/badboy/rustup-version-name","last_synced_at":"2025-10-23T20:12:01.029Z","repository":{"id":57665833,"uuid":"54752836","full_name":"badboy/rustup-version-name","owner":"badboy","description":"rustup toolchain override in your prompt","archived":false,"fork":false,"pushed_at":"2018-03-03T22:55:46.000Z","size":11,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-10T06:22:45.270Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/badboy.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-03-25T23:18:28.000Z","updated_at":"2019-04-17T23:49:33.000Z","dependencies_parsed_at":"2022-09-14T13:01:53.420Z","dependency_job_id":null,"html_url":"https://github.com/badboy/rustup-version-name","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/badboy%2Frustup-version-name","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/badboy%2Frustup-version-name/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/badboy%2Frustup-version-name/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/badboy%2Frustup-version-name/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/badboy","download_url":"https://codeload.github.com/badboy/rustup-version-name/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248199079,"owners_count":21063641,"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":[],"created_at":"2024-10-12T22:44:41.310Z","updated_at":"2025-10-23T20:11:55.979Z","avatar_url":"https://github.com/badboy.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# rustup-version-name\n\nShow the used Rust toolchain version name for the current working directory.\n\nIf you use [rustup](https://github.com/rust-lang-nursery/rustup.rs)\nyou may have toolchain overrides for certain directories.\nSometimes it is good to see which one that is.\nPut it in your prompt and it is there when you need to know.\n\n\n## Install\n\n```\ncargo install --git https://github.com/badboy/rustup-version-name\n```\n\n## Use\n\n```\nrustup-version-name\n```\n\n## Use in shell prompt\n\nAdd the following function to your `.bashrc` or `.zshrc`:\n\n```shell\n__rust_prompt() {\n  local rustp=$(rustup-version-name)\n  if [ -n \"$rustp\"  ] \u0026\u0026 [ \"$rustp\" != \"default\"  ]\n  then\n    echo \" $rustp\"\n  fi\n}\n```\n\nAdd the function to your `PS1`:\n\n```shell\nPS1=\"[%~\\$(__rust_prompt)%# \"\n```\n\nRestart your shell and your done.\n\n## Todo\n\n* Search for override in upper directory.\n\n## License\n\n[MIT](LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbadboy%2Frustup-version-name","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbadboy%2Frustup-version-name","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbadboy%2Frustup-version-name/lists"}