/r/commandline
This is for anything regarding the command line, in any operating system. All questions (including dumb ones), tips, and links to interesting programs/console applications you've found or made yourself are welcome. Linux / BSD / OSX / Windows CLI and TUI apps or questions or comments, we're happy to take them all!
-----------------------------
/ This is for anything
| regarding the command line, |
| in any operating system. All |
| questions (including dumb |
| ones), tips, and interesting |
| programs/console applications |
| you've found or made yourself |
| are welcome. Please read the |
| rules, and you're welcome to |
| flair your posts if you want |
\ to. / |
---|
\ ^__^
\ (OO)\_______
(__)\ )\/\
||----w |
|| ||
commandline@reddit ~ $ _
If you're asking for help, remember to help the community by stating what OS and version you're using, and if at all possible paste any commands you've tried and any errors or output that you've seen.
Related subreddits:
/r/commandline
I’m excited to share my Python package, **Markdrop**, which has hit 6.17k+ downloads in just a month, so updated it just now! 🚀 It’s a powerful tool for converting PDF documents into structured formats like Markdown (.md) and HTML (.html) while automatically processing images and tables into descriptions for downstream use. Here's what Markdrop does:
# Key Features:
* **PDF to Markdown/HTML Conversion**: Converts PDFs into clean, structured Markdown files (.md) or HTML outputs, preserving the content layout.
* **AI-Powered Descriptions**: Replaces tables and images with descriptive summaries generated by LLM, making the content fully textual and easy to analyze. Earlier I added support of 6 different LLM Clients, but to improve the inference time, restricted to Gemini and GPT.
* **Downloadable Tables**: Can add accurate download buttons in HTML for tables, allowing users to download them as Excel files.
* **Seamless Table and Image Handling**: Extracts tables and images, generating detailed summaries for each, which are then embedded into the final Markdown document.
At the end, one can have a **.md** file that contains only textual data, including the AI-generated summaries of tables, images, graphs, etc. This results in a highly portable format that can be used directly for several downstream tasks, such as:
* Can be directly integrated into a RAG pipeline for enhanced content understanding and querying on documents containg useful images and tabular data.
* Ideal for automated content summarization and report generation.
* Facilitates extracting key data points from tables and images for further analysis.
* The .md files can serve as input for machine learning tasks or data-driven projects.
* Ideal for data extraction, simplifying the task of gathering key data from tables and images.
* The downloadable table feature is perfect for analysts, reducing the manual task of copying tables into Excel.
Markdrop streamlines workflows for document processing, saving time and enhancing productivity. You can easily install it via:
pip install markdrop
There’s also a **Colab demo** available to try it out directly: [Open in Colab](https://colab.research.google.com/drive/1ZebtmqGB9i4pZzo824aT5KzGuPikw6D9?usp=sharing).
[Github Repo](https://github.com/shoryasethia/markdrop)
If you've used Markdrop or plan to, I’d love to hear your feedback! Share your experience, any improvements, or how it helped in your workflow.
Check it out on [PyPI](https://pypi.org/project/markdrop) and let me know your thoughts!
I'm wondering what you guys do to swap esc and capslock for tty, i don't want to effect x11 or wayland setting which i run when graphical?
is there a shorthand way of accomplishing this in /etc/vconsole.conf?
Running arch linux but am curious about other major distros or even openbsd!
Enhancing your pre-commit experience with seamless hook autocompletion 🎢
GitHub: https://github.com/jason810496/zsh-pre-commit-autocomplete
I use OMZ, but...
✗ gsw
fatal: missing branch or commit argument
Or
✗ gsw
zsh: do you wish to see all 135 possibilities (135 lines)?
I would really like to push two buttons to go to 1 of the 10 latest branches I worked on.
Hello everyone,
I built a small tool I had been wanting for a while: a "television channel" for Nix packages.
You can check it out here: https://github.com/3timeslazy/nix-search-tv
It's built on top of awesome and fast nix-search package. Right now, it allows you to fuzzy search nixpkgs
, but I’m considering adding support for home-manager and nix-darwin as well.
Also, I would like to say big thanks to the contributors of nix-search
—this project wouldn't exist without their work
Hi,
I'm working on a command line tool taking regular expressions as arguments:
$ ./app column=regexp1 +regexp2 -regexp3
It basically filters a table of rows, the comand line arguments constraint the relevant/interesting rows:
foo=regexp1
matches a row where the column foo
value is characterized by regexp1
+regexp2
denotes that regexp2
must be included in a certain column (contains)-regexp3
denotes that regexp3
must NOT be included in a certain column (contains not)By default, the provided regular expressions match some text case insensitive. This is not negotiable, because it's critical to get rather more than to few results.
Now, can you think of an established notation/syntax that switches to case sensitive matching that plays well on the shell / command line?
In the world I know, the default is reverse. Matching happens case sensitive by default and it's possible to switch to case insensitive. For example,
\c
and \C
to specify the case to use.\\rc
or "\cregexp1"
so the application gets it (escaping), which looks somewhat awkward.I somewhat like the /foo/
notation, as at least in the unix world it's somewhat known that a regular expression is meant with that. It also opens room for extension (funny letters after the last /).
The other idea I had was to introduce command line options denoting the case sensitivity, but as you see from the example invocation above, that somewhat conflicts with the -regexp3 notation above:
$ ./app column=regexp1 +regexp2 -c -regexp3
the -c could mean: "the following regexes are to be matched case sensitive!".
Is there a notation you know that would fit here? What would be intuitive for you? :)
Hey all, new to the command line and wanted to start by remotely controlling our site. I have Oh My Zsh installed, but when I run something like `wp plugin list`, it gives me this:
WP Plugin List - no formatting
Conversely, when I run on another program (Local by Flywheel - use the integrated site shell), I get something like this:
I'm using iTerm2. Any ideas how I can achieve result 2?
My USB pluggin is fine, i tried various methods and other updates and it's still not working, like how to fi it?
Title.
Hey fellow CLI workers!
I'd like to share rsnip, a command-line snippet manager designed to make CLI workflows more efficient. Whether you’re juggling shell commands, git workflows, or custom scripts, rsnip makes searching snippets FAST and more productive.
We’ve all been there: searching for that one command or code snippet we know we used before. While tools like ChatGPT are amazing for new ideas, for repeated tasks, they’re slow and unreliable. Shell history is fast but limited. What I would like to have:
{{ env_USER }}
or {{ current_date|strftime('%Y-%m-%d') }}
).If this sounds like it might also help your workflow give it a try: cargo install rsnip
I'd appreciate your feedback!
It now supports color themes too. Which color theme would you like me to add?
I'm using Warp terminal, and I'd like to move to something more private and open (ideally Ghostty).
However, one feature it has me stuck on it is the visual command history. If I type "ls" then up_key, it shows every my command history filtered to that prefix. I'm looking for a good open alternative to this in zsh or fish.
I tried zsh-autosuggestions and it is nice, but only shows the one. I usually have many I want to look at visually.
I do care about the the UX/keybindings. "up" is pretty hooked into history in my mind and will be hard to reprogram myself. Being able to hit "up" after typing the start is also important to me (I don't realize I need this until I'm part way into typing).
Idk if anyone remembers me from my kotek os post, but since then i switched to making an alpine based distro and today i was able to make a very basic shell! (Made in arch, and will be implemented into my alpine iso soon!)
Desired outcome is... Select magnet link, pass magnet url to transmission-remote.
I have tried placing test commands in /etc/lynx.cfg, ~/.lynxrc, ~/.lynx/external
Errors I've gotten.
LYrcFile: missing '=' EXTERNAL:magnet:echo "Magnet link clicked: %s" >> /home/luke/Lynx.trace
LYrcFile: ignored EXTERNAL=http:echo "POSTs" >> /home/[name]/test.txt
I cannot get ANY functionality out of the EXTERNAL command modules.
I have tried everything I can think of any recommendations would be greatly appreciated.
My question is , is my output supposed to look like this or is this an error?
Hey r/commandline!
I created a tool that captures terminal output as SVG screenshots. It's designed to help developers create high-quality, editable terminal screenshots for documentation, blog posts, and presentations.
Key features:
Example screenshots below (Note: These are PNG previews. Check out the GitHub repo for the actual SVG files which are fully editable!)
The tool uses tmux and Charm's freeze to capture and style the output. You can customize colors, fonts, and other visual elements through a simple JSON config.
GitHub: https://github.com/suin/terminal-svg-screenshot
I'd love to hear your thoughts and feedback!
run() { echo "$@" | (nohup ${SHELL:-"/bin/sh"} &) >/dev/null 2>&1; }
it runs programs with nohup, basicaly allows you to run programs without making them dependent on the terminal.
I made a tool to eliminate the friction when you want to quickly test some code. Type lab
with any extension and start coding immediately - no thinking about filenames or directories.
Key features:
lab
with any extension to open a new filelab 1
opens most recent fileThe goal was to remove all overhead between "I want to try something" and actually writing code. Files live in ~/lab and clean themselves up - no management needed.
Feedback welcome! Made with Go.
maildir-rank-addr is a utility that generates a ranked addressbook from your locally available email. It can be used in MUA's like aerc or mutt by grepping the list, making actual address completion very fast.
Noteable changes are dropping the need for the folder structure to be explicitly maildir and also parsing mboxes, multiple source dirs, and a smarter handling of mailing lists (via the list-id header).
There's also an open issue about adding direct imap/jmap support. It would at quite a bit of complexity, but if it looks like people would use it, then it might be worthwhile to do it, so please chime in if this interests you.
Zip-Stream-CLI: Stream and View ZIP File Contents Directly in Your Terminal
👋 Hey everyone!
I’m happy to share a new Node.js tool I’ve been working on, called Zip-Stream-CLI! 🚀
Zip-Stream-CLI allows you to stream, extract, and display the contents of a remote ZIP file directly in your terminal—without downloading the entire archive! 📦 It supports multiple file types, including:
.txt
, .md
, .json
).mp3
, .wav
).png
, .jpg
).pdf
, .xls
).js
, .py
).tar
, .gz
.Processing img 2kjdi6jassod1...
I wanted a fast and efficient way to preview the contents of ZIP files directly from the terminal, especially when dealing with large archives. Instead of extracting the entire file, you can stream specific files and view them instantly in a visually appropriate format.
Simply provide a remote URL to a ZIP file, and the CLI tool will list its contents. You can choose a file to stream or view directly in your terminal. 🖥️
Example usage:
zip-stream-cli https://example.com/my-archive.zip
You can also extend the tool by adding custom handlers for any file type that isn’t already supported!
If you work with ZIP files often, this tool can save you time by allowing you to quickly preview the content without extracting everything.
You can find it on GitHub: Zip-Stream-CLI on GitHub
I’d love to get your feedback! 💬 If you have any feature suggestions or ideas, feel free to share them. And if you give it a try, let me know how it works for you!