Skip to content

Commit

Permalink
Add instalation of dependencies to Linux release action
Browse files Browse the repository at this point in the history
  • Loading branch information
hericmar committed Oct 22, 2023
1 parent 0b576f3 commit ecc7956
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 22 deletions.
16 changes: 11 additions & 5 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
name: Release
on:
push:
tags:
- '*'
branches:
- feature/github-actions-build
# tags:
# - '*'

permissions:
contents: write
Expand All @@ -25,18 +27,22 @@ jobs:
steps:
- name: Checkout code
uses: actions/checkout@v2
with:
submodules: 'true'

- name: Install Linux dependencies
if: matrix.kind == 'Linux'
run: |
sudo apt-get install -y build-essential \
sudo apt-get install -y build-essential g++-12 libgl-dev libopengl0 libxrandr-dev libxinerama-dev libxcursor-dev libxi-dev
sudo rm -f /usr/bin/g++
sudo ln /usr/bin/g++-12 /usr/bin/g++
- name: Build and create archive
shell: bash
run: |
cmake -S . -B build -DCMAKE_BUILD_TYPE=Release
cmake --build build --config Release
Scripts/CreateBundle.sh --postfix ${{ matrix.kind }} Release
cmake --build build --config Release --target I3T
bash Scripts/CreateBundle.sh --postfix ${{ matrix.kind }} Release
- name: Publish
uses: softprops/action-gh-release@v1
Expand Down
15 changes: 0 additions & 15 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -86,21 +86,6 @@ test:

###

release:
stage: release
only:
- master
script:
- mkdir relase-out && cd release-out
- cmake -DCMAKE_BUILD_TYPE=Release ..
- cmake --build . -j 8 --target I3T
- bash Scripts/CreateBundle.sh
artifacts:
paths:
- I3T*.zip
dependencies:
- test

pass:
script:
- echo "Pipeline passed"
4 changes: 2 additions & 2 deletions Scripts/CreateBundle.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash -e
#!/bin/bash -ex

FILES="Data Config.json LICENSE.txt"

Expand Down Expand Up @@ -79,7 +79,7 @@ function process_args() {

function zip_cmd() {
if [ $IS_UNIX_LIKE = 1 ]; then
zip --recurse --junk-paths "$@"
zip -r "$@"
elif [ $IS_WINDOWS = 1 ]; then
7z a -tzip "$@"
fi
Expand Down

0 comments on commit ecc7956

Please sign in to comment.