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
Mikhail Tergoev
PortWINE
Commits
334b49cd
Commit
334b49cd
authored
Oct 22, 2024
by
Vladislav
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added PORTWINE_DB_NEW
parent
2703dd1e
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
41 additions
and
8 deletions
+41
-8
functions_helper
data_from_portwine/scripts/functions_helper
+8
-5
start.sh
data_from_portwine/scripts/start.sh
+33
-3
No files found.
data_from_portwine/scripts/functions_helper
View file @
334b49cd
...
...
@@ -5433,15 +5433,18 @@ portwine_create_shortcut () {
for df in "${DESKTOP_FILES_ARRAY[@]}" ; do
df="${df//"$PORT_WINE_PATH/"/}"
df="${df//.desktop/}"
if [[ ${PORTWINE_DB^^} =~ ${df^^} ]]
if [[ ${PORTWINE_DB^^} =~ ${df^^} ]]
&& [[ ${PORTWINE_DB^^} != ${df^^} ]]
then name_desktop="$df"
fi
done
fi
if [[ -z $name_desktop ]] ; then
if [[ -n $PORTPROTON_NAME ]]
then name_desktop="$PORTPROTON_NAME"
else name_desktop="$PORTWINE_DB"
if [[ ${PORTPROTON_NAME^^} =~ ${PORTWINE_DB^^} ]] \
&& [[ ${PORTPROTON_NAME^^} != "${PORTWINE_DB^^}" ]]
then
name_desktop="$PORTPROTON_NAME"
else
name_desktop="$PORTWINE_DB_NEW"
fi
fi
export name_desktop
...
...
@@ -5492,7 +5495,7 @@ portwine_create_shortcut () {
edit_user_conf_from_gui PW_SHORTCUT_MENU PW_SHORTCUT_DESKTOP PW_SHORTCUT_STEAM
if
[[
-n
${
DESKTOP_FILES_ARRAY
[1]
}
]]
;
then
if
[[
-n
${
DESKTOP_FILES_ARRAY
[
0]
}
]]
&&
[[
$name_desktop
!=
$df
]]
||
[[
-n
${
DESKTOP_FILES_ARRAY
[
1]
}
]]
;
then
if
yad_question
"
${
translations
[A higher number of duplicate desktop files were found for this file.\\nShould I delete the extra ones or not?]
}
"
;
then
for
rm
in
"
${
DESKTOP_FILES_ARRAY
[@]
}
"
;
do
rm
-f
"
$rm
"
...
...
data_from_portwine/scripts/start.sh
View file @
334b49cd
...
...
@@ -502,10 +502,40 @@ if [[ -f "${portwine_exe}" ]] ; then
[[
$DESKTOP_WITH_TIME
==
enabled
]]
&&
search_desktop_file
if
[[
-z
"
${
PW_COMMENT_DB
}
"
]]
;
then
if
[[
-n
"
${
PORTPROTON_NAME
}
"
]]
;
then
if
[[
${
PORTPROTON_NAME
^^
}
=
~
${
PORTWINE_DB
^^
}
]]
&&
[[
${
PORTPROTON_NAME
^^
}
!=
"
${
PORTWINE_DB
^^
}
"
]]
;
then
PW_COMMENT_DB
=
"
${
translations
[Launching]
}
<b>
$(
print_wrapped
"
${
PORTPROTON_NAME
}
"
"50"
)
</b>
$(
seconds_to_time
"
$TIME_CURRENT
"
)
"
else
PW_COMMENT_DB
=
"
${
translations
[Launching]
}
<b>
$(
print_wrapped
"
${
PORTWINE_DB
}
"
"50"
)
</b>
$(
seconds_to_time
"
$TIME_CURRENT
"
)
"
unset
PORTWINE_DB_PROXY PORTWINE_DB_NEW
PORTWINE_DB
=
"
${
PORTWINE_DB
//_/
}
"
if
[[
${
PORTWINE_DB
:0:1
}
=
~
[
a-z]
]]
;
then
PORTWINE_DB_UPPER
=
"
${
PORTWINE_DB
^^
}
"
PORTWINE_DB
=
"
${
PORTWINE_DB_UPPER
:0:1
}${
PORTWINE_DB
:1
}
"
fi
if
((
${#
PORTWINE_DB
}
>
2
))
;
then
for
((
i
=
0
;
i<
${#
PORTWINE_DB
}
;
i++
))
;
do
if
[[
${
PORTWINE_DB
:i:2
}
=
~
([
a-z][A-Z]|[a-z][0-9]
)
]]
\
&&
[[
!
${
PORTWINE_DB
:i:3
}
=
~
([
a-z][A-Z]
" "
|[a-z][0-9]
" "
)
]]
;
then
PORTWINE_DB_PROXY+
=
"
${
PORTWINE_DB
:i:1
}
"
elif
[[
${
PORTWINE_DB
:i:3
}
=
~
[
0-9][0-9][a-zA-Z]
]]
;
then
PORTWINE_DB_PROXY+
=
"
${
PORTWINE_DB
:i:2
}
"
((
i++
))
else
PORTWINE_DB_PROXY+
=
"
${
PORTWINE_DB
:i:1
}
"
fi
done
for
((
i
=
0
;
i<
${#
PORTWINE_DB_PROXY
}
;
i++
))
;
do
if
[[
${
PORTWINE_DB_PROXY
:i:2
}
=
~
" "
[
a-z]
]]
;
then
PORTWINE_DB_UPPER
=
"
${
PORTWINE_DB_PROXY
:i:2
}
"
PORTWINE_DB_NEW+
=
"
${
PORTWINE_DB_UPPER
^^
}
"
((
i++
))
else
PORTWINE_DB_NEW+
=
"
${
PORTWINE_DB_PROXY
:i:1
}
"
fi
done
else
PORTWINE_DB_NEW
=
"
$PORTWINE_DB
"
fi
PW_COMMENT_DB
=
"
${
translations
[Launching]
}
<b>
$(
print_wrapped
"
${
PORTWINE_DB_NEW
}
"
"50"
)
</b>
$(
seconds_to_time
"
$TIME_CURRENT
"
)
"
fi
else
PW_COMMENT_DB
=
"
$PW_COMMENT_DB
$(
seconds_to_time
"
$TIME_CURRENT
"
)
"
...
...
@@ -639,7 +669,7 @@ else
if [[
$SORT_WITH_TIME
== enabled ]] && [[
$NEW_DESKTOP
== 1 ]] ; then
unset NEW_DESKTOP
sed -i '/^#NEW_DESKTOP/d' "
$desktop_file
"
PW_AMOUNT_NEW_DESKTOP=(
$AMOUNT_GENERATE_BUTTONS
)
PW_AMOUNT_NEW_DESKTOP
+
=(
$AMOUNT_GENERATE_BUTTONS
)
else
PW_AMOUNT_OLD_DESKTOP+=(
$AMOUNT_GENERATE_BUTTONS
)
fi
...
...
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