question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Provide Mount-points for common CLI - Help, Version etc.

See original GitHub issue

In gluegun 2.0 let’s handle the common CLI options in a classy way.

98% of CLIs

If you want the built-in support, you can just use commonCommands function. image Maybe even more succinct as .commonCommands(['help', 'version']) These will stop the copy-pasta mess which is mandatory, but not the focus of most CLIs. You can offload it to us.

BUT! What if they want to write their own?

No problem!, we’ll also support .help() and .version() of every common command, where a user could inject their own function, so they could do something complex like, spit out 2 versions (I’m looking at you react-native-cli). Or simply take control of how things should be displayed.

No thanks Gluegun, you’re getting in my way!!!

No problem!, don’t use either of the aforementioned functions and just you do you. giphy-downsized


Common Commands Should Include ['version', 'help', 'silent']

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:5 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
skellockcommented, Oct 20, 2017

i like you.

1reaction
skellockcommented, Oct 20, 2017

I’d love for this fluent api interface to be:

  .help()
  .version()
  .silent()

The absence of any would mean they are disabled.

The presence of them without params would mean they get defaults.

Passing stuff would allow us to customize their behaviour.

Read more comments on GitHub >

github_iconTop Results From Across the Web

mount(8) - Linux manual page - man7.org
Command-line options available for the mount command are: -a, --all Mount all filesystems (of the given types) mentioned in fstab (except for those...
Read more >
19.2. Mounting a File System Red Hat Enterprise Linux 7
19.2.2. Specifying the Mount Options ; loop, Mounts an image as a loop device. ; noauto, Default behavior disallows the automatic mount of...
Read more >
Linux mount Command with Examples - phoenixNAP
The mount command allows users to mount, i.e., attach additional child file systems to a particular mount point on the currently accessible ...
Read more >
Fstab - Community Help Wiki - Official Ubuntu Documentation
A mount point is a location on your directory tree to mount the partition. The default location is /media although you may use...
Read more >
mount command in Linux with Examples - GeeksforGeeks
l : Lists all the file systems mounted yet. · h : Displays options for command. · V : Displays the version information....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found