mirror of
https://gitee.com/spark-store-project/spark-store
synced 2025-09-26 13:02:20 +08:00
update tool/ssaudit.
Signed-off-by: shenmo <jifengshenmo@outlook.com>
This commit is contained in:
parent
9f1f21c2b6
commit
321e6b3dfe
@ -29,7 +29,7 @@ function create_desktop_file() {
|
|||||||
}
|
}
|
||||||
function exec_create_desktop_file() {
|
function exec_create_desktop_file() {
|
||||||
local user=$(who | awk '{print $1}' | head -n 1)
|
local user=$(who | awk '{print $1}' | head -n 1)
|
||||||
for desktop_file_path in $(dpkg -L "$package_name" | grep .desktop); do
|
for desktop_file_path in $(dpkg -L "$package_name" | awk '/\.desktop$/ {print}'); do
|
||||||
if [ "$(cat $desktop_file_path | grep NoDisplay=true)" = "" ];then
|
if [ "$(cat $desktop_file_path | grep NoDisplay=true)" = "" ];then
|
||||||
echo $desktop_file_path is checked and will be installed to desktop
|
echo $desktop_file_path is checked and will be installed to desktop
|
||||||
sudo -u "$user" cp "$desktop_file_path" "$(sudo -u "$user" xdg-user-dir DESKTOP)/"
|
sudo -u "$user" cp "$desktop_file_path" "$(sudo -u "$user" xdg-user-dir DESKTOP)/"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user