Skip to content

Commit

Permalink
Tweak gosimports settings
Browse files Browse the repository at this point in the history
  • Loading branch information
anuraaga committed Sep 16, 2022
1 parent 368f259 commit 9e44d25
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 3 deletions.
1 change: 1 addition & 0 deletions internal/operators/pm.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ package operators

import (
"github.com/corazawaf/coraza/v3"

"github.com/jcchavezs/coraza-wasm-filter/internal/ahocorasick"
)

Expand Down
1 change: 1 addition & 0 deletions internal/operators/rx.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ package operators

import (
"github.com/corazawaf/coraza/v3"

"github.com/jcchavezs/coraza-wasm-filter/internal/re2"
)

Expand Down
1 change: 1 addition & 0 deletions internal/operators/sqli.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ package operators

import (
"github.com/corazawaf/coraza/v3"

"github.com/jcchavezs/coraza-wasm-filter/internal/injection"
)

Expand Down
1 change: 1 addition & 0 deletions internal/operators/xss.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ package operators

import (
"github.com/corazawaf/coraza/v3"

"github.com/jcchavezs/coraza-wasm-filter/internal/injection"
)

Expand Down
6 changes: 5 additions & 1 deletion magefile.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,11 @@ func Format() error {
"-ignore", "examples/**", "."); err != nil {
return err
}
return sh.RunV("go", "run", fmt.Sprintf("github.com/rinchsan/gosimports/cmd/gosimports@%s", gosImportsVer), "-w", ".")
return sh.RunV("go", "run", fmt.Sprintf("github.com/rinchsan/gosimports/cmd/gosimports@%s", gosImportsVer),
"-w",
"-local",
"github.com/jcchavezs/coraza-wasm-filter",
".")
}

// Lint verifies code quality.
Expand Down
5 changes: 3 additions & 2 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,11 @@ import (
"github.com/corazawaf/coraza/v3"
"github.com/corazawaf/coraza/v3/seclang"
ctypes "github.com/corazawaf/coraza/v3/types"
_ "github.com/jcchavezs/coraza-wasm-filter/internal/calloc"
"github.com/jcchavezs/coraza-wasm-filter/internal/operators"
"github.com/tetratelabs/proxy-wasm-go-sdk/proxywasm"
"github.com/tetratelabs/proxy-wasm-go-sdk/proxywasm/types"

_ "github.com/jcchavezs/coraza-wasm-filter/internal/calloc"
"github.com/jcchavezs/coraza-wasm-filter/internal/operators"
)

// #cgo LDFLAGS: lib/libinjection.a lib/libre2.a lib/libcre2.a lib/libc++.a lib/libc++abi.a lib/libclang_rt.builtins-wasm32.a lib/libaho_corasick.a
Expand Down

0 comments on commit 9e44d25

Please sign in to comment.