fix pre-commit and cleanup

This commit is contained in:
Kjeld Schouten
2024-10-19 15:18:05 +02:00
parent 2acb59c9dc
commit 4ab41d42f2
203 changed files with 8456 additions and 8484 deletions
+13 -13
View File
@@ -1,24 +1,24 @@
package cmd
import (
"os"
"os"
"github.com/rs/zerolog/log"
"github.com/spf13/cobra"
"github.com/truecharts/public/clustertool/pkg/sops"
"github.com/rs/zerolog/log"
"github.com/spf13/cobra"
"github.com/truecharts/public/clustertool/pkg/sops"
)
var precommit = &cobra.Command{
Use: "precommit",
Short: "Runs the PreCommit encryption check",
Run: func(cmd *cobra.Command, args []string) {
if err := sops.CheckFilesAndReportEncryption(true, true); err != nil {
log.Info().Msgf("Error checking files: %v\n", err)
os.Exit(1)
}
},
Use: "precommit",
Short: "Runs the PreCommit encryption check",
Run: func(cmd *cobra.Command, args []string) {
if err := sops.CheckFilesAndReportEncryption(true, true); err != nil {
log.Info().Msgf("Error checking files: %v\n", err)
os.Exit(1)
}
},
}
func init() {
adv.AddCommand(precommit)
adv.AddCommand(precommit)
}