git push를 자동화 하기 위한 간단한 스크립트 파일입니다.
git init, git remote add 후에 사용하시면 됩니다.
ex) homepage_gitpush.sh
.bashrc 파일 수정
# Git Access Info
export env_github_id="Github ID" # ex) "abc"
export env_github_Token="Gitgub Access Token" # ex) "etiwajiojtiojio@#$"
#
# Git remote Address
export env_Project_Name_git="github.com/Address" # ex) "github.com/hunmin815/Git-Automation.git"
#
# SourceDir
export env_Project_Name_Dir="Source OR Project Directory" # ex) "/home/ubuntu/Git-Automation/"
#Project_Name 부분은 자신의 프로젝트명을 넣어주세요
ProjectName_gitPush.sh 파일 내 UserName, Project_name 수정이 필요합니다.
source /home/UserName/.bashrc # ex) source /home/ubuntu/.bashrc
Project_name="My Project Name" # ex) "Git-Automation"
logFile="/home/UserName/"$Project_name"_push.log" # ex) logFile="/home/ubuntu/"$Project_name"_push.log"./ProjectName_gitPush.shCommit 메세지 작성 시 Type을 선택 할 수 있게 되었습니다.
===== Choose Commit Type =====
1. Create
2. Chore
3. Docs
4. Feat
5. Fix
6. Refactor
7. Style
8. Update
9. Enter it myself (custom)
Choose Number (ex. 1) : 3기존과 동일하게 ProjectName_gitPush.sh 스크립트를 실행시켜주시면 됩니다.
Commit Title을 직접 입력 할 수 있습니다.
Enter Commit Title : add Description========= push Start (Date : Sun Dec 12 03:20:48 KST 2021) =========
git add . ...
git status
===== Choose Commit Type =====
1. Create
2. Chore
3. Docs
4. Feat
5. Fix
6. Refactor
7. Style
8. Update
9. Enter it myself (custom)
Choose Number (ex. 1) : 3
3 is number.
[OK] Commit Type : Docs
Enter Commit Title : add Description
git commit -m Docs add Description
git push!
git push Success~!
========= push OK (Date : Sun Dec 12 03:20:48 KST 2021) =========