From 6ca33bdb0200369fadfed23c59963c862af53ca0 Mon Sep 17 00:00:00 2001 From: Tim Green Date: Wed, 16 Apr 2014 18:09:35 +0100 Subject: [PATCH] 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: