forgejo/ci: run build in pazof/yavsc-build-env container #17
1 changed files with 5 additions and 7 deletions
ci: drop working-directory, cd into /src/_src explicitly
forgejo-runner v13 does not interpolate ${{ runner.workspace }}
in working-directory: (or ignores the field entirely for docker
containers), so the container tried to chdir to '/_src' (literally)
which does not exist.
The image WORKDIR is /src, so clone directly into /src/_src and cd
into it at the start of each step. Adds an echo of the checkout
SHA + branch state for visibility in the log.
commit
5f50135c7f
|
|
@ -42,7 +42,7 @@ jobs:
|
||||||
steps:
|
steps:
|
||||||
- name: Clone yavsc
|
- name: Clone yavsc
|
||||||
run: |
|
run: |
|
||||||
cd "$RUNNER_WORKSPACE"
|
cd /src
|
||||||
git clone https://forgejo.pschneider.fr/notazof/yavsc.git _src
|
git clone https://forgejo.pschneider.fr/notazof/yavsc.git _src
|
||||||
cd _src
|
cd _src
|
||||||
if [ -n "${GITHUB_REF:-}" ]; then
|
if [ -n "${GITHUB_REF:-}" ]; then
|
||||||
|
|
@ -50,12 +50,10 @@ jobs:
|
||||||
git checkout FETCH_HEAD
|
git checkout FETCH_HEAD
|
||||||
fi
|
fi
|
||||||
git submodule update --init --recursive --depth 1
|
git submodule update --init --recursive --depth 1
|
||||||
|
echo "Checked out at $(git rev-parse HEAD) on $(git branch --show-current 2>/dev/null || echo detached HEAD)"
|
||||||
- name: Restore dependencies
|
- name: Restore dependencies
|
||||||
working-directory: ${{ runner.workspace }}/_src
|
run: cd /src/_src && dotnet restore
|
||||||
run: dotnet restore
|
|
||||||
- name: Build
|
- name: Build
|
||||||
working-directory: ${{ runner.workspace }}/_src
|
run: cd /src/_src && dotnet build --no-restore
|
||||||
run: dotnet build --no-restore
|
|
||||||
- name: Test
|
- name: Test
|
||||||
working-directory: ${{ runner.workspace }}/_src
|
run: cd /src/_src && dotnet test --no-build --verbosity normal
|
||||||
run: dotnet test --no-build --verbosity normal
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue