command_help
notes
Our great sponsors
command_help | notes | |
---|---|---|
8 | 17 | |
93 | 53 | |
- | - | |
0.0 | 1.5 | |
over 3 years ago | about 1 year ago | |
Shell | Vim Script | |
- | GNU General Public License v3.0 or later |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
command_help
-
Ask HN: What do you use to make CLIs?
I use a lot of CLI tools, but haven't written many for myself. Mostly, aliases/functions and some scripts in Bash/Python.
Extract details for command options from man/help: https://github.com/learnbyexample/command_help/blob/master/c...
cut-like syntax for field manipulations with regexp, negative indexing, etc: https://github.com/learnbyexample/regexp-cut/blob/main/rcut
simple calculator using python syntax: https://learnbyexample.github.io/practice_python_projects/ca...
- A better way of displaying help text on the command line
-
Enter a command to see help text for each arg
I wrote a Linux CLI tool [0] that parses the man/help pages to extract option details. Works most of the time for me, but there are plenty of corner cases that don't work.
-
What tools / utilities have you written that you use regularly?
https://github.com/learnbyexample/command_help to extract help text from builtin commands and man pages, ex:
-
What's a program you made that you actually use regularly?
https://github.com/learnbyexample/command_help is big enough to warrant a repo, examples, limitations, etc. I had a list of todo items to improve the script, but after years of usage, I'm fine with the limitations since I rarely encounter them. This helps me to extract documentation of particular options, here's an example:
-
Save Time Using Manop to Print Only Selected Content From the Man Page using Manop
I wrote one a few years back (https://github.com/learnbyexample/command_help). It has a few corner case issues, but works most of the time for me and supports multiple options to be retrieved.
-
Explainshell - A tool that takes any shell commands, looks up the syntax and options from man pages, and steps you through what it does!
I particularly wanted to lookup documentation for command options from my terminal (instead of the website), so wrote a script for it: https://github.com/learnbyexample/command_help ... Have a long pending todo list, but despite the issues, the tool is good enough for my needs.
-
Testing
When I start a project, I usually try to write the programs incrementally. Say I need to iterate over files from a directory. I will make sure that portion is working (usually with print() statements), then add another feature — say file reading and test that and so on. This reduces the burden of testing a large program at once at the end. And depending upon the nature of the program, I'll add a few sanity tests at the end. For example, for my command_help project, I copy pasted a few test runs of the program with different options and arguments into a separate file and wrote a program to perform these tests programmatically whenever the source code is modified.
notes
-
Blog: Terminal file managers and my Vifm setup
I've documented some really cool things that vifm can do: https://github.com/sitaramc/notes/blob/master/vifm.mkd
-
Prevent Thunar from writing lines to config file, or alternatively make git ignore certain lines
So I wrote https://github.com/sitaramc/notes/blob/master/dac -- 30 lines of shell plus maybe another 30 or 40 of comments, and it does everything I want in a dotfile manager.
-
What tools/methods do you use to track/journal all changes to your (desktop) system?
All this is painlessly taken care of by https://github.com/sitaramc/notes/blob/master/dac (documentation: https://github.com/sitaramc/notes/blob/master/dac.mkd)
-
ncdu - ncurses disk usage - see which directories and files are hogging the most space
If you have fzf installed, grab https://github.com/sitaramc/notes/blob/master/try, and run try dust. Then start typing -t jpg (for example). Then backspace over the jpg and change it to png. Or use some other options.
-
what is the easiest way to backup your config files?
I hesitate to nominate any of them because (a) there are dozens or even hundreds of them and (b) I don't like any of them; I wrote my own because I needed a "hold" feature that no one had (i.e., when propagating changes to the repo, I want to hold back some parts of the change; https://github.com/sitaramc/notes/blob/master/dac.mkd explains better if you're interested
-
Do you use VIFM?
For those of you who are curious, https://github.com/sitaramc/notes/blob/master/vifm.mkd is my part "review" and part "tips and tricks" on vifm.
-
What tools / utilities have you written that you use regularly?
Most of my tools are in bash or perl, most of them less than 100 lines of code, (most of them are less than 200 even with comments). https://github.com/sitaramc/notes has all of them (terrible name for a repo full of tools I know; sorry!)
-
Seeking a terminal file manager
Absolutely vifm. My notes+tips/tricks on this at https://github.com/sitaramc/notes/blob/master/vifm.mkd
-
Should I use vim or neovim?
https://github.com/sitaramc/notes/blob/master/dac.mkd for documentation, https://github.com/sitaramc/notes/blob/master/dac.mkd for code, if you're interested.
-
difference between terminal file managers?
if you're a vim user, you can't go wrong with vifm. My take on vifm is here: https://github.com/sitaramc/notes/blob/master/vifm.mkd -- can't hurt to give it a read (it's a wee bit outdated but not much; probably only the last section needs to be updated)
What are some alternatives?
pinpoint - Keystroke launcher and personal command central. Alternative to Spotlight and Alfred for Windows. Alternative to Wox, PowerToys.
clifm - The shell-like, command line terminal file manager: simple, fast, extensible, and lightweight as hell.
hn-reader - A dark mode reader app for Hacker News
smenu - smenu started as a lightweight and flexible terminal menu generator, but quickly evolved into a powerful and versatile CLI selection tool for interactive or scripting use.
tera - Interactive Bash script terminal music radio player. Play your favorite radio station, CRUD your favorite lists, and explore new radio stations from your terminal.
vifm.vim - Vim plugin that allows use of vifm as a file picker
sc2-replay-go
suda.vim - 🥪 An alternative sudo.vim for Vim and Neovim, limited support sudo in Windows
ffupdate - A shellscript to automatically install and update firefox on linux.
nbrowser - 🔗 🌐 : an easy way to open links in browsers, mimic the "Open URL with..." dialog on Android, `nbrowser` help you open links in a browser
Watson - :watch: A wonderful CLI to track your time!