BSD Ports

textproc/molybdenum 0.1.10 NetBSD

Recursive search and replace CLI application

System
NetBSD
Repository
pkgsrc
Maintainer
[email protected]
License
eupl-v1.1
Categories
textproc
Package size
638.7 KiB, 2571.8 KiB installed

Description

Recursive _search and replace_ CLI application.

Powerful search can be found without problems, eg, grep, ack, ag, ripgrep or broot.

Tools for replacing recursively in a folder are more difficult to find, although some exist: fart-it. Typically, people use a combination of searching, xargs and a replacement tool like sed or rpl.

I use code searching a lot to investigate a large source code base before attempting a replace. Even with 100k files, search is fast and fairly easy. Recursively replacing text is much more dangerous, especially if it requires the combination of several less frequently used tools; it's difficult to remember a search-xargs-replace combination if not used on a daily basis. On top of this, the search tool used to filter the set of files and perform a dry-run, is not per-se using the same search query as the replace tool. After all, these are different tools. It would be better if a single tool could be used for every-day searching and replacing. This is exactly what The Molybdenum Replacer intends to achieve.

Install

Binary package:

pkgin install molybdenum

From pkgsrc:

cd /usr/pkgsrc/textproc/molybdenum && make install clean

Packages

The version each package repository carries. “-” means the repository builds no package of it, “n/a” that there is no such repository.

RepositoryVersion
NetBSD 10.1 x86_640.1.10
NetBSD 10.1 aarch640.1.10
SmartOS / illumos x86_640.1.10
macOS 15 arm640.1.10

Dependencies

No port depends on this one.