https://github.com/jamieweavis/gitsu
🥷 Command line util for quickly & easily switching git identities
https://github.com/jamieweavis/gitsu
git gitconfig gitsu su switch switch-user switcher user
Last synced: about 1 year ago
JSON representation
🥷 Command line util for quickly & easily switching git identities
- Host: GitHub
- URL: https://github.com/jamieweavis/gitsu
- Owner: jamieweavis
- License: mit
- Created: 2022-05-23T15:25:27.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2025-04-05T15:40:11.000Z (about 1 year ago)
- Last Synced: 2025-04-05T15:46:50.652Z (about 1 year ago)
- Topics: git, gitconfig, gitsu, su, switch, switch-user, switcher, user
- Language: TypeScript
- Homepage: https://npm.im/gitsu-cli
- Size: 914 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# gitsu
> 🥷 Command line util for quickly & easily switching git identities
[](https://github.com/jamieweavis/gitsu/actions)
[](https://npmjs.com/package/gitsu-cli)
[](https://github.com/jamieweavis/gitsu/releases)
[](https://github.com/jamieweavis/gitsu/blob/main/LICENSE)

## Install
```sh
npm install gitsu-cli -g
```
## Usage
Open the `gitsu` switcher to select a user from your `~/.gitsurc` config
```sh
gitsu
```
List users stored in your `~/.gitsurc` config
```sh
gitsu --list
gitsu -l
```
Open your `~/.gitsurc` config for editing in your default editor
```sh
gitsu --edit
gitsu -e
```
## Building
Compiling a production build
```sh
npm run build
```
Running in development mode
```sh
npm run dev
```
Running a production build
```sh
npm start
```
## Linking
Link the local package to your global npm modules
```sh
npm link
```
Unlink the local package from your global npm modules
```sh
npm unlink gitsu-cli -g
```
## Config
When you run `gitsu` for the first time, a `.gitsurc` file is created in your home directory. This file is used to store your git identities.
```json
[
{ "name": "John", "email": "john.doe@gmail.com" },
{ "name": "John Doe", "email": "john.doe@corporate.com" },
{ "name": "Johnny", "email": "johnny@startup.io" }
]
```
## Built With
- [Node.js](https://github.com/nodejs/node)
- [TypeScript](https://github.com/microsoft/TypeScript)
- [Commander.js](https://github.com/tj/commander.js)
## License
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.