1
0
mirror of synced 2024-12-01 02:37:18 +01:00

git: Fixed CI, updated all env var names

This commit is contained in:
WerWolv 2022-07-18 20:13:01 +02:00
parent 51f2b24daa
commit 80d47b658e
2 changed files with 11 additions and 10 deletions

View File

@ -164,7 +164,7 @@ jobs:
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache \ -DCMAKE_CXX_COMPILER_LAUNCHER=ccache \
-DCMAKE_OBJC_COMPILER_LAUNCHER=ccache \ -DCMAKE_OBJC_COMPILER_LAUNCHER=ccache \
-DCMAKE_OBJCXX_COMPILER_LAUNCHER=ccache \ -DCMAKE_OBJCXX_COMPILER_LAUNCHER=ccache \
-DIMHEX_PATTERNS_PULL_MASTER \ -DIMHEX_PATTERNS_PULL_MASTER=ON \
.. ..
make -j4 package make -j4 package
@ -243,7 +243,7 @@ jobs:
- name: 📜 Set version variable - name: 📜 Set version variable
run: | run: |
echo "version=`cat VERSION`" >> $GITHUB_ENV echo "IMHEX_VERSION=`cat VERSION`" >> $GITHUB_ENV
#- name: 📦 Bundle Flatpak #- name: 📦 Bundle Flatpak
# run: | # run: |
@ -258,14 +258,14 @@ jobs:
run: | run: |
cp -r build/DEBIAN build/AppDir cp -r build/DEBIAN build/AppDir
dpkg-deb --build build/AppDir dpkg-deb --build build/AppDir
mv build/AppDir.deb imhex-${{env.version}}.deb mv build/AppDir.deb imhex-${{env.IMHEX_VERSION}}.deb
rm -rf build/AppDir/DEBIAN rm -rf build/AppDir/DEBIAN
- name: 📦 Bundle AppImage - name: 📦 Bundle AppImage
run: | run: |
cd build cd build
appimage-builder --recipe ../dist/AppImageBuilder.yml appimage-builder --recipe ../dist/AppImageBuilder.yml
mv ImHex-AppImage-x86_64.AppImage ../imhex-${{env.version}}.AppImage mv ImHex-AppImage-x86_64.AppImage ../imhex-${{env.IMHEX_VERSION}}.AppImage
cd .. cd ..
#- name: ⬆️ Upload Flatpak #- name: ⬆️ Upload Flatpak
@ -339,7 +339,7 @@ jobs:
-DCMAKE_C_FLAGS="-fuse-ld=lld" \ -DCMAKE_C_FLAGS="-fuse-ld=lld" \
-DCMAKE_CXX_FLAGS="-fuse-ld=lld" \ -DCMAKE_CXX_FLAGS="-fuse-ld=lld" \
-DRUST_PATH="$HOME/.cargo/bin/" \ -DRUST_PATH="$HOME/.cargo/bin/" \
-DIMHEX_PATTERNS_PULL_MASTER \ -DIMHEX_PATTERNS_PULL_MASTER=ON \
.. ..
make -j 4 install DESTDIR=installDir make -j 4 install DESTDIR=installDir
@ -350,7 +350,7 @@ jobs:
- name: ✒️ Prepare PKGBUILD - name: ✒️ Prepare PKGBUILD
run: | run: |
cp dist/Arch/PKGBUILD build cp dist/Arch/PKGBUILD build
sed -i 's/%version%/${{env.version}}/g' build/PKGBUILD sed -i 's/%version%/${{env.IMHEX_VERSION}}/g' build/PKGBUILD
# makepkg doesn't want to run as root, so I had to chmod 777 all over # makepkg doesn't want to run as root, so I had to chmod 777 all over
- name: 📦 Package ArchLinux .pkg.tar.zst - name: 📦 Package ArchLinux .pkg.tar.zst
@ -359,20 +359,20 @@ jobs:
# the name is a small trick to make makepkg recognize it as the source # the name is a small trick to make makepkg recognize it as the source
# else, it would try to download the file from the release # else, it would try to download the file from the release
tar -cvf imhex-${{env.version}}-ArchLinux.pkg.tar.zst -C installDir . tar -cvf imhex-${{env.IMHEX_VERSION}}-ArchLinux.pkg.tar.zst -C installDir .
chmod -R 777 . chmod -R 777 .
sudo -u nobody makepkg sudo -u nobody makepkg
# Remplace the old file # Remplace the old file
rm imhex-${{env.version}}-ArchLinux.pkg.tar.zst rm imhex-${{env.IMHEX_VERSION}}-ArchLinux.pkg.tar.zst
mv *.pkg.tar.zst imhex-${{env.version}}-ArchLinux.pkg.tar.zst mv *.pkg.tar.zst imhex-${{env.IMHEX_VERSION}}-ArchLinux.pkg.tar.zst
- name: ⬆️ Upload imhex-archlinux.pkg.tar.zst - name: ⬆️ Upload imhex-archlinux.pkg.tar.zst
uses: actions/upload-artifact@v3 uses: actions/upload-artifact@v3
with: with:
name: ArchLinux .pkg.tar.zst name: ArchLinux .pkg.tar.zst
path: | path: |
build/imhex-${{env.version}}-ArchLinux.pkg.tar.zst build/imhex-${{env.IMHEX_VERSION}}-ArchLinux.pkg.tar.zst

View File

@ -295,6 +295,7 @@ function(downloadImHexPatternsFiles dest)
set(PATTERNS_BRANCH master) set(PATTERNS_BRANCH master)
else () else ()
set(PATTERNS_BRANCH ImHex-v${IMHEX_VERSION}) set(PATTERNS_BRANCH ImHex-v${IMHEX_VERSION})
endif ()
FetchContent_Declare( FetchContent_Declare(
imhex_patterns imhex_patterns