diff --git a/.github/workflows/ares-feature.yml b/.github/workflows/ares-feature.yml new file mode 100644 index 0000000..4020531 --- /dev/null +++ b/.github/workflows/ares-feature.yml @@ -0,0 +1,14 @@ +name: 'Ares: Pull request' + +on: + pull_request: + paths: + - '.github/workflows/ares-feature.yml' + - '.github/workflows/ares-shared.yml' + - 'rust/ares/**' + - 'rust/ares_macros/**' + - 'rust/ibig-rs/**' + +jobs: + urbit: + uses: ./.github/workflows/ares-shared.yml diff --git a/.github/workflows/ares-shared.yml b/.github/workflows/ares-shared.yml new file mode 100644 index 0000000..4f079ef --- /dev/null +++ b/.github/workflows/ares-shared.yml @@ -0,0 +1,27 @@ +on: + workflow_call: + +env: + CARGO_TERM_COLOR: always + +defaults: + run: + working-directory: rust/ares + +jobs: + build: + strategy: + matrix: + os: [ 'ubuntu-latest', 'macos-latest' ] + runs-on: ${{ matrix.os }} + steps: + - uses: actions/checkout@v3 + + - name: Format + run: cargo fmt --check + + - name: Build + run: cargo build --verbose + + - name: Run tests + run: cargo test --verbose diff --git a/.github/workflows/ares-status.yml b/.github/workflows/ares-status.yml new file mode 100644 index 0000000..815113b --- /dev/null +++ b/.github/workflows/ares-status.yml @@ -0,0 +1,16 @@ +name: 'Ares: Push to status' + +on: + push: + branches: + - status + paths: + - '.github/workflows/ares-shared.yml' + - '.github/workflows/ares-status.yml' + - 'rust/ares/**' + - 'rust/ares_macros/**' + - 'rust/ibig-rs/**' + +jobs: + urbit: + uses: ./.github/workflows/ares-shared.yml diff --git a/.github/workflows/ares.yml b/.github/workflows/ares.yml deleted file mode 100644 index e0883c6..0000000 --- a/.github/workflows/ares.yml +++ /dev/null @@ -1,28 +0,0 @@ -name: Ares - -on: - push: - branches: [ "status" ] - pull_request: - branches: [ "status" ] - -env: - CARGO_TERM_COLOR: always - -defaults: - run: - working-directory: rust/ares - -jobs: - build: - - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v3 - - name: Format - run: cargo fmt --check - - name: Build - run: cargo build --verbose - - name: Run tests - run: cargo test --verbose