Skip to content

Latest commit

 

History

History
60 lines (37 loc) · 1.14 KB

DEVELOPMENT.md

File metadata and controls

60 lines (37 loc) · 1.14 KB

Development

Porcupine uses the standard Go toolchain for development.

Testing

You can run the tests with:

go test ./...

Some of the tests generate visualizations which must be manually inspected. To make the tests print the path to the generated HTML files, run the tests with the -v flag.

Formatting

You can run the Go code formatter with:

go fmt ./...

Additionally, this project uses Prettier to format HTML, CSS, and JavaScript files. You can run Prettier (using npx) with:

npx prettier -w '**/*.{html,css,js}'

Static analysis

You can run Go's built-in vet tool with:

go vet ./...

This project additionally uses the staticcheck tool. You can install it with:

go install honnef.co/go/tools/cmd/staticcheck@latest

You can run staticcheck with:

staticcheck -f stylish ./...

Continuous integration

Testing and static analysis is run in CI.