1
Fork 0
mirror of https://github.com/RGBCube/nu_scripts synced 2025-08-01 06:37:46 +00:00

add a nu-check verification CI (#771)

I made a `toolkit.nu` with a very bare bones struct, this is called via
[`setup-nu`](https://github.com/hustcer/setup-nu) action, and generates
the `check-files.nu` file. After that, another nu instance run that
script to check files one by one. The folder `before_v0.60/` is
excluded.
This commit is contained in:
Auca Coyan 2024-03-12 16:48:08 -03:00 committed by GitHub
parent 45f5310e51
commit c2ef662e48
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 128 additions and 0 deletions

29
.github/workflows/ci.yml vendored Normal file
View file

@ -0,0 +1,29 @@
on:
pull_request:
env:
NUSHELL_CARGO_PROFILE: ci
NU_LOG_LEVEL: DEBUG
jobs:
nu-check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: 'Fetch main branch'
run: |
git fetch origin main --depth 1
- uses: hustcer/setup-nu@v3.9
with:
version: '*'
check-latest: true
features: full # dataframe and extra included
- name: toolkit check pr
shell: nu {0}
run: |
nu -c "use toolkit.nu *; check pr"
- name: run nu-check on modified files
shell: nu {0}
run: |
nu ./check-files.nu

33
.github/workflows/daily.yml vendored Normal file
View file

@ -0,0 +1,33 @@
on:
push:
branches:
- main
schedule:
- cron: '30 0 * * *' # every day at 00:30 AM UTC
env:
NUSHELL_CARGO_PROFILE: ci
NU_LOG_LEVEL: DEBUG
jobs:
nu-check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: 'Fetch main branch'
run: |
git fetch origin main --depth 1
- uses: hustcer/setup-nu@v3.9
with:
version: '*'
check-latest: true
features: full # dataframe and extra included
- name: toolkit generate-file-list --full
shell: nu {0}
run: |
nu -c "use toolkit.nu *; generate-file-list --full"
- name: run nu-check on all files
shell: nu {0}
run: |
nu ./check-files.nu