mirror of https://github.com/cheat/cheat.git
Merge pull request #4 from CogBear/master
Cut command added and bash extended
This commit is contained in:
commit
098384d341
|
@ -3,3 +3,12 @@ for file in `ls .`;
|
||||||
do echo 'file';
|
do echo 'file';
|
||||||
echo 'found';
|
echo 'found';
|
||||||
done
|
done
|
||||||
|
|
||||||
|
To implement a case command:
|
||||||
|
case "$1"
|
||||||
|
in
|
||||||
|
0) echo "zero found";;
|
||||||
|
1) echo "one found";;
|
||||||
|
2) echo "two found";;
|
||||||
|
3) echo "three found";;
|
||||||
|
esac
|
||||||
|
|
|
@ -0,0 +1,2 @@
|
||||||
|
To cut out the third field of text or stdoutput that is delimited by a #:
|
||||||
|
cut -d# -f3
|
Loading…
Reference in New Issue