diff options
author | Xiao Pan <gky44px1999@gmail.com> | 2024-03-01 16:24:23 -0800 |
---|---|---|
committer | Xiao Pan <gky44px1999@gmail.com> | 2024-03-01 16:24:23 -0800 |
commit | e314a3d23610ac5b981d791e657835451219d45a (patch) | |
tree | 90be6320018549caffed5ba0c2ba2bb9f864b1f4 | |
parent | 7444bf903de6b9a051ed29d599d8b1277adc87aa (diff) |
fix: consider util-linux
-rwxr-xr-x | sh/upd | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -175,12 +175,13 @@ pac () { systemctl list-unit-files --state=enabled > "$XDG_CONFIG_HOME/myconf/sye" systemctl --user list-unit-files --state=enabled > "$XDG_CONFIG_HOME/myconf/syue" # pacdiff default use pacman database, so no need `sudo -E` for find, but will be a little bit slower + # [^-] consider util-linux; \(^\|[^-]\) consider linux is the first package, ex: pacout is only 'linux-6.6.6' log="$log updated pacman packages: $pacpacs updated aur packages: $aurpacs pacdiff: $(pacdiff -o | tr '\n' ' ') checkrebuild: $checkrebuild_pacs -$(if echo "$pacpacs" | grep -q 'linux-\(megi-\)\?[0-9]'; then echo 'kernel upgraded, need reboot'; fi) +$(if echo "$pacpacs" | grep -q '\(^\|[^-]\)linux-\(megi-\)\?[0-9]'; then echo 'kernel upgraded, need reboot'; fi) " } |