generated from khulnasoft/repository-template
-
Notifications
You must be signed in to change notification settings - Fork 0
/
codex.json
44 lines (44 loc) · 1.99 KB
/
codex.json
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
{
"name": "codex",
"description": "Instant, easy, and predictable development environments",
"packages": {
"go": "latest",
"runx:golangci/golangci-lint": "latest",
"runx:mvdan/gofumpt": "latest",
},
"env": {
"GOENV": "off",
"PATH": "$PATH:$PWD/dist",
},
"shell": {
"init_hook": [
// Remove Go environment variables that might've been inherited from the
// user's environment and could affect the build.
"test -z $FISH_VERSION && \\",
"unset CGO_ENABLED GO111MODULE GOARCH GOFLAGS GOMOD GOOS GOROOT GOTOOLCHAIN GOWORK || \\",
"set --erase CGO_ENABLED GO111MODULE GOARCH GOFLAGS GOMOD GOOS GOROOT GOTOOLCHAIN GOWORK",
],
"scripts": {
// Build codex for the current platform
"build": "go build -o dist/codex ./cmd/codex",
"build-darwin-amd64": "GOOS=darwin GOARCH=amd64 go build -o dist/codex-darwin-amd64 ./cmd/codex",
"build-darwin-arm64": "GOOS=darwin GOARCH=arm64 go build -o dist/codex-darwin-arm64 ./cmd/codex",
"build-linux-amd64": "GOOS=linux GOARCH=amd64 go build -o dist/codex-linux-amd64 ./cmd/codex",
"build-linux-arm64": "GOOS=linux GOARCH=arm64 go build -o dist/codex-linux-arm64 ./cmd/codex",
"build-all": [
"codex run build-darwin-amd64",
"codex run build-darwin-arm64",
"codex run build-linux-amd64",
"codex run build-linux-arm64",
],
// Open VSCode
"code": "code .",
"lint": "golangci-lint run --timeout 5m && scripts/gofumpt.sh",
"fmt": "scripts/gofumpt.sh",
"test": "go test -race -cover ./...",
"test-projects-only": "CODEX_RUN_PROJECT_TESTS=1 go test -v -timeout ${CODEX_GOLANG_TEST_TIMEOUT:-30m} ./... -run \"TestExamples|TestScriptsWithProjects\"",
"update-examples": "codex run build && go run testscripts/testrunner/updater/main.go",
"tidy": "go mod tidy",
},
},
}