-
-
Notifications
You must be signed in to change notification settings - Fork 163
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rework notification to not be sent from systemd service
- Loading branch information
Showing
6 changed files
with
27 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
if test "$(id -u)" -gt "0" && test -d "$HOME"; then | ||
Check failure on line 1 in system_files/shared/etc/profile.d/sb-key-notify-autostart.sh Codacy Production / Codacy Static Code Analysissystem_files/shared/etc/profile.d/sb-key-notify-autostart.sh#L1
|
||
if test ! -e "$HOME"/.config/autostart/sb-key-notify.desktop; then | ||
mkdir -p "$HOME"/.config/autostart | ||
cp -f /etc/skel/.config/autostart/sb-key-notify.desktop "$HOME"/.config/autostart | ||
fi | ||
fi |
10 changes: 10 additions & 0 deletions
10
system_files/shared/etc/skel/.config/autostart/sb-key-notify.desktop
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
[Desktop Entry] | ||
Name=Secure boot Notify | ||
Comment=Autostart secure boot key notification | ||
Exec=/usr/bin/sb-key-notify | ||
Icon=org.gnome.Terminal | ||
Type=Application | ||
Categories=Utility;System; | ||
Name[en_US]=secure-boot-notify | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
KEY_WARN_FILE="/run/user-motd-sbkey-warn.md" | ||
|
||
if [ -e $KEY_WARN_FILE ]; then | ||
WARNING_MSG=$(cat "$KEY_WARN_FILE") | ||
|
||
notify-send "WARNING" "$(echo "$WARNING_MSG" | tr -d '*~')" -i dialog-warning -u critical -a mokutil --wait | ||
else | ||
echo "No secure boot key warning file. Skipping... | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters