-
Notifications
You must be signed in to change notification settings - Fork 212
65 lines (57 loc) · 1.87 KB
/
build.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
name: Build and Release
on:
push:
branches:
- master
pull_request:
branches:
- master
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
jobs:
build:
runs-on: ${{ matrix.config.runner }}
strategy:
matrix:
config:
- runner: ubuntu-20.04
image: ubuntu:20.04
- runner: ubuntu-22.04-arm
image: ubuntu:22.04
container:
image: ${{ matrix.config.image }}
options: --privileged
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Print configuration
run: echo "Running build on ${{ matrix.config }}"
- name: Install dependencies
run: |
apt-get update
apt-get install -y sudo libarchive-tools curl zsync squashfs-tools aria2 desktop-file-utils wget fuse binutils file imagemagick git
- name: Test to create neoVim AppImage
run: |
chmod +x ./out/pkg2appimage*.AppImage*
./out/pkg2appimage*.AppImage* recipes/neovim.yml
- name: Verify AppImage Creation and Test
run: |
if ls out/neovim-*.AppImage 1> /dev/null 2>&1; then
echo "Neovim AppImage successfully created."
./out/neovim-*.AppImage --version | tee version_output.txt
if grep -q "NVIM" version_output.txt && grep -q "Build type: Release" version_output.txt; then
echo "Neovim AppImage test passed."
else
echo "Neovim AppImage test failed: Version output is incorrect." >&2
exit 1
fi
else
echo "Failed to create Neovim AppImage." >&2
exit 1
fi
- name: Release
run: |
export TRAVIS_BUILD_NUMBER=$(git rev-parse --short HEAD)
export VERSION=$(git rev-parse --short HEAD)
wget -c https://github.com/probonopd/uploadtool/raw/master/upload.sh
bash upload.sh ./out/pkg2appimage*.AppImage*