| title | Git extras |
|---|---|
| category | Git |
| intro | Quick reference to some utilities in the [git-extras](https://github.com/tj/git-extras) utilities. |
References
Git-flow
$ git feature myfeature switched to branch 'feature/rofl' $ ... $ git checkout develop $ git feature finish myfeature merging 'feature/rofl' into develop deleted branch 'feature/rofl'
Also git-bug and git-refactor.
Branches
$ git delete-merged-branches
# hint: do `git remote prune origin` after
$ git create-branch development
$ git delete-branch development
$ git fresh-branch gh-pagesInspecting
$ git summary # repo age, commits, active days, etc $ git info # shows information about the repo $ git effort # commits per file $ git commits-since # list commits since date $ git changelog # generate changelog since last tag
Github
$ git fork strongloop/express # sync your fork with the original repository: $ git remote add upstream https://github.com/ORIGINAL_OWNER/ORIGINAL_REPOSITORY.git $ git fetch upstream; git merge upstream/master
Tags
$ git release v1.0.0 # commit, tag, push-tags
$ git delete-tag v1.0.0Conveniences
$ git ignore "*.log" # append *.log to .gitignore $ git undo # undo the last local commit
Locking
Assumes that changes will not be committed.
$ git lock config/database.yml $ git unlock config/database.yml
Etc
$ git obliterate secret.yml # remove all references to it