Skip to content

Commit

Permalink
Add 'git add' and 'git commit' function and alias that uses positiona…
Browse files Browse the repository at this point in the history
…l parameters
  • Loading branch information
Phundamentals committed Feb 4, 2025
1 parent 64305a8 commit 76647f9
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions Bash/bashrc
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ alias ga='git add'
alias ga.='ga .'
alias gc='git commit'
alias gc.='ga. && gc -m'
alias gac='gitAddCommit'
alias gca.='ga. && gc --amend'
alias gr='git rebase --committer-date-is-author-date'
alias grc='git rebase --continue'
Expand All @@ -61,6 +62,11 @@ alias gsw-m='gsw main'
alias gsw-d='gsw develop'
alias gsw-l='gsw local-changes'

gitAddCommit() {
git add "${@:1:$#-1}";
git commit -m "${@:$#}";
}

#
# Git Flow
#
Expand Down

0 comments on commit 76647f9

Please sign in to comment.