Skip to content

Commit

Permalink
add script for building all sims for web and use it for CD
Browse files Browse the repository at this point in the history
  • Loading branch information
kkoreilly committed Aug 20, 2024
1 parent d709149 commit 2490d0a
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 6 deletions.
9 changes: 3 additions & 6 deletions .github/workflows/core.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,13 +40,10 @@ jobs:
go-version: '1.22'

- name: Install Core
run: go install cogentcore.org/core/cmd/core@main
run: go install cogentcore.org/core/cmd/core@main && go install cogentcore.org/shell/cmd/cosh@main

- name: Build Neuron
run: core build web -dir ch2/neuron -o static/ch2/neuron

- name: Build Detector
run: core build web -dir ch2/detector -o static/ch2/detector
- name: Build Sims
run: ./make

- name: Setup Pages
id: pages
Expand Down
10 changes: 10 additions & 0 deletions make
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#!/usr/bin/env cosh

for _, pkg := range cosh.SplitLines(`go list ./...`) {
pkg = strings.TrimPrefix(pkg, "github.com/CompCogNeuro/sims/v2")
if pkg == "" {
continue
}
pkg = pkg[1:] // remove slash
core build web -dir {pkg} -o {filepath.Join("static", pkg)}
}

0 comments on commit 2490d0a

Please sign in to comment.