iankelling.org
/
git
/
small-misc-bash
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e92df2e
)
minor fixes
author
Ian Kelling
<iank@fsf.org>
Sun, 30 Jun 2019 19:21:25 +0000
(15:21 -0400)
committer
Ian Kelling
<iank@fsf.org>
Sun, 30 Jun 2019 19:21:25 +0000
(15:21 -0400)
ex
patch
|
blob
|
history
psg-function
patch
|
blob
|
history
diff --git
a/ex
b/ex
index cd9bd78ec0b367546d7d5e32dc6b59f9f210ce75..0ef26c45c5a9d7dc50d6852986bb7091f7e60d59 100755
(executable)
--- a/
ex
+++ b/
ex
@@
-36,7
+36,13
@@
Note: dtrx (package & command) extracts most of these plus some others."
*.xz) xz -d "$x" ;;
*.7z ) 7za x "$x" ;;
*.bz2 ) bunzip2 "$x" ;;
- *.deb ) ar x "$x" ;;
+ *.deb )
+ ar x "$x"
+ tar Jxf data.tar.xz
+ tar xzf control.tar.gz
+ rm -f control.tar.gz
+ rm -f data.tar.xz
+ ;;
*.dsc) dpkg-source -x "$x" ;;
*.gz ) gunzip "$x" ;;
*.iso )
diff --git
a/psg-function
b/psg-function
index ccdd12aff199341b56c2c0d2c90cc99745122049..bdef3516a46d5f7bf3cdf34f41d5cc33f397b974 100644
(file)
--- a/
psg-function
+++ b/
psg-function
@@
-23,7
+23,7
@@
grep ps and output in a nice format"
fi
x=$(sudo ps -eF)
# final grep is because some commands tend to have a lot of trailing spaces
- y=$(echo "$x" | grep -P "$@" | grep -o '.*[^ ]')
+ y=$(echo "$x" | grep -
i
P "$@" | grep -o '.*[^ ]')
if [[ $y ]]; then
echo "$x" | head -n 1
echo "$y"