Skip to content

Commit

Permalink
vendor xdg
Browse files Browse the repository at this point in the history
  • Loading branch information
aybabtme authored and Antoine Grondin committed Sep 15, 2022
1 parent 69e78eb commit 907dd6a
Show file tree
Hide file tree
Showing 369 changed files with 124,371 additions and 62,444 deletions.
2 changes: 2 additions & 0 deletions cmd/humanlog/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import (
"os/signal"
"strings"

"github.com/adrg/xdg"
"github.com/aybabtme/humanlog"
"github.com/aybabtme/rgbterm"
"github.com/mattn/go-colorable"
Expand All @@ -22,6 +23,7 @@ func fatalf(c *cli.Context, format string, args ...interface{}) {

func main() {
app := newApp()
_ = xdg.DataHome

prefix := rgbterm.FgString(app.Name+"> ", 99, 99, 99)

Expand Down
8 changes: 6 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,16 @@ module github.com/aybabtme/humanlog
go 1.19

require (
github.com/adrg/xdg v0.4.0
github.com/aybabtme/rgbterm v0.0.0-20170906152045-cc83f3b3ce59
github.com/fatih/color v1.7.1-0.20180516100307-2d684516a886
github.com/go-logfmt/logfmt v0.4.0
github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515
github.com/mattn/go-colorable v0.1.0
github.com/mattn/go-isatty v0.0.4 // indirect
github.com/urfave/cli v1.20.1-0.20180226030253-8e01ec4cd3e2
golang.org/x/sys v0.0.0-20170407050850-f3918c30c5c2 // indirect
)

require (
github.com/mattn/go-isatty v0.0.4 // indirect
golang.org/x/sys v0.0.0-20211025201205-69cdffdb9359 // indirect
)
16 changes: 14 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
github.com/adrg/xdg v0.4.0 h1:RzRqFcjH4nE5C6oTAxhBtoE2IRyjBSa62SCbyPidvls=
github.com/adrg/xdg v0.4.0/go.mod h1:N6ag73EX4wyxeaoeHctc1mas01KZgsj5tYiAIwqJE/E=
github.com/aybabtme/rgbterm v0.0.0-20170906152045-cc83f3b3ce59 h1:WWB576BN5zNSZc/M9d/10pqEx5VHNhaQ/yOVAkmj5Yo=
github.com/aybabtme/rgbterm v0.0.0-20170906152045-cc83f3b3ce59/go.mod h1:q/89r3U2H7sSsE2t6Kca0lfwTK8JdoNGS/yzM/4iH5I=
github.com/davecgh/go-spew v1.1.0 h1:ZDRjVQ15GmhC3fiQ8ni8+OwkZQO4DARzQgrnXU1Liz8=
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
github.com/fatih/color v1.7.1-0.20180516100307-2d684516a886 h1:NAFoy+QgUpERgK3y1xiVh5HcOvSeZHpXTTo5qnvnuK4=
github.com/fatih/color v1.7.1-0.20180516100307-2d684516a886/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4=
github.com/go-logfmt/logfmt v0.4.0 h1:MP4Eh7ZCb31lleYCFuwm0oe4/YGak+5l1vA2NOE80nA=
Expand All @@ -10,7 +14,15 @@ github.com/mattn/go-colorable v0.1.0 h1:v2XXALHHh6zHfYTJ+cSkwtyffnaOyR1MXaA91mTr
github.com/mattn/go-colorable v0.1.0/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU=
github.com/mattn/go-isatty v0.0.4 h1:bnP0vzxcAdeI1zdubAl5PjU6zsERjGZb7raWodagDYs=
github.com/mattn/go-isatty v0.0.4/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4=
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY=
github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
github.com/urfave/cli v1.20.1-0.20180226030253-8e01ec4cd3e2 h1:xAkHCttGHKXIr10OSiFzNt0XOJyHMdng0ylSynT8sMo=
github.com/urfave/cli v1.20.1-0.20180226030253-8e01ec4cd3e2/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA=
golang.org/x/sys v0.0.0-20170407050850-f3918c30c5c2 h1:niKkabq6kYToDafvvFw9MeTkT4ifSvpOCRP6pFxOCZE=
golang.org/x/sys v0.0.0-20170407050850-f3918c30c5c2/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20211025201205-69cdffdb9359 h1:2B5p2L5IfGiD7+b9BOoRMC6DgObAVZV+Fsp050NqXik=
golang.org/x/sys v0.0.0-20211025201205-69cdffdb9359/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c h1:dUUwHk2QECo/6vqA44rthZ8ie2QXMNeKRTHCNY2nXvo=
gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
4 changes: 4 additions & 0 deletions test/cases/00004-mixed/input
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
time=2022-08-10T03:03:24.259999353Z level=INFO msg="Started Worker" Namespace=runtime TaskQueue=runtimed
time=2022-08-10T03:05:19.289159884Z level=ERROR msg="processing job" error="worker error from receive: twirp error internal: failed to do request: Post \"http://localhost:18081/twirp/aqueduct.api.v1.JobQueueService/Receive\": context deadline exceeded (Client.Timeout exceeded while awaiting headers)"
time=2022-08-10T03:06:20.422461071Z level=DEBUG msg="inbound request" twirp_svc=ManagementsAPI twirp_method=GetEnableStatus twirp_req=*managements.GetEnableStatusRequest
{"level":"info","ts":"2022-08-10T03:03:18.312Z","msg":"temporal-sys-tq-scanner-workflow workflow successfully started","service":"worker","logging-call-at":"scanner.go:202"}
29 changes: 29 additions & 0 deletions test/cases/00004-mixed/opts.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
{
"skip": null,
"keep": null,
"time_fields": [
"time",
"ts",
"@timestamp",
"timestamp"
],
"message_fields": [
"message",
"msg"
],
"level_fields": [
"level",
"lvl",
"loglevel",
"severity"
],
"sort_longest": true,
"skip_unchanged": true,
"truncates": false,
"light_bg": false,
"color_mode": 2,
"truncate_length": 15,
"time_format": "Jan _2 15:04:05",
"palette": null
}

4 changes: 4 additions & 0 deletions test/cases/00004-mixed/want
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Aug 10 03:03:24 |INFO| Started Worker Namespace=runtime TaskQueue=runtimed
Aug 10 03:05:19 |ERRO| processing job error=worker error from receive: twirp error internal: failed to do request: Post "http://localhost:18081/twirp/aqueduct.api.v1.JobQueueService/Receive": context deadline exceeded (Client.Timeout exceeded while awaiting headers)
Aug 10 03:06:20 |DEBU| inbound request twirp_svc=ManagementsAPI twirp_method=GetEnableStatus twirp_req=*managements.GetEnableStatusRequest
Aug 10 03:03:18 |INFO| temporal-sys-tq-scanner-workflow workflow successfully started service="worker" logging-call-at="scanner.go:202"
2 changes: 1 addition & 1 deletion test/cases/10001-behavior-truncates/want
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Jan 1 00:00:00 || <no msg> k1="short" k2="lonnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnng"
Jan 1 00:00:00 || <no msg> k1="short" k2="lonnnnnnnnnnnn...
Jan 1 00:00:00 || <no msg> repeated="first time"
Jan 1 00:00:00 || <no msg>
Jan 1 00:00:00 || <no msg> repeated="second time"
77 changes: 77 additions & 0 deletions vendor/github.com/adrg/xdg/CODE_OF_CONDUCT.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

135 changes: 135 additions & 0 deletions vendor/github.com/adrg/xdg/CONTRIBUTING.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

21 changes: 21 additions & 0 deletions vendor/github.com/adrg/xdg/LICENSE

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 907dd6a

Please sign in to comment.