Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
PortWINE
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Vladislav
PortWINE
Commits
27a3962e
Commit
27a3962e
authored
Sep 28, 2024
by
Vladislav
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Updated background_pid, added returns for clear prefix, reinstall and delete PP
parent
27d18124
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
22 additions
and
21 deletions
+22
-21
functions_helper
data_from_portwine/scripts/functions_helper
+20
-15
start.sh
data_from_portwine/scripts/start.sh
+2
-6
No files found.
data_from_portwine/scripts/functions_helper
View file @
27a3962e
...
...
@@ -679,23 +679,27 @@ background_pid () {
local arg1=
$1
# --start или --end
local arg2=
$2
# Название команды
local arg3=
$3
# Номер процесса (1,2,3..)
if [[ "
$START_FROM_STEAM
" == 1 ]]
\
|| [[ -n "
$PW_DEBUG
" ]] ; then
case
$arg1
in
--start) eval "
$arg2
" ;;
--end) : ;;
esac
else
get_bg_pid () {
eval "
echo
\
${
$1
}
"
}
if [[ "
$arg1
" == --start ]] ; then
case
$arg1
in
--start)
eval "
$arg2
&
"
PID=
$!
export bg_pid"
${
arg3
}
"="
$PID
"
elif [[ "
$arg1
" == --end ]] ; then
export bg_pid"
${
arg3
}
"="
$PID
" ;;
--end)
PID=
$(
get_bg_pid bg_pid
"
${
arg3
}
"
)
[[
$PID
== "" ]] && return 1
while true ; do
if [[ !
$(
jobs
-p
)
=~
$PID
]] ; then
return 0
fi
sleep 0.005
done
wait "
$PID
" && return 0 ;;
esac
fi
}
export -f background_pid
...
...
@@ -849,9 +853,7 @@ pw_reinstall_pp () {
echo ""
exit 1
fi
elif ! yad_question "
${
translations
[Do you really want to reinstall PortProton?\\nFor this, an internet connection will be required.]
}
"
then exit 1
fi
elif yad_question "
${
translations
[Do you really want to reinstall PortProton?\\nFor this, an internet connection will be required.]
}
" ; then
pw_clear_pfx
try_remove_dir "
${
PORT_WINE_PATH
}
/data/dist
"
create_new_dir "
${
PORT_WINE_PATH
}
/data/dist
"
...
...
@@ -862,6 +864,7 @@ pw_reinstall_pp () {
echo ""
unset SKIP_CHECK_UPDATES
print_info "
Restarting
PP for reinstall files...
"
fi
restart_pp
}
...
...
@@ -5874,8 +5877,8 @@ gui_clear_pfx () {
if
yad_question
"
${
translations
[Do you want to clear prefix in PortProton?]
}
"
;
then
pw_clear_pfx
print_info
"Restarting PP after clearing prefix..."
restart_pp
fi
restart_pp
}
export
-f
gui_clear_pfx
...
...
@@ -5886,8 +5889,9 @@ gui_rm_portproton () {
rm
-fr
"
${
HOME
}
/PortWINE"
rm
-f
"
$(
grep
-il
PortProton
"
${
HOME
}
/.local/share/applications"
/
*
.desktop
)
"
update-desktop-database
-q
"
${
HOME
}
/.local/share/applications"
fi
exit
0
fi
restart_pp
}
export
-f
gui_rm_portproton
...
...
@@ -5988,6 +5992,7 @@ export -f change_gui_start
gui_wine_uninstaller
()
{
start_portwine
pw_run uninstaller
stop_portwine
--restart
}
export
-f
gui_wine_uninstaller
...
...
data_from_portwine/scripts/start.sh
View file @
27a3962e
...
...
@@ -257,11 +257,7 @@ if [[ "${SKIP_CHECK_UPDATES}" != 1 ]] ; then
PW_FILESYSTEM
=
$(
stat
-f
-c
%T
"
${
PORT_WINE_PATH
}
"
)
export
PW_FILESYSTEM
if
[[
"
$START_FROM_STEAM
"
==
1
]]
;
then
pw_get_tmp_files
else
background_pid
--start
"pw_get_tmp_files"
"1"
fi
fi
# create lock file
...
...
@@ -802,7 +798,7 @@ fi
[[ -n "$PW_YAD_SET" ]] && case "$PW_YAD_SET" in
gui_pw_reinstall_pp|open_changelog|\
128|gui_pw_update|\
128|gui_pw_update|
gui_rm_portproton|
\
change_loc|gui_open_scripts_from_backup|\
gui_credits|pw_start_cont_xterm)
if [[ -z "${PW_ALL_DF}" ]] ; then
...
...
@@ -814,7 +810,7 @@ fi
gui_proton_downloader|WINETRICKS|\
116|pw_create_prefix_backup|\
gui_clear_pfx|WINEREG|WINECMD|\
WINEFILE|WINECFG)
WINEFILE|WINECFG
|gui_wine_uninstaller
)
if [[ -z "${PW_ALL_DF}" ]] ; then
export TAB_MAIN_MENU="3"
else
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment