-
Notifications
You must be signed in to change notification settings - Fork 9
70 lines (64 loc) · 1.84 KB
/
run-test.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
name: Develop and Release Test
on:
push:
branches:
- main
- develop
- release/*
paths-ignore:
- '**.md'
defaults:
run:
shell: nu {0}
jobs:
test-latest:
strategy:
matrix:
os: [ubuntu-22.04, macos-latest, windows-latest]
runs-on: ${{ matrix.os }}
name: test (${{matrix.os}}, setup-nu@latest-dev)
steps:
- uses: actions/checkout@v3
- name: Setup nu@latest
uses: hustcer/setup-nu@develop
with:
check-latest: true
enable-plugins: true
env:
ACTIONS_STEP_DEBUG: true
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: You can run bash commands, too
run: pwd && ls -la
shell: bash
- name: Default shell will be `nu`
run: |
print $'Nu version info:(char nl)'; print (version)
print $'Current env:(char nl)'; print $env
print 'Current NU_LIB_DIRS:'
print $env.NU_LIB_DIRS
print $'Nu path:(which nu)(char nl)'
print $"(char nl)Dir contents:(char nl)"; print (ls ((which nu).path.0 | path dirname))
def greeting [name: string] {
print $'Hello ($name)'
}
greeting hustcer
test-ver:
strategy:
matrix:
os: [ubuntu-22.04, macos-latest, windows-latest]
runs-on: ${{ matrix.os }}
name: test (${{matrix.os}}, [email protected])
steps:
- uses: actions/checkout@v3
- name: Setup nu@latest
uses: hustcer/[email protected]
with:
version: v0.80
enable-plugins: true
env:
ACTIONS_STEP_DEBUG: true
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- run: print $'Nu version info:(char nl)'; version
- run: print $'Current env:(char nl)'; $env
- run: print $'Nu path:(which nu)(char nl)'
- run: print $"(char nl)Dir contents:(char nl)"; ls ((which nu).path.0 | path dirname)