Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
eepm
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
etersoft
eepm
Commits
c226aca4
Commit
c226aca4
authored
Mar 31, 2024
by
Vitaly Lipatov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
epm pack.d/generic-appimage.sh: don't override package version with…
epm pack.d/generic-appimage.sh: don't override package version with X-AppImage-Version (can be wrong)
parent
8f3d8163
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
7 deletions
+8
-7
generic-appimage.sh
pack.d/generic-appimage.sh
+8
-7
No files found.
pack.d/generic-appimage.sh
View file @
c226aca4
...
...
@@ -23,22 +23,23 @@ alpkg=$(basename $TAR)
PRODUCT
=
"
$(
basename
$alpkg
.AppImage
)
"
# unpack AppImage
# TODO: use SHELL/sh instead of execute bit
[
-x
"
$TAR
"
]
||
chmod
u+x
$verbose
"
$TAR
"
$TAR
--appimage-extract
>
/dev/null
||
fatal
# try separate VERSION from PRODUCT
if
[
-z
"
$VERSION
"
]
;
then
VERSION
=
"
$(
echo
"
$PRODUCT
"
|
grep
-o
-P
"[-_.
a-zA-Z]([0-9])([0-9])*([.]*[0-9])*"
|
head
-n1
|
sed
-e
's|^[-_.a-zA-Z]||'
-e
's|--|-|g
'
)
"
#"
VERSION
=
"
$(
echo
"
$PRODUCT
"
|
grep
-o
-P
"[-_.
]([0-9v])([0-9])*([.]*[0-9])*"
|
head
-n1
|
sed
-e
's|^[-_.a-zA-Z]||'
-e
's|--|-|g'
-e
's|^v\([0-9]\)|\1|
'
)
"
#"
[
-n
"
$VERSION
"
]
&&
PRODUCT
=
"
$(
echo
"
$PRODUCT
"
|
sed
-e
"s|[-_.]
$VERSION
.*||"
)
"
PRODUCT
=
"
${
PRODUCT
/-x86_64/
}
"
fi
# try override version with X-AppImage-Version if present
DESKTOPFILE
=
"
$(
echo
squashfs-root/
*
.desktop |
head
-n1
)
"
str
=
"
$(
grep
'^X-AppImage-Version=[0-9]'
$DESKTOPFILE
)
"
if
[
-n
"
$str
"
]
;
then
VERSION
=
"
$(
echo
$str
|
sed
-e
's|.*X-AppImage-Version=||'
)
"
# try get version from X-AppImage-Version
if
[
-z
"
$VERSION
"
]
;
then
DESKTOPFILE
=
"
$(
echo
squashfs-root/
*
.desktop |
head
-n1
)
"
str
=
"
$(
grep
'^X-AppImage-Version=[0-9]'
$DESKTOPFILE
)
"
if
[
-n
"
$str
"
]
;
then
VERSION
=
"
$(
echo
$str
|
sed
-e
's|.*X-AppImage-Version=||'
)
"
fi
fi
# try get version from URL
...
...
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