This commit is contained in:
Endeavorance 2025-05-10 10:46:40 -04:00
parent cc37b06d8b
commit cc19888102
14 changed files with 529 additions and 322 deletions

View file

@ -26,40 +26,28 @@ $ rundir x build # runs the `build` script in the original `.run` directory
## CLI
### List scripts
```
Usage: rundir [command]
```shell
$ rundir
Commands:
x <name> Run a script from the nearest rundir (alias: run)
new <name> Create a new script in the rundir (alias: create)
ls List all scripts in the rundir
ls <name> Print the absolute path to a specific script
which Print the absolute path of the rundir
help Show this help message
```
### Create script
## `rdx` alias
Consider setting an alias for `rundir x` to `rdx` for convenience:
```shell
$ rundir create myscript
alias rdx="rundir x"
```
### Run a script
Then you can run scripts with `rdx` instead of `rundir x`:
```shell
$ rundir x myscript
# ... or if you're in the root directory just...
$ .run/myscript
rdx build
```
### Print the path of the current rundir
```shell
$ rundir which
```
### Open a script in your editor
```shell
$ rundir edit myscript
```
### Print help message
```shell
$ rundir help
```