generated from golang-templates/seed
-
Notifications
You must be signed in to change notification settings - Fork 0
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
Showing
10 changed files
with
90 additions
and
86 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 |
---|---|---|
@@ -1,5 +1,5 @@ | ||
LOG_TIMESTAMP-FORMAT=2006-01-02T15:04:05.000Z | ||
LOG_FORMAT=ansi | ||
LOG_FILE=/var/log/crontab-go.log | ||
LOG_STDOUT=true | ||
LOG_LEVEL=debug | ||
$env.LOG_TIMESTAMP_FORMAT = 2006-01-02T15:04:05.000Z | ||
$env.LOG_FORMAT = ansi | ||
$env.LOG_FILE = /var/log/crontab-go.log | ||
$env.LOG_STDOUT = true | ||
$env.LOG_LEVEL = debug |
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 |
---|---|---|
|
@@ -19,6 +19,7 @@ linters-settings: | |
linters: | ||
disable-all: true | ||
enable: | ||
- godoc | ||
- bodyclose | ||
- dogsled | ||
- dupl | ||
|
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
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
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
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
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 |
---|---|---|
@@ -1,8 +1,8 @@ | ||
package context | ||
|
||
type ContextKey = string | ||
type ContextKey string | ||
|
||
var ( | ||
scope ContextKey = "scope" | ||
logger ContextKey = "logger" | ||
scope ContextKey = ContextKey("scope") | ||
logger ContextKey = ContextKey("logger") | ||
) |
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,20 @@ | ||
package enums | ||
|
||
import "fmt" | ||
|
||
type LoggerFormatType string | ||
|
||
var ( | ||
JsonLogger = LoggerFormatType("json") | ||
AnsiLogger = LoggerFormatType("ansi") | ||
PlainLogger = LoggerFormatType("plain") | ||
) | ||
|
||
func (lf *LoggerFormatType) Validate() error { | ||
switch lf { | ||
case &JsonLogger, &AnsiLogger, &PlainLogger: | ||
return nil | ||
default: | ||
return fmt.Errorf("Given Logger type: `%s`", *lf) | ||
} | ||
} |
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
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