Skip to content

Commit

Permalink
chore: optimize directory structure
Browse files Browse the repository at this point in the history
  • Loading branch information
akkuman committed Dec 2, 2024
1 parent 7e7b42b commit 6a32e14
Show file tree
Hide file tree
Showing 18 changed files with 18 additions and 18 deletions.
4 changes: 2 additions & 2 deletions cmd/sbuild-linter/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"os"

"github.com/pkgforge/sbuilder-go/logger"
"github.com/pkgforge/sbuilder-go/validator"
"github.com/pkgforge/sbuilder-go/pkg/linter"
)

const errorMessage = `incorrect SBUILD File. Please recheck @ https://www.yamllint.com
Expand Down Expand Up @@ -40,7 +40,7 @@ func main() {
// Print which file is being verified
fmt.Printf("\x1b[44m\x1b[30m\x1b[4m[+]\x1b[0m Verifying %s\n", file)

validator, err := validator.NewValidator(file)
validator, err := linter.NewValidator(file)
if err != nil {
logger.Log.Error(err.Error())
logger.Log.Error(errorMessage)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package validator
package linter

import (
"bufio"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package validator
package linter

import (
"fmt"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package validator
package linter

import (
"fmt"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package validator
package linter

import (
"fmt"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package validator
package linter

import (
"fmt"
Expand Down
2 changes: 1 addition & 1 deletion validator/checkPkgId.go → pkg/linter/checkPkgId.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package validator
package linter

import (
"fmt"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package validator
package linter

import (
"fmt"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package validator
package linter

func (v *Validator) validateRunScript(noShellcheck bool) ([]byte, error, string) {
if xExec, ok := v.data["x_exec"].(map[string]interface{}); ok {
Expand Down
2 changes: 1 addition & 1 deletion validator/checkShebang.go → pkg/linter/checkShebang.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package validator
package linter

import (
"bufio"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package validator
package linter

import (
"fmt"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package validator
package linter

import (
"fmt"
Expand Down
2 changes: 1 addition & 1 deletion validator/checkVersion.go → pkg/linter/checkVersion.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package validator
package linter

import (
"fmt"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package validator
package linter

// The library does this check, so... Don't have to do anything here.
func (v *Validator) validateYAML() ([]byte, error, string) {
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion validator/util.go → pkg/linter/util.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package validator
package linter

import (
"fmt"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package validator
package linter

import (
"fmt"
Expand Down
2 changes: 1 addition & 1 deletion validator/validator.go → pkg/linter/validator.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package validator
package linter

import (
"fmt"
Expand Down

0 comments on commit 6a32e14

Please sign in to comment.