Update
This commit is contained in:
parent
2e05e553c4
commit
e28f06948f
|
@ -0,0 +1,7 @@
|
|||
[Desktop Entry]
|
||||
Exec=/usr/bin/bash ~/.local/bin/key-sign.sh
|
||||
Icon=
|
||||
Name=key-sign.sh
|
||||
Path=
|
||||
Terminal=False
|
||||
Type=Application
|
|
@ -0,0 +1,92 @@
|
|||
#!/bin/bash
|
||||
|
||||
if [[ "$UID" != 0 ]]; then
|
||||
echo "USER NOT ROOT"
|
||||
sudo "$0"
|
||||
exit
|
||||
else
|
||||
echo "USER IS ROOT"
|
||||
fi
|
||||
|
||||
ping -c 1 1.1.1.1 > /dev/null
|
||||
have_internet="$?"
|
||||
|
||||
# sleep 1
|
||||
|
||||
cd "/root"
|
||||
|
||||
rm /var/lib/pacman/sync/*
|
||||
rm -rf /etc/pacman.d/gnupg/*
|
||||
|
||||
mkdir -p /root/.gnupg 2>/dev/null
|
||||
chmod 700 /root/.gnupg
|
||||
|
||||
haveged -w 1024
|
||||
pacman-key --init
|
||||
pkill haveged
|
||||
|
||||
pacman-key --add /usr/share/pacman/keyrings/melawy-linux.gpg
|
||||
pacman-key --lsign-key BC8B600E8DDA1F4CB77B10D2BA803A261A5EE6B8
|
||||
pacman-key --lsign-key B175815513971572FE7B1557CEC07AC8FF64DA4B
|
||||
|
||||
if [ "$have_internet" -eq 0 ]; then
|
||||
pacman-key --keyserver hkps://keys.openpgp.org --recv-keys BC8B600E8DDA1F4CB77B10D2BA803A261A5EE6B8
|
||||
pacman-key --keyserver hkps://keyserver.ubuntu.com --recv-keys BC8B600E8DDA1F4CB77B10D2BA803A261A5EE6B8
|
||||
pacman-key --lsign-key BC8B600E8DDA1F4CB77B10D2BA803A261A5EE6B8
|
||||
|
||||
pacman-key --keyserver hkps://keys.openpgp.org --recv-keys B175815513971572FE7B1557CEC07AC8FF64DA4B
|
||||
pacman-key --keyserver hkps://keyserver.ubuntu.com --recv-keys B175815513971572FE7B1557CEC07AC8FF64DA4B
|
||||
pacman-key --lsign-key B175815513971572FE7B1557CEC07AC8FF64DA4B
|
||||
fi
|
||||
|
||||
pacman-key --lsign-key melawy-linux
|
||||
|
||||
pacman-key --add /usr/share/pacman/keyrings/manjaro.gpg
|
||||
pacman-key --lsign-key manjaro
|
||||
pacman-key --add /usr/share/pacman/keyrings/cachyos.gpg
|
||||
pacman-key --lsign-key cachyos
|
||||
pacman-key --add /usr/share/pacman/keyrings/arcolinux.gpg
|
||||
pacman-key --lsign-key arcolinux
|
||||
pacman-key --add /usr/share/pacman/keyrings/chaotic.gpg
|
||||
pacman-key --lsign-key chaotic
|
||||
pacman-key --add /usr/share/pacman/keyrings/endeavouros.gpg
|
||||
pacman-key --lsign-key endeavouros
|
||||
|
||||
pacman-key --populate
|
||||
|
||||
echo "
|
||||
keyserver hkp://keyserver.ubuntu.com:80" | sudo tee --append /etc/pacman.d/gnupg/gpg.conf
|
||||
|
||||
pacman-key --updatedb
|
||||
|
||||
if [ "$have_internet" -eq 0 ]; then
|
||||
pacman -Sy
|
||||
fi
|
||||
|
||||
title="Successed!"
|
||||
msg="$(date '+%Y.%m.%d %H:%M:%S')"
|
||||
|
||||
users=$(/usr/bin/users | sed 's| |\n|g' | sort | uniq)
|
||||
for user in $users
|
||||
do
|
||||
userid=$(/usr/bin/id -u "$user")
|
||||
|
||||
cmd=(
|
||||
DISPLAY=:0
|
||||
DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/"$userid"/bus
|
||||
/usr/bin/notify-send
|
||||
--icon=info
|
||||
--urgency=low
|
||||
-t 5000
|
||||
-a "'Keys sign'"
|
||||
"'$title'"
|
||||
"'$msg'"
|
||||
)
|
||||
|
||||
/usr/bin/su "$user" -c "${cmd[*]}"
|
||||
|
||||
if [ "$user" != "liveuser" ]; then
|
||||
rm /home/"$user"/.config/autostart/key-sign.sh.desktop
|
||||
# rm /home/"$user"/.local/bin/key-sign.sh
|
||||
fi
|
||||
done
|
|
@ -1,8 +1,10 @@
|
|||
<?xml version='1.0'?>
|
||||
<!DOCTYPE gui SYSTEM 'kpartgui.dtd'>
|
||||
<gui name="dolphin" version="40">
|
||||
<MenuBar>
|
||||
<Menu name="file">
|
||||
<!DOCTYPE gui>
|
||||
<gui name="dolphin" translationDomain="kxmlgui6" version="40">
|
||||
<MenuBar alreadyVisited="1">
|
||||
<Menu alreadyVisited="1" name="file" noMerge="1">
|
||||
<text translationDomain="kxmlgui6">&File</text>
|
||||
<Action name="file_new"/>
|
||||
<Separator weakSeparator="1"/>
|
||||
<Action name="new_menu"/>
|
||||
<Action name="file_new"/>
|
||||
<Action name="new_tab"/>
|
||||
|
@ -19,8 +21,23 @@
|
|||
<Action name="show_target"/>
|
||||
<Separator/>
|
||||
<Action name="properties"/>
|
||||
<Separator weakSeparator="1"/>
|
||||
<Action name="file_close"/>
|
||||
<Separator weakSeparator="1"/>
|
||||
<Action name="file_quit"/>
|
||||
</Menu>
|
||||
<Menu name="edit">
|
||||
<Menu alreadyVisited="1" name="edit" noMerge="1">
|
||||
<text translationDomain="kxmlgui6">&Edit</text>
|
||||
<Action name="edit_undo"/>
|
||||
<Separator weakSeparator="1"/>
|
||||
<Action name="edit_cut"/>
|
||||
<Action name="edit_copy"/>
|
||||
<Action name="edit_paste"/>
|
||||
<Separator weakSeparator="1"/>
|
||||
<Action name="edit_select_all"/>
|
||||
<Separator weakSeparator="1"/>
|
||||
<Action name="edit_find"/>
|
||||
<Separator weakSeparator="1"/>
|
||||
<Action name="edit_undo"/>
|
||||
<Separator/>
|
||||
<Action name="edit_cut"/>
|
||||
|
@ -37,7 +54,13 @@
|
|||
<Action name="edit_select_all"/>
|
||||
<Action name="invert_selection"/>
|
||||
</Menu>
|
||||
<Menu name="view">
|
||||
<Menu alreadyVisited="1" name="view" noMerge="1">
|
||||
<text translationDomain="kxmlgui6">&View</text>
|
||||
<Action name="view_zoom_in"/>
|
||||
<Action name="view_zoom_out"/>
|
||||
<Separator weakSeparator="1"/>
|
||||
<Action name="view_redisplay"/>
|
||||
<Separator weakSeparator="1"/>
|
||||
<Action name="view_zoom_in"/>
|
||||
<Action name="view_zoom_reset"/>
|
||||
<Action name="view_zoom_out"/>
|
||||
|
@ -57,19 +80,27 @@
|
|||
<Action name="stop"/>
|
||||
<Separator/>
|
||||
<Action name="panels"/>
|
||||
<Menu icon="edit-select-text" name="location_bar">
|
||||
<text context="@title:menu">Location Bar</text>
|
||||
<Menu icon="edit-select-text" name="location_bar" noMerge="1">
|
||||
<text context="@title:menu" translationDomain="dolphin">Location Bar</text>
|
||||
<Action name="editable_location"/>
|
||||
<Action name="replace_location"/>
|
||||
</Menu>
|
||||
<Separator/>
|
||||
<Action name="view_properties"/>
|
||||
</Menu>
|
||||
<Menu name="go">
|
||||
<Menu alreadyVisited="1" name="go" noMerge="1">
|
||||
<text translationDomain="kxmlgui6">&Go</text>
|
||||
<Action name="go_up"/>
|
||||
<Action name="go_back"/>
|
||||
<Action name="go_forward"/>
|
||||
<Action name="go_home"/>
|
||||
<Separator weakSeparator="1"/>
|
||||
<Action name="bookmarks"/>
|
||||
<Action name="closed_tabs"/>
|
||||
</Menu>
|
||||
<Menu name="tools">
|
||||
<Separator weakSeparator="1"/>
|
||||
<Menu alreadyVisited="1" name="tools" noMerge="1">
|
||||
<text translationDomain="kxmlgui6">&Tools</text>
|
||||
<Action name="open_preferred_search_tool"/>
|
||||
<Action name="open_terminal"/>
|
||||
<Action name="open_terminal_here"/>
|
||||
|
@ -77,10 +108,37 @@
|
|||
<Action name="compare_files"/>
|
||||
<Action name="change_remote_encoding"/>
|
||||
</Menu>
|
||||
<Menu alreadyVisited="1" name="settings" noMerge="1">
|
||||
<text translationDomain="kxmlgui6">&Settings</text>
|
||||
<Action name="options_show_menubar"/>
|
||||
<Merge name="StandardToolBarMenuHandler"/>
|
||||
<Merge name="KMDIViewActions"/>
|
||||
<Action name="options_show_statusbar"/>
|
||||
<Separator weakSeparator="1"/>
|
||||
<Action name="switch_application_language"/>
|
||||
<Action name="options_configure_keybinding"/>
|
||||
<Action name="options_configure_toolbars"/>
|
||||
<Action name="options_configure"/>
|
||||
</Menu>
|
||||
<Separator weakSeparator="1"/>
|
||||
<Menu alreadyVisited="1" name="help" noMerge="1">
|
||||
<text translationDomain="kxmlgui6">&Help</text>
|
||||
<Action name="help_contents"/>
|
||||
<Action name="help_whats_this"/>
|
||||
<Action name="open_kcommand_bar"/>
|
||||
<Separator weakSeparator="1"/>
|
||||
<Action name="help_report_bug"/>
|
||||
<Separator weakSeparator="1"/>
|
||||
<Action name="help_donate"/>
|
||||
<Separator weakSeparator="1"/>
|
||||
<Action name="help_about_app"/>
|
||||
<Action name="help_about_kde"/>
|
||||
</Menu>
|
||||
</MenuBar>
|
||||
<ToolBar alreadyVisited="1" name="mainToolBar" noMerge="1">
|
||||
<Action name="go_home"/>
|
||||
<Action name="open_terminal_here"/>
|
||||
<Action name="new_menu"/>
|
||||
<Separator name="separator_0"/>
|
||||
<text context="@title:menu" translationDomain="dolphin">Main Toolbar</text>
|
||||
<Action name="go_back"/>
|
||||
|
@ -155,5 +213,6 @@
|
|||
<Action name="view_zoom_in" priority="0"/>
|
||||
<Action name="view_zoom_out" priority="0"/>
|
||||
<Action name="view_zoom_reset" priority="0"/>
|
||||
<Action name="new_menu" priority="0"/>
|
||||
</ActionProperties>
|
||||
</gui>
|
||||
|
|
Loading…
Reference in New Issue