This repository has been archived by the owner on Sep 16, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
67 lines (62 loc) · 1.67 KB
/
ci.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
66
67
name: CMake
on:
push:
branches: [ "*" ]
tags: [ "*" ]
pull_request:
branches: [ master ]
env:
BUILD_TYPE: Release
jobs:
build:
runs-on: ubuntu-latest
container: 'debian:buster-backports'
steps:
- name: Install Dependencies
shell: bash
run: |
apt-get update
apt-get install -y git python3 libsqlite3-dev libpython3-dev ninja-build build-essential
apt-get -t buster-backports install -y cmake
- uses: actions/checkout@v2
with:
submodules: recursive
- name: Query tag name
uses: little-core-labs/[email protected]
- name: Build
env:
CFLAGS: '-flto -O3 -march=znver1'
shell: bash
run: ./.ci/build.sh
- name: Upload
uses: actions/upload-artifact@v2
with:
name: artifacts
path: |
build/*.tar*
build/*.deb
build/*.sha256
release:
runs-on: ubuntu-latest
needs: [build]
if: ${{ startsWith(github.ref, 'refs/tags/') }}
steps:
- uses: actions/[email protected]
- name: Query tag name
uses: little-core-labs/[email protected]
id: tagName
- name: Create release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ steps.tagName.outputs.tag }}
release_name: ${{ steps.tagName.outputs.tag }}
draft: false
prerelease: false
- name: Upload artifacts
uses: alexellis/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
asset_paths: '["./**/*.tar.xz","./**/*.deb", "./**/*.sha256"]'