How to automate creating a new project on Git

Ravali Peddi
2 min readNov 30, 2020

--

Usually when I am starting a new project, I find myself doing lot of steps repeatedly for every project.

  1. Open my terminal
  2. Navigate to the directory where I usually keep my projects. Make a new folder for the project. Go into that folder

3. Create a README.md file.

4. Initialize an empty GIT repository

5. Then go to Github and create new repository with same project name

6. Copy and run the above command in the terminal in project directory

7. Commit the README.md file as initial commit

8. And Finally push the commit to remote on master branch

So, to automate all the above steps, the shell script looks like:

Using python script to login to your git account, create repository

Clone this repository for the source code:

All you need to do is, clone the repo, cd into it. Add you filepath, github credentials in .env file and save it.
Run create <Your_project_name>. And Boom..! you are ready to rock with your new project folder also with a git repository

Sign up to discover human stories that deepen your understanding of the world.

Free

Distraction-free reading. No ads.

Organize your knowledge with lists and highlights.

Tell your story. Find your audience.

Membership

Read member-only stories

Support writers you read most

Earn money for your writing

Listen to audio narrations

Read offline with the Medium app

--

--

Ravali Peddi
Ravali Peddi

No responses yet

Write a response