Skip to content

Deal with case where validators.app returns null values we weren't ex… #416

Deal with case where validators.app returns null values we weren't ex…

Deal with case where validators.app returns null values we weren't ex… #416

Workflow file for this run

on:
push:
branches: [ master ]
tags:
- '*'
env:
CARGO_TERM_COLOR: always
jobs:
build_release:
strategy:
matrix:
include:
- target: x86_64-unknown-linux-gnu
os: ubuntu-20.04
- target: x86_64-apple-darwin
os: macos-latest
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2
- if: startsWith(matrix.os, 'ubuntu')
run: |
sudo apt-get update
sudo apt-get install -y libudev-dev
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
components: rustfmt, clippy
- name: cargo build --release
uses: actions-rs/cargo@v1
with:
command: build
args: --release
- run: |
mv target/release/solana-stake-o-matic solana-stake-o-matic-${{ matrix.target }}
mv target/release/solana-foundation-delegation-program solana-foundation-delegation-program-${{ matrix.target }}
- uses: actions/upload-artifact@v2
with:
name: ${{ matrix.target }}
path: |
solana-stake-o-matic-${{ matrix.target }}
solana-foundation-delegation-program-${{ matrix.target }}
if-no-files-found: error
publish_release:
needs: build_release
runs-on: ubuntu-20.04
steps:
- uses: actions/download-artifact@v2
- if: startsWith(github.ref, 'refs/tags/')
uses: softprops/action-gh-release@v1
with:
files: |
x86_64-apple-darwin/solana-stake-o-matic-x86_64-apple-darwin
x86_64-unknown-linux-gnu/solana-stake-o-matic-x86_64-unknown-linux-gnu
x86_64-apple-darwin/solana-foundation-delegation-program-x86_64-apple-darwin
x86_64-unknown-linux-gnu/solana-foundation-delegation-program-x86_64-unknown-linux-gnu
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- if: startsWith(github.ref, 'refs/heads/master')
run: |
set -x
mkdir master-bin
mv x86_64-apple-darwin/* master-bin/
mv x86_64-unknown-linux-gnu/* master-bin/
cd master-bin
git init .
git config --local user.email "41898282+github-actions[bot]@users.noreply.github.com"
git config --local user.name "github-actions[bot]"
git add *
git commit -m "Build artifacts from $GITHUB_SHA" --allow-empty
- if: startsWith(github.ref, 'refs/heads/master')
uses: ad-m/[email protected]
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: master-bin
directory: master-bin
force: true