This repository contains a batch file that automates various GitHub processes to streamline your workflow.
- Initialze Git
- Commit changes
- Add remote repository
- Push changes to remote repositories
- Ensure you have Git installed on your machine. You can download it from here. To check if Git is installed, run:
git --version
- Install GitHub CLI from here. To check if GitHub CLI is installed, run:
gh --version
- Configure your GitHub credentials for seamless authentication.
- Clone this repository to your local machine.
- Move the repo directory to
C:\aliases
- Edit the
origin
section in the batch file to set your GitHub username and email:git remote add origin https://github.com/your_user_name/%1
- add this
C:\aliases
file to your Environment Variables - Run the batch file using the command prompt:
gitsetup repo_name commit_message --private/--public
- Done ✨
- Clone this repository to your local machine.
- cd into the cloned repo
- Edit gitsetup.sh and replace github_username with your username in
git remote add origin [email protected]:github_username/"$REPO_NAME".git
- Run
chmod +x gitsetup.sh
- Copy the gitsetup.sh script to your desired location, preferrably to the one where you keep all your scripts
- Add
export PATH=$PATH:/path/to/script
to your~/.bashrc
file if the location is not alredy part of your PATH - Run
source ~/.bashrc
- Now you can run the script from any location where you want to initialize a new github repository using
gitsetup.sh <repo-name> <commit-message> [--private|--public]
gitsetup test "first commit" --private
This project is licensed under the MIT License. See the LICENSE file for details.
Contributions are welcome! Please open an issue or submit a pull request.
For any questions or feedback, please contact [email protected].