Skip to content

Commit 7b80692

Browse files
committed
Create Shell Programming.md
1 parent 81b147a commit 7b80692

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

Shell Programming.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
##1. replace the specific line
2+
```
3+
sed '4 s/hello/good/g' file
4+
sed '4a drink tea' file
5+
sed '4d'
6+
sed -n '5,7p'
7+
8+
```
9+
10+
##2. print the specific colume
11+
```
12+
sed -n '5p' hello | awk 'BEGIN {FS=","} {print $4}'
13+
```

0 commit comments

Comments
 (0)