1 | name: Path Testing CI |
2 | |
3 | on: |
4 | push: |
5 | paths-ignore: |
6 | - "**.md" |
7 | pull_request: |
8 | paths-ignore: |
9 | - "**.md" |
10 | |
11 | concurrency: |
12 | group: build-paths-${{ github.event.pull_request.number || github.sha }} |
13 | cancel-in-progress: true |
14 | |
15 | jobs: |
16 | |
17 | space-paths-linux: |
18 | runs-on: ubuntu-20.04 |
19 | if: github.event_name != 'push' || github.event.ref == 'refs/heads/master' || github.event.repository.full_name != 'vlang/v' |
20 | timeout-minutes: 30 |
21 | env: |
22 | MY_V_PATH: '你好 my $path, @с интервали' |
23 | steps: |
24 | - uses: actions/checkout@v3 |
25 | with: |
26 | path: ${{env.MY_V_PATH}} |
27 | - name: Build V |
28 | run: | |
29 | echo '${{env.MY_V_PATH}}' |
30 | ls -la |
31 | cd '${{env.MY_V_PATH}}' |
32 | ls -la |
33 | make |
34 | - name: v doctor |
35 | run: | |
36 | cd '${{env.MY_V_PATH}}' |
37 | ./v doctor |
38 | - name: v tests |
39 | run: | |
40 | cd '${{env.MY_V_PATH}}' |
41 | ./v test vlib/builtin vlib/os |
42 | |
43 | space-paths-macos: |
44 | runs-on: macOS-latest |
45 | if: github.event_name != 'push' || github.event.ref == 'refs/heads/master' || github.event.repository.full_name != 'vlang/v' |
46 | timeout-minutes: 30 |
47 | env: |
48 | MY_V_PATH: '你好 my $path, @с интервали' |
49 | steps: |
50 | - uses: actions/checkout@v3 |
51 | with: |
52 | path: ${{env.MY_V_PATH}} |
53 | - name: Build V |
54 | run: | |
55 | echo '${{env.MY_V_PATH}}' |
56 | ls -la |
57 | cd '${{env.MY_V_PATH}}' |
58 | ls -la |
59 | make |
60 | ## prebuild cmd/tools/builders/js_builder, to minimise the |
61 | ## chances of a sporadic "Killed" when running the tests later |
62 | ./v -b js run examples/hello_world.v |
63 | - name: v doctor |
64 | run: | |
65 | cd '${{env.MY_V_PATH}}' |
66 | ./v doctor |
67 | - name: v tests |
68 | run: | |
69 | cd '${{env.MY_V_PATH}}' |
70 | ./v test vlib/builtin vlib/os |
71 | |
72 | space-paths-windows: |
73 | runs-on: windows-2022 |
74 | if: github.event_name != 'push' || github.event.ref == 'refs/heads/master' || github.event.repository.full_name != 'vlang/v' |
75 | timeout-minutes: 30 |
76 | env: |
77 | MY_V_PATH: 'path with some $punctuation, and some spaces' |
78 | |
79 | ## NB: the following paths do not work for now: |
80 | ##### MY_V_PATH: '你好 my $path, @с интервали' |
81 | ##### MY_V_PATH: 'path with some $punctuation, and some spaces ' |
82 | ## tcc has a problem interpreting paths with non latin letters in them, |
83 | ## by default, but that can be solved with passing -Bthirdparty/tcc |
84 | ## but after that V fails self building with: |
85 | ####### builder error: cannot write to folder |
86 | ####### D:\a\v\v\你好 my $path, @с интервали: No such file or directory |
87 | ## and that happens even for gcc builds, not just tcc ones |
88 | |
89 | steps: |
90 | - uses: actions/checkout@v3 |
91 | with: |
92 | path: ${{env.MY_V_PATH}} |
93 | - name: Build V |
94 | run: | |
95 | echo '${{env.MY_V_PATH}}' |
96 | dir |
97 | cd '${{env.MY_V_PATH}}' |
98 | dir |
99 | .\make.bat -tcc |
100 | - name: v doctor |
101 | run: | |
102 | cd '${{env.MY_V_PATH}}' |
103 | ./v doctor |
104 | - name: v tests |
105 | run: | |
106 | cd '${{env.MY_V_PATH}}' |
107 | ./v test vlib/builtin vlib/os |