Skip to content

Commit

Permalink
Add regression test action (#2)
Browse files Browse the repository at this point in the history
Add regression to build html documentation

Signed-off-by: dhower-qc <[email protected]>
  • Loading branch information
dhower-qc authored Jul 15, 2024
1 parent 04c6e42 commit 7be4248
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 5 deletions.
21 changes: 19 additions & 2 deletions .github/workflows/regress.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,24 @@ jobs:
uses: actions/checkout@v4
- name: Setup apptainer
uses: eWaterCycle/[email protected]
- name: Get container from cache
id: cache-sif
uses: actions/cache@v3
with:
path: .singularity/image.sif
key: ${{ hashFiles('container.def') }}
- name: Get gems and node files from cache
id: cache-bundle-npm
uses: actions/cache@v3
with:
path: |
.home/.gems
node_modules
key: ${{ hashFiles('Gemfile.lock') }}-${{ hashFiles('package-lock.json') }}
- if: ${{ steps.cache-sif.outputs.cache-hit != 'true' }}
name: Build container
run: ./bin/build_container
- name: Setup project
run: apptainer run --home ${{ github.workspace }}/.home oras://docker.io/riscvintl/spec-generator:0.1 ./bin/setup
run: ./bin/setup
- name: Build html documentation for generic_rv64
run: apptainer run --home ${{ github.workspace }}/.home oras://docker.io/riscvintl/spec-generator:0.1 bundle exec rake gen:html[generic_rv64]
run: ./do gen:html[generic_rv64]
2 changes: 1 addition & 1 deletion bin/build_container
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ if [ $NEED_SUDO -eq 0 ]; then
FAKEROOT=--fakeroot
echo "Using fakeroot"
else
if [[ `groups` == *"sudo"* ]]; then
if [[ ! -z "$GITHUB_RUN_ID" || `groups` == *"sudo"* ]]; then
# user has sudo permission
SUDO=sudo
FAKEROOT=""
Expand Down
2 changes: 1 addition & 1 deletion bin/setup
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ if [ ! -d $ROOT/.home/.gems ]; then
fi

if [ ! -f $ROOT/ext/riscv-opcodes/README.md ]; then
git submodule init --update ext/riscv-opcodes
git submodule update --init ext/riscv-opcodes
fi

if [[ ! -z "$DEVELOPMENT" && $DEVELOPMENT -eq 1 ]]; then
Expand Down
2 changes: 1 addition & 1 deletion cfgs/generic_rv64/arch_overlay/csr/marchid.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@
marchid:
fields:
Architecture:
description: My custom description.
description: Custom overlay description

0 comments on commit 7be4248

Please sign in to comment.