From a347b2385769e1469b0dc8d5a1c9c3b14f6a8711 Mon Sep 17 00:00:00 2001 From: Ruslan Brest Date: Tue, 15 Apr 2014 10:27:54 +0300 Subject: [PATCH 01/26] Getting content of Pull Request in Diff or Patch format --- README.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/README.md b/README.md index eb15621..2b456f9 100644 --- a/README.md +++ b/README.md @@ -330,6 +330,18 @@ Using the *unfold* button in the gutter of a diff, you can reveal additional lin [*Read more about expanding context in diffs.*](https://github.com/blog/1705-expanding-context-in-diffs) +#### Getting content of Pull Request in Diff or Patch format + +You can get the diff of viewed pull request by adding `.diff` or `.patch` +to the end of URL. For example: + +* +* - the pull + request in DIFF format +* - the pull + request as PATCH + + ### Hub [Hub](https://github.com/github/hub) is a command line Git wrapper that gives you extra features and commands that make working with GitHub easier. From 2e4446fb6e634c9a2d92c89eba7740e523920588 Mon Sep 17 00:00:00 2001 From: Ruslan Brest Date: Tue, 15 Apr 2014 10:38:27 +0300 Subject: [PATCH 02/26] Add ToC entry for Getting content of Pull Request in Diff or Patch format --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 2b456f9..13a0481 100644 --- a/README.md +++ b/README.md @@ -27,6 +27,7 @@ A collection of cool hidden and not so hidden features of Git and GitHub. This c - [Rendered prose Diffs](#rendered-prose-diffs) - [Diffable Maps](#diffable-maps) - [Expanding Context in Diffs](#expanding-context-in-diffs) + - [Getting content of Pull Request in Diff or Patch format](#getting-content-of-pull-request-in-diff-or-patch-format) - [Hub](#hub) - [Decreasing Contributor Friction](#decreasing-contributor-friction) - [Contributing Guidelines](#contributing-guidelines) From 527cc25dd1a635302acf6659e9618f62d7e10aea Mon Sep 17 00:00:00 2001 From: Rafal Chmiel Date: Wed, 16 Apr 2014 10:07:02 +0100 Subject: [PATCH 03/26] Add some resources about Git (partly fixes #23) --- README.md | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/README.md b/README.md index 172bbe7..c69633c 100644 --- a/README.md +++ b/README.md @@ -43,6 +43,8 @@ A collection of cool hidden and not so hidden features of Git and GitHub. This c - [Aliases](#aliases) - [Auto-Correct](#auto-correct) - [Color](#color) + - [Git Resources](#git-resources) + - [Git Books](#git-books) ## GitHub ### Ignore Whitespace @@ -603,3 +605,29 @@ $ git config --global color.ui 1 ``` [*Read more about the Git `config` command.*](http://git-scm.com/docs/git-config) + +### Git Resources +| Title | Link | +| ----- | ---- | +| Official Git Site | http://git-scm.com/ | +| Official Git Video Tutorials | http://git-scm.com/videos | +| Code School Try Git | http://try.github.com/ | +| Introductory Reference & Tutorial for Git | http://gitref.org/ | +| Official Git Tutorial | http://git-scm.com/docs/gittutorial | +| Everyday Git | http://git-scm.com/docs/everyday | +| Git Immersion | http://gitimmersion.com/ | +| Ry's Git Tutorial | http://rypress.com/tutorials/git/index.html | +| Git for Designer | http://hoth.entp.com/output/git_for_designers.html | +| Git for Computer Scientists | http://eagain.net/articles/git-for-computer-scientists/ | +| Git Magic | http://www-cs-students.stanford.edu/~blynn/gitmagic/ | + +#### Git Books +| Title | Link | +| ----- | ---- | +| Pragmatic Version Control Using Git | http://www.pragprog.com/titles/tsgit/pragmatic-version-control-using-git | +| Pro Git | http://git-scm.com/book | +| Git Internals Peepcode | http://peepcode.com/products/git-internals-pdf | +| Git in the Trenches | http://cbx33.github.com/gitt/ | +| Version Control with Git | http://www.amazon.com/Version-Control-Git-collaborative-development/dp/1449316387 | +| Pragmatic Guide to Git | http://www.pragprog.com/titles/pg_git/pragmatic-guide-to-git | +| Git: Version Control for Everyone | http://www.packtpub.com/git-version-control-for-everyone/book | From ad99cf9c5e4bdf1cd5aa410baad18e53dfa12474 Mon Sep 17 00:00:00 2001 From: Rafal Chmiel Date: Wed, 16 Apr 2014 10:10:09 +0100 Subject: [PATCH 04/26] Add some GitHub resources (#23) --- README.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/README.md b/README.md index c69633c..32562db 100644 --- a/README.md +++ b/README.md @@ -30,6 +30,7 @@ A collection of cool hidden and not so hidden features of Git and GitHub. This c - [Hub](#hub) - [Decreasing Contributor Friction](#decreasing-contributor-friction) - [Contributing Guidelines](#contributing-guidelines) + - [GitHub Resources](#github-resources) - [Git](#git) - [Previous Branch](#previous-branch) - [Checking out Pull Requests](#checking-out-pull-requests) @@ -363,6 +364,15 @@ Adding a `CONTRIBUTING` file to the root of your repository will add a link to y [*Read more about contributing guidelines.*](https://github.com/blog/1184-contributing-guidelines) +### GitHub Resources +| Title | Link | +| ----- | ---- | +| GitHub Explore | https://github.com/explore | +| GitHub Blog | https://github.com/blog | +| GitHub Help | https://help.github.com/ | +| GitHub Training | http://training.github.com/ | +| GitHub Developer | https://developer.github.com/ | + ## Git ### Previous Branch To move to the previous branch in Git: From b5a872a88c784c1658f193220ada1e4e8159265e Mon Sep 17 00:00:00 2001 From: Rafal Chmiel Date: Wed, 16 Apr 2014 10:16:29 +0100 Subject: [PATCH 05/26] Add links to talks about GitHub --- README.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/README.md b/README.md index 32562db..cb743f6 100644 --- a/README.md +++ b/README.md @@ -31,6 +31,7 @@ A collection of cool hidden and not so hidden features of Git and GitHub. This c - [Decreasing Contributor Friction](#decreasing-contributor-friction) - [Contributing Guidelines](#contributing-guidelines) - [GitHub Resources](#github-resources) + - [GitHub Talks](#github-talks) - [Git](#git) - [Previous Branch](#previous-branch) - [Checking out Pull Requests](#checking-out-pull-requests) @@ -373,6 +374,11 @@ Adding a `CONTRIBUTING` file to the root of your repository will add a link to y | GitHub Training | http://training.github.com/ | | GitHub Developer | https://developer.github.com/ | +#### GitHub Talks +| Title | Link | +| ----- | ---- | +| How GitHub Uses GitHub to Build GitHub | https://www.youtube.com/watch?v=qyz3jkOBbQY | + ## Git ### Previous Branch To move to the previous branch in Git: From 0508be9ea701647b85f9d2df5705215bafdd9e36 Mon Sep 17 00:00:00 2001 From: Rafal Chmiel Date: Wed, 16 Apr 2014 10:17:12 +0100 Subject: [PATCH 06/26] Add link to talk about GH --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index cb743f6..b104d74 100644 --- a/README.md +++ b/README.md @@ -378,6 +378,7 @@ Adding a `CONTRIBUTING` file to the root of your repository will add a link to y | Title | Link | | ----- | ---- | | How GitHub Uses GitHub to Build GitHub | https://www.youtube.com/watch?v=qyz3jkOBbQY | +| Introduction to Git with Scott Chacon of GitHub | https://www.youtube.com/watch?v=ZDR433b0HJY | ## Git ### Previous Branch From 2b84ae8ed0bb98eef67904a9d8b3fbb8764d6b9c Mon Sep 17 00:00:00 2001 From: Rafal Chmiel Date: Wed, 16 Apr 2014 10:18:57 +0100 Subject: [PATCH 07/26] Add one more talk --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index b104d74..1586d74 100644 --- a/README.md +++ b/README.md @@ -379,6 +379,7 @@ Adding a `CONTRIBUTING` file to the root of your repository will add a link to y | ----- | ---- | | How GitHub Uses GitHub to Build GitHub | https://www.youtube.com/watch?v=qyz3jkOBbQY | | Introduction to Git with Scott Chacon of GitHub | https://www.youtube.com/watch?v=ZDR433b0HJY | +| How GitHub No Longer Works | https://www.youtube.com/watch?v=gXD1ITW7iZI | ## Git ### Previous Branch From 350635573cc96c0e7c2a0bb5b506593eeb4e0785 Mon Sep 17 00:00:00 2001 From: Rafal Chmiel Date: Wed, 16 Apr 2014 10:20:13 +0100 Subject: [PATCH 08/26] Add talks by @holman --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 1586d74..a532e49 100644 --- a/README.md +++ b/README.md @@ -380,6 +380,8 @@ Adding a `CONTRIBUTING` file to the root of your repository will add a link to y | How GitHub Uses GitHub to Build GitHub | https://www.youtube.com/watch?v=qyz3jkOBbQY | | Introduction to Git with Scott Chacon of GitHub | https://www.youtube.com/watch?v=ZDR433b0HJY | | How GitHub No Longer Works | https://www.youtube.com/watch?v=gXD1ITW7iZI | +| Git and GitHub Secrets | https://www.youtube.com/watch?v=Foz9yvMkvlA | +| More Git and GitHub Secrets | https://www.youtube.com/watch?v=p50xsL-iVgU | ## Git ### Previous Branch From cb6d09422ab9cbaa1227fc8e59a8d82a4b31b83f Mon Sep 17 00:00:00 2001 From: Rafal Chmiel Date: Wed, 16 Apr 2014 10:26:40 +0100 Subject: [PATCH 09/26] Add Gists screenshot --- README.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index a532e49..770ef54 100644 --- a/README.md +++ b/README.md @@ -111,7 +111,11 @@ https://github.com/rails/rails/compare/byroot:idempotent-counter-caches...master ``` ### Gists -[Gists](https://gist.github.com/) are an easy way to work with small bits of code without creating a fully fledged repository. Add `.pibb` to the end of any Gist URL ([like this](https://gist.github.com/tiimgreen/10545817.pibb)) in order to get the *HTML only* version suitable for embedding in any other site. +[Gists](https://gist.github.com/) are an easy way to work with small bits of code without creating a fully fledged repository. + +![Gist](http://i.imgur.com/VkKI1LC.png?1) + +Add `.pibb` to the end of any Gist URL ([like this](https://gist.github.com/tiimgreen/10545817.pibb)) in order to get the *HTML only* version suitable for embedding in any other site. Gists can be treated as a full repository so they can be cloned like any other: From 97a5328a1bf101c704596f943db85a3d01624ded Mon Sep 17 00:00:00 2001 From: Rafal Chmiel Date: Wed, 16 Apr 2014 10:28:43 +0100 Subject: [PATCH 10/26] Add Git.io screenshot example --- README.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 770ef54..e0afcae 100644 --- a/README.md +++ b/README.md @@ -128,7 +128,11 @@ $ git clone https://gist.github.com/tiimgreen/10545817 [*Read more about creating gists.*](https://help.github.com/articles/creating-gists) ### Git.io -[Git.io](http://git.io) is a simple URL shortener for GitHub. You can also use it via pure HTTP using Curl: +[Git.io](http://git.io) is a simple URL shortener for GitHub. + +![Git.io](http://i.imgur.com/6JUfbcG.png?1) + +You can also use it via pure HTTP using Curl: ```bash $ curl -i http://git.io -F "url=https://github.com/..." From ef29a1322e42cff2f40846dbd9df95b5467abc63 Mon Sep 17 00:00:00 2001 From: Rafal Chmiel Date: Wed, 16 Apr 2014 10:30:10 +0100 Subject: [PATCH 11/26] Add keyboard screenshot example --- README.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index e0afcae..d0579ce 100644 --- a/README.md +++ b/README.md @@ -155,7 +155,9 @@ When on a repository page, keyboard shortcuts allow you to navigate easily. - Pressing `l` will edit labels on existing Issues. - Pressing `y` **when looking at a file** (e.g. `https://github.com/tiimgreen/github-cheat-sheet/blob/master/README.md`) will change your URL to one which, in effect, freezes the page you are looking at. If this code changes, you will still be able to see what you saw at that current time. -To see all of the shortcuts for the current page press `?`. +To see all of the shortcuts for the current page press `?`: + +![Keyboard shortcuts](http://i.imgur.com/y5ZfNEm.png) [*Read more about using the Command Bar.*](https://help.github.com/articles/using-the-command-bar) From ac15804c9a0b7ce3c8e422bbab9ad969fe5cb82d Mon Sep 17 00:00:00 2001 From: Rafal Chmiel Date: Wed, 16 Apr 2014 10:33:51 +0100 Subject: [PATCH 12/26] Add compare branch example --- README.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/README.md b/README.md index d0579ce..85a23ed 100644 --- a/README.md +++ b/README.md @@ -82,10 +82,13 @@ https://github.com/user/repo/compare/{range} Where `{range} = master...4-1-stable` For example: + ``` https://github.com/rails/rails/compare/master...4-1-stable ``` +![Rails branch compare example](http://i.imgur.com/0Z52X5Y.png) + `{range}` can be changed to things like: ``` From 3d24fe74dee2e48ba85d66228d36739a82d24a89 Mon Sep 17 00:00:00 2001 From: Rafal Chmiel Date: Wed, 16 Apr 2014 10:36:45 +0100 Subject: [PATCH 13/26] Add commit history example --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 85a23ed..cb0f6fa 100644 --- a/README.md +++ b/README.md @@ -61,6 +61,8 @@ To view all commits on a repo by author add `?author=username` to the URL. https://github.com/rails/rails/commits/master?author=dhh ``` +![DHH commit history](http://i.imgur.com/mDWwuaY.png) + [*Read more about the differences between commits views.*](https://help.github.com/articles/differences-between-commit-views) ### Cloning a Repository From 957019cfed90d9d1ca5bda940bf2e4c176ca399f Mon Sep 17 00:00:00 2001 From: Rafal Chmiel Date: Wed, 16 Apr 2014 10:38:41 +0100 Subject: [PATCH 14/26] Add example forked repo compare --- README.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index cb0f6fa..6c91950 100644 --- a/README.md +++ b/README.md @@ -112,9 +112,11 @@ https://github.com/user/repo/compare/{foreign-user}:{branch}...{own-branch} For example: ``` -https://github.com/rails/rails/compare/byroot:idempotent-counter-caches...master +https://github.com/rails/rails/compare/byroot:master...master ``` +![Forked branch compare](http://i.imgur.com/Q1W6qcB.png) + ### Gists [Gists](https://gist.github.com/) are an easy way to work with small bits of code without creating a fully fledged repository. From 9274e6222e1a7030144fe04989c02d15a3452000 Mon Sep 17 00:00:00 2001 From: Rafal Chmiel Date: Wed, 16 Apr 2014 10:42:49 +0100 Subject: [PATCH 15/26] Add another branch compare example --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 6c91950..84cfc42 100644 --- a/README.md +++ b/README.md @@ -98,6 +98,8 @@ https://github.com/rails/rails/compare/master@{1.day.ago}...master https://github.com/rails/rails/compare/master@{2014-10-04}...master ``` +![Another compare example](http://i.imgur.com/5dtzESz.png) + ...which allows you to see the difference on the master branch up a set time ago or a specified date. [*Read more about comparing commits across time.*](https://help.github.com/articles/comparing-commits-across-time) From 3ce96f8e1ca8d7f5b739ca904b74d934e1a5e5ad Mon Sep 17 00:00:00 2001 From: Rafal Chmiel Date: Wed, 16 Apr 2014 10:49:25 +0100 Subject: [PATCH 16/26] Improve recently merged section --- README.md | 33 ++++++++++++++++++++++++++------- 1 file changed, 26 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 1e3f466..0b7a18f 100644 --- a/README.md +++ b/README.md @@ -355,16 +355,35 @@ Using the *unfold* button in the gutter of a diff, you can reveal additional lin [*Read more about expanding context in diffs.*](https://github.com/blog/1705-expanding-context-in-diffs) #### Getting content of Pull Request in Diff or Patch format +You can get the diff of a Pull Request by adding a `.diff` or `.patch` +extension to the end of the URL. For example: -You can get the diff of viewed pull request by adding `.diff` or `.patch` -to the end of URL. For example: +``` +https://github.com/tiimgreen/github-cheat-sheet/pull/15 +https://github.com/tiimgreen/github-cheat-sheet/pull/15.diff +https://github.com/tiimgreen/github-cheat-sheet/pull/15.patch +``` -* -* - the pull - request in DIFF format -* - the pull - request as PATCH +The `.diff` extension would give you this in plain text: +``` +diff --git a/README.md b/README.md +index 88fcf69..8614873 100644 +--- a/README.md ++++ b/README.md +@@ -28,6 +28,7 @@ All the hidden and not hidden features of Git and GitHub. This cheat sheet was i + - [Merged Branches](#merged-branches) + - [Quick Licensing](#quick-licensing) + - [TODO Lists](#todo-lists) ++- [Relative Links](#relative-links) + - [.gitconfig Recommendations](#gitconfig-recommendations) + - [Aliases](#aliases) + - [Auto-correct](#auto-correct) +@@ -381,6 +382,19 @@ When they are clicked, they will be updated in the pure Markdown: + - [ ] Sleep + +(...) +``` ### Hub [Hub](https://github.com/github/hub) is a command line Git wrapper that gives you extra features and commands that make working with GitHub easier. From 404f919b70e9f44da0e30c9b215e86908ea9bd40 Mon Sep 17 00:00:00 2001 From: Rafal Chmiel Date: Wed, 16 Apr 2014 10:50:16 +0100 Subject: [PATCH 17/26] Change title of one section --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 0b7a18f..93bcbd1 100644 --- a/README.md +++ b/README.md @@ -27,7 +27,7 @@ A collection of cool hidden and not so hidden features of Git and GitHub. This c - [Rendered prose Diffs](#rendered-prose-diffs) - [Diffable Maps](#diffable-maps) - [Expanding Context in Diffs](#expanding-context-in-diffs) - - [Getting content of Pull Request in Diff or Patch format](#getting-content-of-pull-request-in-diff-or-patch-format) + - [Diff or Patch of Pull Request](#diff-or-patch-of-pull-request) - [Hub](#hub) - [Decreasing Contributor Friction](#decreasing-contributor-friction) - [Contributing Guidelines](#contributing-guidelines) @@ -354,7 +354,7 @@ Using the *unfold* button in the gutter of a diff, you can reveal additional lin [*Read more about expanding context in diffs.*](https://github.com/blog/1705-expanding-context-in-diffs) -#### Getting content of Pull Request in Diff or Patch format +#### Diff or Patch of Pull Request You can get the diff of a Pull Request by adding a `.diff` or `.patch` extension to the end of the URL. For example: From cb5058e2b60b537861670c96ec4eaef247f957c4 Mon Sep 17 00:00:00 2001 From: Rafal Chmiel Date: Wed, 16 Apr 2014 12:15:08 +0100 Subject: [PATCH 18/26] Add 'CI Status on Pull Requests' section (fixes #22) --- README.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/README.md b/README.md index 93bcbd1..91b3c4e 100644 --- a/README.md +++ b/README.md @@ -14,6 +14,7 @@ A collection of cool hidden and not so hidden features of Git and GitHub. This c - [Line Highlighting in Repositories](#line-highlighting-in-repositories) - [Closing Issues via Commit Messages](#closing-issues-via-commit-messages) - [Cross-Link Issues](#cross-link-issues) + - [CI Status on Pull Requests](#ci-status-on-pull-requests) - [Syntax Highlighting in Markdown Files](#syntax-highlighting-in-markdown-files) - [Emojis](#emojis) - [Images/GIFs](#imagesgifs) @@ -202,6 +203,13 @@ To link to an issue in another repository, `user_name/repo_name#ISSUE_NUMBER` e. ![Cross-Link Issues](https://camo.githubusercontent.com/447e39ab8d96b553cadc8d31799100190df230a8/68747470733a2f2f6769746875622d696d616765732e73332e616d617a6f6e6177732e636f6d2f626c6f672f323031312f736563726574732f7265666572656e6365732e706e67) +### CI Status on Pull Requests +If set up correctly, every time you receive a Pull Request, [Travis CI](https://travis-ci.org/) will build that Pull Request just like it would every time you make a new commit. Read more about how to [get started with Travis CI](http://docs.travis-ci.com/user/getting-started/). + +[![Travic CI status](https://cloud.githubusercontent.com/assets/1687642/2700187/3a88838c-c410-11e3-9a46-e65e2a0458cd.png)](https://github.com/octokit/octokit.rb/pull/452) + +[*Read more about the commit status API.*](https://github.com/blog/1227-commit-status-api) + ### Syntax Highlighting in Markdown Files For example, to syntax highlight Ruby code in your Markdown files write: From fea81dbbe5d87f210e3b455ad8c0c33fb6faaed0 Mon Sep 17 00:00:00 2001 From: Hariadi Hinta Date: Wed, 16 Apr 2014 21:28:24 +0800 Subject: [PATCH 19/26] URL: Metadata and Plugin Support for GitHub Pages --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 91b3c4e..94add82 100644 --- a/README.md +++ b/README.md @@ -334,7 +334,7 @@ Within Jekyll pages and posts, repository information is available within the `s The Jemoji and jekyll-mentions plugins enable [emoji](#emojis) and [@mentions](https://github.com/blog/821) in your Jekyll posts and pages to work just like you'd expect when interacting with a repository on GitHub.com. -[*Read more about repository metadata and plugin support for GitHub Pages.*](Repository metadata and plugin support for GitHub Pages) +[*Read more about repository metadata and plugin support for GitHub Pages.*](https://github.com/blog/1797-repository-metadata-and-plugin-support-for-github-pages) ### Diffs #### Rendered Prose Diffs From 7e669d32ed39d754e8978cc3eb43cca43520e21f Mon Sep 17 00:00:00 2001 From: Tim Green Date: Wed, 16 Apr 2014 17:08:41 +0100 Subject: [PATCH 20/26] Add Ignoring Whitespace example --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 94add82..a98bc6f 100644 --- a/README.md +++ b/README.md @@ -54,6 +54,8 @@ A collection of cool hidden and not so hidden features of Git and GitHub. This c ### Ignore Whitespace Adding `?w=1` to any diff URL will remove any changes only in whitespace, enabling you to see only that code that has changed. +![Diff without whitespace](https://camo.githubusercontent.com/797184940defadec00393e6559b835358a863eeb/68747470733a2f2f6769746875622d696d616765732e73332e616d617a6f6e6177732e636f6d2f626c6f672f323031312f736563726574732f776869746573706163652e706e67) + [*Read more about GitHub secrets.*](https://github.com/blog/967-github-secrets) ### Commit History by Author From 803319ce284a0dd1497eb4a523b4186b935c04e9 Mon Sep 17 00:00:00 2001 From: Tim Green Date: Wed, 16 Apr 2014 17:17:57 +0100 Subject: [PATCH 21/26] Add date format helper for comparing branches --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index a98bc6f..420cf20 100644 --- a/README.md +++ b/README.md @@ -102,6 +102,8 @@ https://github.com/rails/rails/compare/master@{1.day.ago}...master https://github.com/rails/rails/compare/master@{2014-10-04}...master ``` +*Dates are in the format `YYYY-DD-MM`* + ![Another compare example](http://i.imgur.com/5dtzESz.png) ...which allows you to see the difference on the master branch up a set time ago or a specified date. From c2cbbc3d909629d3058f14be6c4adc8bcf01cbc2 Mon Sep 17 00:00:00 2001 From: Tim Green Date: Wed, 16 Apr 2014 17:24:20 +0100 Subject: [PATCH 22/26] Literally link emoji lists to add clarity --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 420cf20..9e31449 100644 --- a/README.md +++ b/README.md @@ -248,7 +248,7 @@ Would produce: :smile: -The full list of supported Emojis on GitHub can be found [here](http://www.emoji-cheat-sheet.com/) or [here](https://github.com/scotch-io/All-Github-Emoji-Icons). +The full list of supported Emojis on GitHub can be found at [http://www.emoji-cheat-sheet.com/](http://www.emoji-cheat-sheet.com/) or [scotch-io/All-Github-Emoji-Icons](https://github.com/scotch-io/All-Github-Emoji-Icons). The top 5 used Ejmojis on GitHub are: From bdb3f77d37d2cd27e9825b59bd4537f45eaf0295 Mon Sep 17 00:00:00 2001 From: Tim Green Date: Wed, 16 Apr 2014 17:25:49 +0100 Subject: [PATCH 23/26] Format link better --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 9e31449..ae044b7 100644 --- a/README.md +++ b/README.md @@ -248,7 +248,7 @@ Would produce: :smile: -The full list of supported Emojis on GitHub can be found at [http://www.emoji-cheat-sheet.com/](http://www.emoji-cheat-sheet.com/) or [scotch-io/All-Github-Emoji-Icons](https://github.com/scotch-io/All-Github-Emoji-Icons). +The full list of supported Emojis on GitHub can be found at [emoji-cheat-sheet.com](http://www.emoji-cheat-sheet.com/) or [scotch-io/All-Github-Emoji-Icons](https://github.com/scotch-io/All-Github-Emoji-Icons). The top 5 used Ejmojis on GitHub are: From 8e5b0bdd4535680d16f47bccd2f3c70d7d646aba Mon Sep 17 00:00:00 2001 From: Tim Green Date: Wed, 16 Apr 2014 17:30:08 +0100 Subject: [PATCH 24/26] Remove verbose Hub example --- README.md | 6 ------ 1 file changed, 6 deletions(-) diff --git a/README.md b/README.md index ae044b7..b5d4502 100644 --- a/README.md +++ b/README.md @@ -406,12 +406,6 @@ This allows you to do things like: $ hub clone tiimgreen/toc ``` -...instead of: - -```bash -$ git clone https://github.com/tiimgreen/toc.git -``` - [*Check out some more cool commands Hub has to offer.*](https://github.com/github/hub#commands) ### Decreasing Contributor Friction From 6ca33bdb0200369fadfed23c59963c862af53ca0 Mon Sep 17 00:00:00 2001 From: Tim Green Date: Wed, 16 Apr 2014 18:09:35 +0100 Subject: [PATCH 25/26] Stripspace --- README.md | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/README.md b/README.md index b5d4502..dcfb589 100644 --- a/README.md +++ b/README.md @@ -36,6 +36,7 @@ A collection of cool hidden and not so hidden features of Git and GitHub. This c - [GitHub Talks](#github-talks) - [Git](#git) - [Previous Branch](#previous-branch) + - [Stripspace](#stripspace) - [Checking out Pull Requests](#checking-out-pull-requests) - [Empty Commits :trollface:](#empty-commits-trollface) - [Styled Git Status](#styled-git-status) @@ -457,6 +458,21 @@ $ git checkout - [*Read more about Git branching.*](http://git-scm.com/book/en/Git-Branching-Basic-Branching-and-Merging) +### Stripspace + +Git Stripspace: + +- Strips trailing whitespace +- Collapses newlines +- Adds newline to end of file + +A file must be passed when calling the command, e.g.: +```bash +$ git stripspace < README.md +``` + +[*Read more about the Git `stripspace` command.*](https://www.kernel.org/pub/software/scm/git/docs/git-stripspace.html) + ### Checking out Pull Requests If you want to check out pull request locally, you can fetch it using that command: From d3b05869c498d8dbab31a909042fe5bf3711a5c8 Mon Sep 17 00:00:00 2001 From: Rafal Chmiel Date: Wed, 16 Apr 2014 18:40:00 +0100 Subject: [PATCH 26/26] Use different link to Git docs --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index dcfb589..f039c6b 100644 --- a/README.md +++ b/README.md @@ -471,7 +471,7 @@ A file must be passed when calling the command, e.g.: $ git stripspace < README.md ``` -[*Read more about the Git `stripspace` command.*](https://www.kernel.org/pub/software/scm/git/docs/git-stripspace.html) +[*Read more about the Git `stripspace` command.*](http://git-scm.com/docs/git-stripspace) ### Checking out Pull Requests If you want to check out pull request locally, you can fetch it using that command: