As a developer, it's common to perform repetitive tasks like committing changes to your GitHub repository. This script helps automate the process by simplifying the steps required for committing files. No more typing the same Git commands repeatedly!
-
Copy the script file and place it inside a folder. For example, let's place it in: /home/miggy-pg/scripts
-
To use the script, you need to allow read and write permissions for the file. To do this, navigate to the directory where you have placed the script and use the
chmod
command. Replace<file_name.sh>
with the actual name of your script:
chmod +x <file_name.sh>
For instance:
chmod +x git_push.sh
- Now that you've set the permissions, you can use the bash script from your current working directory. Open your terminal and type:
~/scripts/git_push.sh
By using this script, you can save time and effort by automating the process of committing files to your GitHub repository. Happy coding!