See how a minor change to your commit message style can make you a better programmer.
Format: <type>(<scope>): <subject>
<scope> is optional
| import React, { Component, PropTypes } from 'react'; | |
| import htr from 'hooks-theme-refs'; | |
| export class Chip extends Component { | |
| render() { | |
| const { label, hooks, theme, refs, children, ...rest } = htr(this); | |
| return ( | |
| <div {...rest} className={theme.chip} onClick={hooks.onClick} ref={refs.chip}> | |
| {children} |
Jon Warbrick, July 2014, V3.2 (for Ansible 1.7)
First one found from of
| #!/bin/bash | |
| function deploy { | |
| # Update the rsync target on the server | |
| rsync \ | |
| -av \ | |
| --delete \ | |
| --delete-excluded \ | |
| $rsync_ignore_list_param \ | |
| $rsync_source/ $target:$rsync_target |
| # Hello, and welcome to makefile basics. | |
| # | |
| # You will learn why `make` is so great, and why, despite its "weird" syntax, | |
| # it is actually a highly expressive, efficient, and powerful way to build | |
| # programs. | |
| # | |
| # Once you're done here, go to | |
| # http://www.gnu.org/software/make/manual/make.html | |
| # to learn SOOOO much more. |
| #!/usr/bin/python | |
| """ | |
| This is a prepare-commit-msg hook for use with Jira | |
| Copy this file to $GITREPOSITORY/.git/hooks/prepare-commit-msg | |
| It will prepend PROJ-123 to your commit message, assuming your branch is | |
| named proj-123. | |
| """ |
| docker run -rm -t -i -v $(dirname $SSH_AUTH_SOCK) -e SSH_AUTH_SOCK=$SSH_AUTH_SOCK ubuntu /bin/bash |
| voices = %w[Agnes Alex Bruce Bubbles Fred Junior Kathy Princess Ralph Vicki Victoria] | |
| phrases = [ | |
| "We are the Borg.", | |
| "Lower your shields and surrender your ships.", | |
| "We will add your biological and technological distinctiveness to our own.", | |
| "Your culture will adapt to service us.", | |
| "Resistance is futile." | |
| ] |
Locate the section for your github remote in the .git/config file. It looks like this:
[remote "origin"]
fetch = +refs/heads/*:refs/remotes/origin/*
url = git@github.com:joyent/node.git
Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/* to this section. Obviously, change the github url to match your project's URL. It ends up looking like this: