Skip to content

Commit

Permalink
Merge pull request #13 from hugheaves/openscad-grammar-updates
Browse files Browse the repository at this point in the history
Openscad grammar updates
  • Loading branch information
hugheaves committed Dec 29, 2023
2 parents 6371600 + 361c7e2 commit 4b87578
Show file tree
Hide file tree
Showing 44 changed files with 2,438 additions and 915 deletions.
24 changes: 6 additions & 18 deletions .github/workflows/release-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,12 +47,8 @@ jobs:
java-version: '17'
- name: Install ANTLR
run: pip install antlr4-tools
- name: Generate
run: go generate ./...
- name: Test
run: go test -v ./...
- name: Build
run: go build -o scadformat.exe cmd/main.go
- name: Build and Test
run: make
- name: Zip Artifact
run: powershell Compress-Archive scadformat.exe windows.zip
- name: Upload Artifact
Expand Down Expand Up @@ -81,12 +77,8 @@ jobs:
java-version: '17'
- name: Install ANTLR
run: pip install antlr4-tools
- name: Generate
run: go generate ./...
- name: Test
run: go test -v ./...
- name: Build
run: go build -o scadformat cmd/main.go
- name: Build and Test
run: make
- name: Zip Artifact
run: zip macos.zip scadformat
- name: Upload Artifact
Expand Down Expand Up @@ -115,12 +107,8 @@ jobs:
java-version: '17'
- name: Install ANTLR
run: pip install antlr4-tools
- name: Generate
run: go generate ./...
- name: Test
run: go test -v ./...
- name: Build
run: go build -o scadformat cmd/main.go
- name: Build and Test
run: make
- name: Zip Artifact
run: zip linux.zip scadformat
- name: Upload Artifact
Expand Down
10 changes: 2 additions & 8 deletions .github/workflows/test-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,5 @@ jobs:
- name: Install ANTLR
run: pip install antlr4-tools

- name: Generate
run: go generate ./...

- name: Test
run: go test -v ./...

- name: Build
run: go build -o scadformat cmd/main.go
- name: Build and Test
run: make
15 changes: 4 additions & 11 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,12 +1,5 @@
/scadformat
/internal/parser/.antlr
/internal/parser/openscad_base_visitor.go
/internal/parser/openscad_lexer.go
/internal/parser/openscad_parser.go
/internal/parser/openscad_visitor.go
/internal/parser/openscad_base_visitor.go.orig
/internal/parser/OpenSCAD.interp
/internal/parser/OpenSCAD.tokens
/internal/parser/OpenSCADLexer.interp
/internal/parser/OpenSCADLexer.tokens
/internal/parser/*
/cmd/version.txt
/.antlr
/scadformat
/scadformat.exe
15 changes: 15 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
scadformat: test cmd/*.go internal/parser/*.go internal/formatter/*.go internal/logutil/*.go
go build cmd/scadformat.go

internal/parser/*.go: OpenSCAD.g4
go generate ./...

test: internal/parser/*.go
go test ./...

clean:
rm -f internal/parser/*
rm -rf internal/parser/.antlr
rm cmd/version.txt

.PHONY: clean test
Loading

0 comments on commit 4b87578

Please sign in to comment.