Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Command line argument that print only current code. #10

Open
tuxmartin opened this issue Apr 22, 2017 · 3 comments
Open

Command line argument that print only current code. #10

tuxmartin opened this issue Apr 22, 2017 · 3 comments

Comments

@tuxmartin
Copy link

Hi,
is possible to add command line argument that print only current code?

Program output:

  $ gauth
             prev   curr   next
  AWS        315306 135387 483601
  Airbnb     563728 339206 904549
  Google     453564 477615 356846
  Github     911264 548790 784099
  [=======                      ]

I need something like:

  $ gauth --curr
              curr   
  AWS        135387 
  Airbnb      339206 
  Google     477615 
  Github      548790 
  [=======                      ]

I do not want to remove variables from

gauth/gauth.go

Line 135 in a2c540c

fmt.Printf("%-10s %s %s %s\n", name, prevToken, currentToken, nextToken)

Thanks!

tbaumann pushed a commit to tbaumann/gauth that referenced this issue Jul 13, 2017
* Select single engtry via command line switch
* Don't print fluff in non-terminal mode

Adresses pcarrier#10
@iamkirkbater
Copy link

Wouldn't you be able to use awk for this?

gauth | awk '{$2=$4=""; print $0}'

@gadelkareem
Copy link

a flag would be really appreciated :)

@pcarrier
Copy link
Owner

pcarrier commented Jan 29, 2021

There might soon be a -csv (#42) that outputs a format closer to what you'd like now (name, current token, next token, seconds to next token), but doesn't look super nice. I realize showing the previous token is quirky but so am I; flag addition welcome if that really affects you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants