mirror of
https://github.com/roc-lang/roc.git
synced 2025-12-23 08:48:03 +00:00
* new compiler CI init * update name Signed-off-by: Anton-4 <17049058+Anton-4@users.noreply.github.com> * altered exe check * add macos dynamic dep check * add windows too * use builtin windows tools * ci_manager changes * move devtools too * fix deadlock * moved md link check * correct filename Signed-off-by: Anton-4 <17049058+Anton-4@users.noreply.github.com> * correct filename Signed-off-by: Anton-4 <17049058+Anton-4@users.noreply.github.com> * correct trigger Signed-off-by: Anton-4 <17049058+Anton-4@users.noreply.github.com> * fixed call_old_workflow if * naming fix * add output * fix finish if Signed-off-by: Anton-4 <17049058+Anton-4@users.noreply.github.com> * zig CI test change * fix auto cancellation * fix finish if * new compiler CI init update name Signed-off-by: Anton-4 <17049058+Anton-4@users.noreply.github.com> altered exe check add macos dynamic dep check add windows too use builtin windows tools ci_manager changes move devtools too fix deadlock moved md link check correct filename Signed-off-by: Anton-4 <17049058+Anton-4@users.noreply.github.com> correct filename Signed-off-by: Anton-4 <17049058+Anton-4@users.noreply.github.com> correct trigger Signed-off-by: Anton-4 <17049058+Anton-4@users.noreply.github.com> fixed call_old_workflow if naming fix add output fix finish if Signed-off-by: Anton-4 <17049058+Anton-4@users.noreply.github.com> zig CI test change fix auto cancellation fix finish if --------- Signed-off-by: Anton-4 <17049058+Anton-4@users.noreply.github.com>
51 lines
1.9 KiB
YAML
51 lines
1.9 KiB
YAML
on:
|
|
workflow_call:
|
|
|
|
name: devtools nix files test - linux
|
|
|
|
jobs:
|
|
devtools-test-linux:
|
|
name: devtools-test-linux
|
|
runs-on: [ubuntu-20.04]
|
|
timeout-minutes: 120
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Only run all steps if a nix file changed
|
|
run: |
|
|
git fetch origin ${{ github.base_ref }}
|
|
if git diff --name-only origin/${{ github.base_ref }} HEAD | grep 'nix'; then
|
|
echo "A nix file was changed. Testing devtools nix files..."
|
|
echo "nix_changed=true" >> $GITHUB_ENV
|
|
else
|
|
echo "A nix file was changed. No need to run tests."
|
|
echo "nix_changed=false" >> $GITHUB_ENV
|
|
fi
|
|
|
|
|
|
- uses: cachix/install-nix-action@v23
|
|
if: env.nix_changed == 'true'
|
|
with:
|
|
nix_path: nixpkgs=channel:nixos-unstable
|
|
|
|
- name: test devtools/flake.nix
|
|
if: env.nix_changed == 'true'
|
|
id: devtools_test_step
|
|
run: |
|
|
sed -i "s|/home/username/gitrepos/roc|$(realpath .)|g" devtools/flake.nix
|
|
cat devtools/flake.nix
|
|
mkdir -p ../temp
|
|
cp devtools/flake.nix ../temp
|
|
cp devtools/flake.lock ../temp
|
|
cd ../temp
|
|
git init
|
|
git add flake.nix flake.lock
|
|
nix develop
|
|
|
|
- name: Print tip on fail
|
|
if: steps.devtools_test_step.outcome == 'failure'
|
|
run: |
|
|
echo "The devtools test failed, this can likely be fixed by"
|
|
echo "locally deleting devtools/flake.lock and following the"
|
|
echo "instructions in devtools/README.md. This will create a"
|
|
echo "new flake.lock you should use to replace the old devtools/flake.lock"
|