Skip to content

Instantly share code, notes, and snippets.

@TheBigRoomXXL
Last active September 14, 2023 12:11
Show Gist options
  • Save TheBigRoomXXL/6b23edb7d0e815fd466f1eb600d496b3 to your computer and use it in GitHub Desktop.
Save TheBigRoomXXL/6b23edb7d0e815fd466f1eb600d496b3 to your computer and use it in GitHub Desktop.
Git shortcut
#!/bin/bash
`
add () {
git add .
}
commit () {
git commit -m "$1"
}
feat () {
git commit -m "feat: $1"
}
fix () {
git commit -m "fix: $1"
}
refacto () {
git commit -m "refacto: $1"
}
misc () {
git commit -m "misc: $1"
}
ci () {
git commit -m "ci: $1"
}
doc () {
git commit -m "doc: $1"
}
amend () {
if [[ $# -eq 1 ]]
then
git commit --amend --no-edit -m "$1"
else
git commit --amend --no-edit
fi
}
test-ci () {
git add .
git commit --amend --no-edit
git push -f
}
push () {
git push
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment