replace grep+sed by awk
This commit is contained in:
parent
e88e9c357f
commit
2b9bf3de24
1 changed files with 1 additions and 1 deletions
|
@ -143,7 +143,7 @@ esac
|
||||||
if [ -f /etc/os-release ]; then
|
if [ -f /etc/os-release ]; then
|
||||||
# already lowercase, according to:
|
# already lowercase, according to:
|
||||||
# https://www.freedesktop.org/software/systemd/man/os-release.html
|
# https://www.freedesktop.org/software/systemd/man/os-release.html
|
||||||
grep '^ID=' /etc/os-release | sed -e 's|^ID=||'
|
awk -F= '/^ID=/ {print $2;}' /etc/os-release
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue