-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
candinu
committed
Mar 18, 2023
0 parents
commit 9ef8501
Showing
6 changed files
with
150 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
.DS_Store | ||
*.swp | ||
*.log | ||
bin/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,109 @@ | ||
# This file contains all available configuration options | ||
# with their default values (in comments). | ||
# | ||
# This file is not a configuration example, | ||
# it contains the exhaustive configuration with explanations of the options. | ||
|
||
# Options for analysis running. | ||
run: | ||
# The default concurrency value is the number of available CPU. | ||
concurrency: 4 | ||
|
||
# Timeout for analysis, e.g. 30s, 5m. | ||
# Default: 1m | ||
timeout: 5m | ||
|
||
# Exit code when at least one issue was found. | ||
# Default: 1 | ||
issues-exit-code: 2 | ||
|
||
# Include test files or not. | ||
# Default: true | ||
tests: false | ||
|
||
# List of build tags, all linters use it. | ||
# Default: []. | ||
build-tags: | ||
- mytag | ||
|
||
# Which dirs to skip: issues from them won't be reported. | ||
# Can use regexp here: `generated.*`, regexp is applied on full path. | ||
# Default value is empty list, | ||
# but default dirs are skipped independently of this option's value (see skip-dirs-use-default). | ||
# "/" will be replaced by current OS file path separator to properly work on Windows. | ||
skip-dirs: | ||
- src/external_libs | ||
- autogenerated_by_my_lib | ||
|
||
# Enables skipping of directories: | ||
# - vendor$, third_party$, testdata$, examples$, Godeps$, builtin$ | ||
# Default: true | ||
skip-dirs-use-default: false | ||
|
||
# Which files to skip: they will be analyzed, but issues from them won't be reported. | ||
# Default value is empty list, | ||
# but there is no need to include all autogenerated files, | ||
# we confidently recognize autogenerated files. | ||
# If it's not please let us know. | ||
# "/" will be replaced by current OS file path separator to properly work on Windows. | ||
skip-files: | ||
- ".*\\.my\\.go$" | ||
- lib/bad.go | ||
|
||
# If set we pass it to "go list -mod={option}". From "go help modules": | ||
# If invoked with -mod=readonly, the go command is disallowed from the implicit | ||
# automatic updating of go.mod described above. Instead, it fails when any changes | ||
# to go.mod are needed. This setting is most useful to check that go.mod does | ||
# not need updates, such as in a continuous integration and testing system. | ||
# If invoked with -mod=vendor, the go command assumes that the vendor | ||
# directory holds the correct copies of dependencies and ignores | ||
# the dependency descriptions in go.mod. | ||
# | ||
# Allowed values: readonly|vendor|mod | ||
# By default, it isn't set. | ||
modules-download-mode: readonly | ||
|
||
# Allow multiple parallel golangci-lint instances running. | ||
# If false (default) - golangci-lint acquires file lock on start. | ||
allow-parallel-runners: false | ||
|
||
# Define the Go version limit. | ||
# Mainly related to generics support in go1.18. | ||
# Default: use Go version from the go.mod file, fallback on the env var `GOVERSION`, fallback on 1.17 | ||
go: '1.18' | ||
|
||
|
||
linters: | ||
enable-all: true | ||
disable: | ||
- golint | ||
- exhaustivestruct | ||
- scopelint | ||
- interfacer | ||
- maligned | ||
- bodyclose | ||
- contextcheck | ||
- nilerr | ||
- noctx | ||
- rowserrcheck | ||
- sqlclosecheck | ||
- structcheck | ||
- tparallel | ||
- unparam | ||
- wastedassign | ||
- wsl | ||
- varnamelen | ||
- gomnd | ||
- exhaustruct | ||
- gochecknoglobals | ||
- nlreturn | ||
- godox | ||
|
||
linters-settings: | ||
lll: | ||
line-length: 160 | ||
tagliatelle: | ||
case: | ||
use-field-name: true | ||
rules: | ||
json: snake |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
VERSION=$(shell git tag --sort=-version:refname | head -1) | ||
SHA=$(shell git rev-parse --short HEAD) | ||
|
||
LDFLAGS=-X 'main.version=$(VERSION)' -X 'main.sha=$(SHA)' | ||
|
||
.PHONY: setup build build_linux test run clean all | ||
|
||
.DEFAULT_GOAL: default | ||
|
||
default: build test | ||
|
||
setup: | ||
mkdir -p bin | ||
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s v1.46.2 | ||
|
||
install: | ||
go install --ldflags="${LDFLAGS}" ./cmd/rom/ | ||
|
||
lint: setup | ||
./bin/golangci-lint run | ||
|
||
test: lint | ||
go test ./... | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
module github.com/scalescape/dolores | ||
|
||
go 1.19 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
package main | ||
|
||
import "log" | ||
|
||
func main() { | ||
log.Println("dolores") | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# Dolores | ||
|
||
Simplifying secrets management |