aboutsummaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
authorLuca Matei Pintilie <luca@lucamatei.com> 2023-09-13 23:59:09 +0200
committerThomas Voss <mail@thomasvoss.com> 2023-09-14 00:02:51 +0200
commita9b6c2bd68ccfd72a833355fce55feda914fe3bd (patch)
treefcfd937aac9dfc21034fee800b189e40fc902bdd /README.md
parente93e75ca1dd782fb0c6df97be89d03d7f1cc66d3 (diff)
Add MMV_NAME and MCP_NAME compile-time variablesv1.3.0
Due to the sheer popularity of the "mmv" name it might conflict with other programs installed on the user's computer. As such the MMV_NAME and MCP_NAME environmental variables can control the program's name at compile time, allowing the user to avoid name conflicts with other programs. If the variables are not set then they will silently default back to "mmv" and "mcp" respectively. Signed-off-by: Luca Matei Pintilie <luca@lucamatei.com> Co-authored-by: Thomas Voss <mail@thomasvoss.com>
Diffstat (limited to 'README.md')
-rw-r--r--README.md18
1 files changed, 18 insertions, 0 deletions
diff --git a/README.md b/README.md
index ce25f4f..2066f2f 100644
--- a/README.md
+++ b/README.md
@@ -18,6 +18,24 @@ $ make
$ sudo make install
```
+The following environment variables can also be set at compile-time to modify
+the names of the generated binaries:
+
+- `$MMV_NAME`
+ + The name of the file-moving binary (default is `mmv`). This is also used
+ to name the backups folder in `$XDG_CACHE_HOME`.
+- `$MCP_NAME`
+ + The name of the file-copying binary (default is `mcp`).
+
+If you are compiling with a custom binary name, you want to make sure that the
+environment variables actually get used when performing a `make install`. If
+you’re using `sudo`, you want to do this with the `-E` flag.
+
+```
+$ MMV_NAME=mmv-rs MCP_NAME=mcp-rs make
+$ MMV_NAME=mmv-rs MCP_NAME=mcp-rs sudo -E make install
+```
+
## Examples and Documentation
To avoid repeating myself everywhere, if you would like to see usage examples