
Security News
Deno 2.6 + Socket: Supply Chain Defense In Your CLI
Deno 2.6 introduces deno audit with a new --socket flag that plugs directly into Socket to bring supply chain security checks into the Deno CLI.
grabit
Advanced tools
grabit is a command-line tool for recursively scanning a directory, extracting file contents, and saving or copying them to the clipboard while respecting .grabit rules. The tool helps turn complex projects into LLM input for big context questions.
I will endeavour to keep the docs on how to use grabit up to date, but time constraints mean they will likely slip behind as I ship features. The easiest way to see all the options available is to clone the repo run grabit on it and ask an LLM what's available! LOL. Or just read the source code if you know your Python.
grabit is a pure Python CLI. No dependencies. So it works out of the box on Windows, macOS, and Linux.--no-git or -ng. Turning off git significantly speeds up the process and reduces token count..grabit rules..grabit file with some standard regex and options set with some commentary on how to set up the file.Install grabit using pip:
pip install grabit
.grabit filegrabit init
This will create a file in your current directory called .grabit.
This command is what you'll use to generate input for an LLM.
grabit scan /path/to/directory
The above command will output the LLM context to the terminal and ask you to use copy or output.
grabit scan /path/to/directory -c
grabit scan /path/to/directory -o some_output_file.txt
grabit scan /path/to/directory -o some_output_file.txt -ng
Order by descending on the path.
grabit scan /path/to/directory --order path:desc
Order by ascending on the last modified by:
grabit scan /path/to/directory --order modified:asc
By default asc is used if you don't add anything, so
grabit scan /path/to/directory --order modified
Is the same as the above. If you want to see all possible options use:
grabit scan --help
This command is what you'll use to quickly scan a directory and prepare your .grabit file for scan.
grabit bytes /path/to/directory -c
grabit bytes /path/to/directory -o some_output_file.txt
Order by descending on the path.
grabit bytes /path/to/directory --order path:desc
Order by ascending on the last modified by:
grabit scan /path/to/directory --order modified:asc
By default asc is used if you don't add anything, so
grabit scan /path/to/directory --order modified
Is the same as the above. If you want to see all possible options use:
grabit scan --help
grabit tree /path/to/directory
grabit tree /path/to/directory -c
grabit tree /path/to/directory --depth 2
or
grabit tree /path/to/directory -d 2
Please do grabit init and read the commentary in the file to see how these work. They are currently (2025-03-04) in a state of constant change. Once they're more stable I will add a full tutorial.
When run, grabit will generate a structured output:
## `src/main.py`:
``
print("Hello, World!")
``
## `README.md`:
``
# Project Readme
``
Major.Minor.Patch
.grabit..grabit file. i.e. you could have a configuration for getting section A of your app, and another for section B of your app to make it easier to set the configs once and not worry afterwards..grabit file produced by grabit init..grabit file to reflect the user's choices in the above two features..grabit file for faster query re-runs.README.md.grabit files. This will run through their directory and make decisions for them, outputting choices to the terminal for the user to review. e.g. skipping extra large files, or skipping known auto-genned file types like .dll..grabit options and lets them build their .grabit file via the terminalbytes command so that the file endings also have their total bytes colour coded.curses built in python package to make a terminal app for automated actions: https://docs.python.org/3/howto/curses.html.grabit or extend the .grabit file type to allow formatted messages. i.e. you should be able to write prompts that rely on grabit commands. So in the .grabit file you would set up several different configs, then in the prompt creation file you would use <!grabit config some-config?> or something along these lines. This would make it possible to build prompts quickly and only build them once, in such a way that you can set up repeat questions very effectively, or re-use prompt structure easily. It would also allow for grabit to ship with some basic configs already set up.# global or something, this would apply everywhere across all configs.tree command in Linux but prettierMIT License
FAQs
Simple Python CLI tool for turning directories into a single text file for input to LLMs.
We found that grabit demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Deno 2.6 introduces deno audit with a new --socket flag that plugs directly into Socket to bring supply chain security checks into the Deno CLI.

Security News
New DoS and source code exposure bugs in React Server Components and Next.js: what’s affected and how to update safely.

Security News
Socket CEO Feross Aboukhadijeh joins Software Engineering Daily to discuss modern software supply chain attacks and rising AI-driven security risks.