|
You are here |
hjr265.me | ||
| | | | |
osc.garden
|
|
| | | | | In order to keep the 'Last updated' field of posts always accurate, I automated its modification with a custom Git pre-commit hook. | |
| | | | |
www.brandonpugh.com
|
|
| | | | | TLDR: Git hooks are an awesome way to automatically verify your code as you commit your changes I'm sure we've all been there where we accidentally committed a change that we were supposed to undo or wasn't ready to be pushed and don't realize it until the build breaks or QA finds a bug. The first step I take to avoid committing anything unintentionally is instead of just running git add -A I make sure to review all the changes in the files I'm potentially committing. This is where a graphical tool like Gitk or SmartGit comes in handy as they allow you to click on your modified files and easily view a diff and then select which changes to stage. Unfortunately changes still slip through as happened to me yesterday when a change of mine got pushed all the way ... | |
| | | | |
tarneo.fr
|
|
| | | | | Programming, Linux, self-hosting, ergo keyboards, IT ethics... | |
| | | | |
wittchen.io
|
|
| | | When you fork GitHub repository, you usually want to have your fork up to date with the original repository. You can update your fork in a few easy steps. Just look at the following example of the Git commands: Add the remote, call it upstream: git remote add upstream https://github.com/whoever/whatever.git Fetch all the branches of that remote into remote-tracking branches, such as upstream/master: git fetch upstream Make sure that you're on your master branch: | ||