Skip to main content
ldez u/ldez avatar

ldez

u/ldez

Feed options
Hot
New
Top
View
Card
Compact

Maintained fork of segmentio/golines
Image
r/golang
A banner for the subreddit

Ask questions and post articles about the Go programming language and related tools, events etc.


Weekly visitors Weekly contributions
Maintained fork of segmentio/golines

Twilio Segment has archived segmentio/golines.

The main changes inside the fork are:

  • The project structure: organized into packages, and usable as a library

  • CLI performance improvements

  • Several bugs have been fixed

  • -w and -l can be used at the same time

  • New tests system that allows testing all the options

There is no breaking change.

golangci/golines is about nine to fourteen times faster than segmentio/golines.

Bonus: there is a logo.


Image
A banner for the subreddit

/r/Twitch is an unofficial place for discussions surrounding the streaming website Twitch.tv. If you want to provide feedback, ask a question or browse our knowledge base, this is the place for you!


Weekly visitors Weekly contributions
r/Twitch
A banner for the subreddit

/r/Twitch is an unofficial place for discussions surrounding the streaming website Twitch.tv. If you want to provide feedback, ask a question or browse our knowledge base, this is the place for you!


Weekly visitors Weekly contributions

Nvidia Shield / Android TV: Twitch stream stops working as soon as it tries to play an ad

ldez
commented

I have a kind of workaround, when the pause appears:

  • decrease the stream quality to 160p

  • the ad will start

  • at the end of the ad, a QRCode will appear, press the back button of the remote control.

  • increase the stream quality to the original


Image
A banner for the subreddit

Ask questions and post articles about the Go programming language and related tools, events etc.


Weekly visitors Weekly contributions
r/golang
A banner for the subreddit

Ask questions and post articles about the Go programming language and related tools, events etc.


Weekly visitors Weekly contributions

Disable golangci-lint revive unused-parameter rule.

ldez
commented

Hi, you can do that:

linters:
  exclusions:
    rules:
      - linters:
          - revive
        path: path/to/your/file.go
        text: "unused-parameter: parameter 'XXX' seems to be unused, consider removing or renaming it as _"

Replace XXX with the parameter name, and path/to/your/file.go with your targeted file.

https://golangci-lint.run/docs/linters/false-positives/#exclude-issue-by-text


Image
A banner for the subreddit

Ask questions and post articles about the Go programming language and related tools, events etc.


Weekly visitors Weekly contributions
r/golang
A banner for the subreddit

Ask questions and post articles about the Go programming language and related tools, events etc.


Weekly visitors Weekly contributions

Welcome to golangci-lint v2

ldez
replied to atuca666

thank you



Image
A banner for the subreddit

Ask questions and post articles about the Go programming language and related tools, events etc.


Weekly visitors Weekly contributions
r/golang
A banner for the subreddit

Ask questions and post articles about the Go programming language and related tools, events etc.


Weekly visitors Weekly contributions

[deleted by user]

ldez
replied to ldez

Also, Go is not Java, the direct access to struct fields is the recommended way unless some exceptions.


Image
A banner for the subreddit

Ask questions and post articles about the Go programming language and related tools, events etc.


Weekly visitors Weekly contributions
r/golang
A banner for the subreddit

Ask questions and post articles about the Go programming language and related tools, events etc.


Weekly visitors Weekly contributions

[deleted by user]

In your example, u.Name is returned and it's string so immutable. There is no problem to do that.


Image
A banner for the subreddit

Ask questions and post articles about the Go programming language and related tools, events etc.


Weekly visitors Weekly contributions
r/golang
A banner for the subreddit

Ask questions and post articles about the Go programming language and related tools, events etc.


Weekly visitors Weekly contributions

[deleted by user]

ldez
commented

Edit: my answer was offtopic