k3c
k3c copied to clipboard
Logs syntax was not as expected
This command works: k3c logs -f 1e51768333bc
This one doesn't work, but I use this order a lot: k3c logs 1e51768333bc -f - "logs" requires exactly 1 argument, see --help
@ibuildthecloud I know you shared some feelings about Cobra, but for its downsides, it does get the ordering of flags "right" and is consistent with the other tooling we're used to like docker / kubectl.
Yes and no. For example. docker run foo bar -it and docker logs asdf -f have different expected behavior. In this project I tried using urfave 2. In urfave 1 there was an option for this SkipArgReorder. I'm guessing it got dropped? I'll figure out what happened, maybe revert to urfave 1.
I see your point with -t -i in docker run.. Thanks for looking, I think adding -f or --tail 100 to the end of a logs statement is important.
@alexellis Sorry that was the point I was making. In docker run foo bar -i the -i should not be treated as a flag. In docker logs foo -f you want it treated as a flag. I'll look at cobra.