-
Notifications
You must be signed in to change notification settings - Fork 0
64 lines (53 loc) · 1.59 KB
/
node.js.yml
File metadata and controls
64 lines (53 loc) · 1.59 KB
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
name: Repository CI
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
validate:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Validate repository layout
run: |
test -d web
test -d powershell
test -d windows
test -d android
test -f web/index.html
test -f web/styles.css
test -f web/script.js
test -f web/manifest.json
test -f web/service-worker.js
test -f powershell/native-widget.ps1
test -f windows/BinaryBloomClock.Windows.csproj
test -f android/app/build.gradle.kts
- name: Validate JSON files
run: |
python -m json.tool web/manifest.json > /dev/null
- name: Validate PowerShell syntax
shell: pwsh
run: |
$errors = @()
Get-ChildItem -Path powershell -Filter *.ps1 | ForEach-Object {
$parseErrors = $null
[void][System.Management.Automation.Language.Parser]::ParseFile($_.FullName, [ref]$null, [ref]$parseErrors)
if ($parseErrors) {
$errors += $parseErrors
}
}
if ($errors.Count -gt 0) {
$errors | ForEach-Object { Write-Host $_ }
throw "PowerShell parse errors found."
}
windows-build:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: Setup .NET SDK
uses: actions/setup-dotnet@v4
with:
dotnet-version: 9.0.x
- name: Build Windows wrapper
run: dotnet build windows/BinaryBloomClock.Windows.csproj --configuration Release --nologo