Commit 5c49205 1 parent fdcd9d4 commit 5c49205 Copy full SHA for 5c49205
File tree 4 files changed +29
-13
lines changed
4 files changed +29
-13
lines changed Original file line number Diff line number Diff line change 5
5
pull_request :
6
6
types : [opened, reopened]
7
7
8
-
9
- env :
10
- APT : sudo apt install -y --no-install-recommends
11
-
12
8
jobs :
13
9
ubuntu20 :
14
10
runs-on : ubuntu-20.04
44
40
runs-on : ubuntu-latest
45
41
steps :
46
42
- uses : actions/checkout@v4
47
- - run : ${APT} desktop-file-utils
48
- - run : make appimage ARCH=x86_64 YQ_ARCH=amd64
43
+ - run : make appimage_deps
44
+ - run : make appimage ARCH=x86_64 YQ_ARCH=amd64 WSHANDLER_VERSION=1.1.1
49
45
- run : make appimage ARCH=aarch64 YQ_ARCH=arm64
50
46
- run : make test WSHANDLER=./build/appimage/wshandler-x86_64.AppImage
Original file line number Diff line number Diff line change 3
3
tags :
4
4
- ' **'
5
5
6
- env :
7
- APT : sudo apt install -y --no-install-recommends
8
-
9
6
jobs :
10
7
appimage :
11
8
runs-on : ubuntu-latest
12
9
steps :
13
10
- uses : actions/checkout@v4
14
- - run : ${APT} desktop-file-utils
15
- - run : make appimage ARCH=x86_64 YQ_ARCH=amd64 VERSION =${{ github.ref_name }}
16
- - run : make appimage ARCH=aarch64 YQ_ARCH=arm64 VERSION =${{ github.ref_name }}
11
+ - run : make appimage_deps
12
+ - run : make appimage ARCH=x86_64 YQ_ARCH=amd64 WSHANDLER_VERSION =${{ github.ref_name }}
13
+ - run : make appimage ARCH=aarch64 YQ_ARCH=arm64 WSHANDLER_VERSION =${{ github.ref_name }}
17
14
- run : ./build/appimage/wshandler-x86_64.AppImage -r tests/update status
18
15
- uses : softprops/action-gh-release@v2
19
16
with :
20
17
files : |
21
18
build/appimage/wshandler*.AppImage
19
+ build/appimage/wshandler*.zsync
20
+ wshandler
22
21
wshandler
23
22
fail_on_unmatched_files : true
Original file line number Diff line number Diff line change @@ -120,13 +120,19 @@ appimage:
120
120
&& tar -xf ' yq_linux_${YQ_ARCH}.tar.gz' -O > " AppDir_${ARCH} /usr/bin/yq" \
121
121
&& chmod +x appimagetool-x86_64.AppImage
122
122
cp wshandler " ${APPDIR} /usr/bin/"
123
+ test -z " ${WSHANDLER_VERSION} " || sed -i -e " s/WSH_VERSION=/WSH_VERSION=${WSHANDLER_VERSION} /g" " ${APPDIR} /usr/bin/wshandler"
123
124
cp appimage/AppRun " ${APPDIR} /AppRun"
124
125
chmod +x " ${APPDIR} /AppRun"
125
126
chmod +x " ${APPDIR} /usr/bin/yq"
126
127
cp appimage/wshandler.png " ${APPDIR} "
127
128
cp appimage/wshandler.desktop " ${APPDIR} "
128
129
# --appimage-extract-and-run to avoid dependency on fuse in CI
129
130
cd build/appimage \
130
- && ./appimagetool-x86_64.AppImage AppDir_${ARCH} wshandler-${ARCH} .AppImage
131
+ && ./appimagetool-x86_64.AppImage \
132
+ --updateinformation " gh-releases-zsync|asherikov|wshandler|latest|wshandler-${ARCH} .AppImage.zsync" \
133
+ AppDir_${ARCH} wshandler-${ARCH} .AppImage
134
+
135
+ appimage_deps :
136
+ sudo apt install -y --no-install-recommends desktop-file-utils zsync
131
137
132
138
.PHONY : appimage
Original file line number Diff line number Diff line change 5
5
set -e
6
6
set -o pipefail
7
7
8
+ WSH_VERSION=
8
9
9
10
help ()
10
11
{
11
12
EXIT_CODE=${1:- " 0" }
12
13
echo " Usage (default values are shown in curly braces):"
13
14
echo " wshandler [<COMMON_ARGS>] [<COMMAND_ARGS>] <COMMAND> <COMMAND_ARGS>"
15
+ if [ -n " ${WSH_VERSION} " ]
16
+ then
17
+ echo " wshandler -v|--version"
18
+ fi
14
19
echo " "
15
20
echo " Notation:"
16
21
echo " <REQUIRED ARGUMENT>"
@@ -724,6 +729,16 @@ WSH_REPOLIST=
724
729
while [[ $# -gt 0 ]]
725
730
do
726
731
case $1 in
732
+ -v|--version)
733
+ if [ -n " ${WSH_VERSION} " ]
734
+ then
735
+ echo " wshandler version: ${WSH_VERSION} "
736
+ exit
737
+ else
738
+ echo " wshandler version is unknown"
739
+ exit 50
740
+ fi ;;
741
+
727
742
-y|--yq)
728
743
WSH_YQ_BINARY=$2
729
744
shift ; shift ;;
You can’t perform that action at this time.
0 commit comments