Separate check scripts to their own repository (#567)
* Remove scripts * Update workflows to use checks repo * Add explanation about naming of base branch This only concerns private tests with PRs created against a base branch in another non-official repo. * Fix checkout paths * Move TESTING to a less confusing location
This commit is contained in:
committed by
GitHub
parent
41589135c3
commit
23ba528593
@@ -0,0 +1,10 @@
|
||||
The name of the branch plays a role in the tests run when changes are
|
||||
submitted. For this reason, when modifying the workflows in ./.github, if you
|
||||
want to test them prior to submission, the PR must be tested against a branch that
|
||||
exists also in the `alire-index-checks` repo, e.g., 'stable-1.2' or 'devel-1.2'
|
||||
|
||||
Normally you'll want to use the latest stable or devel branch.
|
||||
|
||||
E.g., if you modify a workflow in the `alire-index` repo and want to test it
|
||||
privately, you can do so in your own account, but using the same `stable-x.x`
|
||||
base branch for your private PR.
|
||||
@@ -1,5 +1,11 @@
|
||||
# Please read the TESTING file before modifying this file
|
||||
|
||||
name: Build Crate
|
||||
|
||||
env:
|
||||
CHECKS_ORG: alire-project
|
||||
CHECKS_REPO: alire-index-checks
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
paths:
|
||||
@@ -59,6 +65,13 @@ jobs:
|
||||
# changed files detectors (in both scripts/gh-build-crate.sh and
|
||||
# check-author action).
|
||||
|
||||
- name: Check out alire-index-checks
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
repository: ${{env.CHECKS_ORG}}/${{env.CHECKS_REPO}}
|
||||
ref: ${{github.base_ref}}
|
||||
path: ${{env.CHECKS_REPO}}
|
||||
|
||||
- name: Update system repositories
|
||||
if: matrix.os == 'ubuntu-latest'
|
||||
run: sudo apt update
|
||||
@@ -93,7 +106,7 @@ jobs:
|
||||
uses: mosteo/actions@docker-run/v1
|
||||
with:
|
||||
image: alire/gnat:${{matrix.tag}}
|
||||
command: scripts/gh-build-crate.sh
|
||||
command: ${{env.CHECKS_REPO}}/scripts/gh-build-crate.sh
|
||||
params: -v ${{ github.workspace }}/alire_install/bin/alr:/usr/bin/alr
|
||||
|
||||
- name: Install tar from msys2 (Windows) # Git tar in Actions VM does not seem to work)
|
||||
@@ -102,5 +115,5 @@ jobs:
|
||||
|
||||
- name: Test crate (Windows/MacOS)
|
||||
if: matrix.os != 'ubuntu-latest' # native testing in Windows/MacOS
|
||||
run: scripts/gh-build-crate.sh
|
||||
run: ${{env.CHECKS_REPO}}/scripts/gh-build-crate.sh
|
||||
shell: bash
|
||||
|
||||
@@ -1,6 +1,12 @@
|
||||
# Please read the TESTING file before modifying this file
|
||||
|
||||
name: Toolchain
|
||||
# Build the submitted crate with a native toolchain from Alire
|
||||
|
||||
env:
|
||||
CHECKS_ORG: alire-project
|
||||
CHECKS_REPO: alire-index-checks
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
paths:
|
||||
@@ -30,6 +36,13 @@ jobs:
|
||||
# changed files detectors (in both scripts/gh-build-crate.sh and
|
||||
# check-author action).
|
||||
|
||||
- name: Check out alire-index-checks
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
repository: ${{env.CHECKS_ORG}}/${{env.CHECKS_REPO}}
|
||||
ref: ${{github.base_ref}}
|
||||
path: ${{env.CHECKS_REPO}}
|
||||
|
||||
# For the devel branch we need a compiler available to build alr in
|
||||
# setup-alire. We will be able to get rid of this once composite actions
|
||||
# support conditional steps.
|
||||
@@ -63,5 +76,5 @@ jobs:
|
||||
run: C:\Users\runneradmin\.cache\alire\msys64\usr\bin\pacman --noconfirm -S tar
|
||||
|
||||
- name: Test crate
|
||||
run: scripts/gh-build-crate.sh
|
||||
run: ${{env.CHECKS_REPO}}/scripts/gh-build-crate.sh
|
||||
shell: bash
|
||||
|
||||
@@ -1,8 +1,14 @@
|
||||
# Please read the TESTING file before modifying this file
|
||||
|
||||
# Show differences between the submitted manifest and the previous
|
||||
# release of the same crate, to enable easier catching of problems
|
||||
|
||||
name: Diff release
|
||||
|
||||
env:
|
||||
CHECKS_ORG: alire-project
|
||||
CHECKS_REPO: alire-index-checks
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
paths:
|
||||
@@ -23,6 +29,13 @@ jobs:
|
||||
# need the full history or else grafted partial branches confuse the
|
||||
# changed files detector
|
||||
|
||||
- name: Check out alire-index-checks
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
repository: ${{env.CHECKS_ORG}}/${{env.CHECKS_REPO}}
|
||||
ref: ${{github.base_ref}}
|
||||
path: ${{env.CHECKS_REPO}}
|
||||
|
||||
- name: Set up stable `alr`
|
||||
if: contains(github.base_ref, 'stable-')
|
||||
uses: alire-project/setup-alire@v1
|
||||
@@ -49,5 +62,5 @@ jobs:
|
||||
branch: master
|
||||
|
||||
- name: Diff releases
|
||||
run: scripts/diff-release.sh || true # No deal breaker if failed
|
||||
run: ${{env.CHECKS_REPO}}/scripts/diff-release.sh || true # No deal breaker if failed
|
||||
shell: bash
|
||||
|
||||
Reference in New Issue
Block a user