Skip to content

Commit 6ca33bd

Browse files
committed
Stripspace
1 parent 8e5b0bd commit 6ca33bd

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

README.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ A collection of cool hidden and not so hidden features of Git and GitHub. This c
3636
- [GitHub Talks](#github-talks)
3737
- [Git](#git)
3838
- [Previous Branch](#previous-branch)
39+
- [Stripspace](#stripspace)
3940
- [Checking out Pull Requests](#checking-out-pull-requests)
4041
- [Empty Commits :trollface:](#empty-commits-trollface)
4142
- [Styled Git Status](#styled-git-status)
@@ -457,6 +458,21 @@ $ git checkout -
457458

458459
[*Read more about Git branching.*](http://git-scm.com/book/en/Git-Branching-Basic-Branching-and-Merging)
459460

461+
### Stripspace
462+
463+
Git Stripspace:
464+
465+
- Strips trailing whitespace
466+
- Collapses newlines
467+
- Adds newline to end of file
468+
469+
A file must be passed when calling the command, e.g.:
470+
```bash
471+
$ git stripspace < README.md
472+
```
473+
474+
[*Read more about the Git `stripspace` command.*](https://www.kernel.org/pub/software/scm/git/docs/git-stripspace.html)
475+
460476
### Checking out Pull Requests
461477
If you want to check out pull request locally, you can fetch it using that command:
462478

0 commit comments

Comments
 (0)