From f96ec96786b6c7596b38f5ae01869530515c6584 Mon Sep 17 00:00:00 2001 From: kjuulh Date: Sun, 18 Sep 2022 21:44:29 +0200 Subject: [PATCH] with semantic --- _examples/queries/find_semantic/kraken.yml | 9 +++++++++ internal/logger/zap.go | 3 ++- roadmap.md | 1 + scripts/run_client.sh | 7 +++++-- 4 files changed, 17 insertions(+), 3 deletions(-) create mode 100644 _examples/queries/find_semantic/kraken.yml diff --git a/_examples/queries/find_semantic/kraken.yml b/_examples/queries/find_semantic/kraken.yml new file mode 100644 index 0000000..e98ba75 --- /dev/null +++ b/_examples/queries/find_semantic/kraken.yml @@ -0,0 +1,9 @@ +apiVersion: git.front.kjuulh.io/kjuulh/kraken/blob/main/schema/v1 +name: write-a-readme +select: + providers: + - gitea: https://git.front.kjuulh.io + organisation: "cibus" +queries: + - type: grep + query: "releaser" diff --git a/internal/logger/zap.go b/internal/logger/zap.go index b6e7dce..5c44a40 100644 --- a/internal/logger/zap.go +++ b/internal/logger/zap.go @@ -12,7 +12,7 @@ func New() (*zap.Logger, error) { return lvl >= zapcore.ErrorLevel }) lowPriority := zap.LevelEnablerFunc(func(lvl zapcore.Level) bool { - return lvl < zapcore.ErrorLevel + return lvl < zapcore.ErrorLevel && lvl > zapcore.DebugLevel }) config := zap.NewDevelopmentEncoderConfig() @@ -28,5 +28,6 @@ func New() (*zap.Logger, error) { ) logger := zap.New(core) + return logger, nil } diff --git a/roadmap.md b/roadmap.md index 2d22130..57d603a 100644 --- a/roadmap.md +++ b/roadmap.md @@ -40,6 +40,7 @@ - [ ] Setup CI - [ ] Setup static analysis - [ ] Setup releases on gitea using drone +- [ ] Figure out a license (probably MIT) ## Version 0.3 diff --git a/scripts/run_client.sh b/scripts/run_client.sh index 237c23d..888e967 100755 --- a/scripts/run_client.sh +++ b/scripts/run_client.sh @@ -4,5 +4,8 @@ set -e current_branch=$(git branch --show-current) -go run cmd/kraken/kraken.go process --actions-repo "git@git.front.kjuulh.io:kjuulh/kraken.git" --branch "$current_branch" --path "_examples/actions/write_a_readme" -go run cmd/kraken/kraken.go process --actions-repo "git@git.front.kjuulh.io:kjuulh/kraken.git" --branch "$current_branch" --path "_examples/queries/scrape_readme" +#go run cmd/kraken/kraken.go process --actions-repo "git@git.front.kjuulh.io:kjuulh/kraken.git" --branch "$current_branch" --path "_examples/actions/write_a_readme" +go run cmd/kraken/kraken.go process \ + --actions-repo "git@git.front.kjuulh.io:kjuulh/kraken.git"\ + --branch "$current_branch" \ + --path "_examples/queries/find_semantic"