Code Monkey home page Code Monkey logo

git-switcher's Introduction

Build Status GitHub release (latest SemVer) GitHub Contributor Covenant

Git Switcher

Description

Overview

Global git config cannot keep a few usernames / emails, but sometimes it's necessary to use different git profiles and be able to quickly and easily switch between them. For this just need Git Switcher. The app stores user's git profiles (username & email pairs) and may switch it in global .gitconfig file in one command.

Technologies

Project is using C++ language, C++11 standard.

System requirements

  • OS: Windows x86 & x64, Linux x86 & x64
  • Software: make, g++, git

Installation

git clone https://github.com/XDragonSl/git-switcher.git
cd git-switcher
make all

You must run these commands as Administrator (Windows) or using sudo (Linux).

Windows version supports using both: command line tools and Git Bash, but for using via Git Bash, users must add the following line to %USERPROFILE%\.bash_profile file:

alias gsw="gsw.exe"

Just run the following command:

echo alias gsw="gsw.exe" >> $(USERPROFILE)\.bash_profile

or open the file (or create it) in a text editor and add the line manually.

Downloads

You could download precompiled binaries of prefered release.

Usage

App

Options:
        -v, --version:                                                  Display installed version
        -h, --help:                                                     Display help
        -c, --current:                                                  Display current user email       
        -l, --list:                                                     Display list of all user profiles
        -a, --add
                --name <name> --email <email>:                          Add new user profile
        -u, --update
                --number <number> --name <name> --email <email>:        Update existing user profile
        -s, --switch
                <number>:                                               Switch user profile
        -r, --remove
                <number>:                                               Remove user profile

Make targets

  • make - compile project (default: build folder)
  • make all - compile project, install app & clean up compiled output
  • make clean - clean up compiled output (project must be compiled earlier)
  • make install - install app (project must be compiled earlier)
  • make update - uninstall app, compile project, install app & clean up compiled output (app must be installed earlier)
  • make uninstall - uninstall app (app must be installed earlier)

Change log

CHANGELOG.md

Contacts

If you have any questions please don't hesitate to contact me [email protected]

Copyright

© 2020 Ermolenko V.A.

git-switcher's People

Contributors

xdragonsl avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.