Skip to content

Commit

Permalink
Automatic binary deployment
Browse files Browse the repository at this point in the history
  • Loading branch information
agudys authored Aug 30, 2024
1 parent 5ed7787 commit d8d133a
Showing 1 changed file with 88 additions and 0 deletions.
88 changes: 88 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,88 @@
name: Deploy

on:
release:
types:
- created

jobs:


########################################################################################
checkout:
name: Checkout
strategy:
matrix:
machine: [x64_linux, x64_mac, arm64_linux, arm64_mac]
runs-on: [self-hosted, clusty, '${{ matrix.machine }}']

steps:
- uses: actions/checkout@v4
with:
submodules: recursive
- name: Get tags
run: |
cd ./libs/igraph
echo exit code $?
git tag --list
########################################################################################
make:
name: Make
needs: checkout
strategy:
fail-fast: false
matrix:
machine: [x64_linux, arm64_linux]
leiden: [true]
include:
- machine: x64_mac
leiden: false
- machine: arm64_mac
leiden: false

runs-on: [self-hosted, clusty, '${{ matrix.machine }}']

steps:
- name: make
run: |
make clean
make -j32 CXX=g++-12 STATIC_LINK=true LEIDEN=${{ matrix.leiden }}
- name: tar artifacts
run: tar -cvzf clusty.tar.gz clusty LICENSE


########################################################################################
help:
name: Print usage
needs: make
strategy:
fail-fast: false
matrix:
machine: [x64_linux, x64_mac, arm64_linux, arm64_mac]
runs-on: [self-hosted, clusty, '${{ matrix.machine }}']

steps:
- name: help
run: ./clusty

########################################################################################
upload:
name: Upload
needs: help
strategy:
fail-fast: false
matrix:
machine: [x64_linux, x64_mac, arm64_linux, arm64_mac]
runs-on: [self-hosted, clusty, '${{ matrix.machine }}']

steps:
- name: deploy
uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ./clusty.tar.gz
asset_name: clusty-${{ github.event.release.tag_name }}-${{matrix.machine}}.tar.gz
asset_content_type: application/gzip

0 comments on commit d8d133a

Please sign in to comment.