add grep only integers

This commit is contained in:
onceupon 2017-11-01 17:59:03 +08:00 committed by GitHub
parent 4dfbacff7b
commit 42df407113
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -33,6 +33,13 @@ http://onceupon.github.io/Bash-Oneliner/
grep -o -P '(?<=w1).*(?=w2)'
```
##### Grep only integer
```bash
grep -o '[0-9]*'
```
##### Grep lines without word (e.g. bbo)
```bash