casey / just

🤖 Just a command runner
https://just.systems
Creative Commons Zero v1.0 Universal
18.74k stars 426 forks source link

Suggestion: alias for a module #2216

Open Splines opened 1 week ago

Splines commented 1 week ago

I have checked the module documentation and the aliases documentation.

It'd be awesome if we could do something like this

mod test ".config/commands/test.justfile"
alias t := test

And use it like just t test-recipe-in-test-justfile, i.e. alias the module itself. Previously, the hack around modules was as follows where you could do this:

alias d := docker
# Groups docker commands
docker recipe='' *ARGS='':
just -f ./config/commands/docker.justfile {{recipe}} {{ARGS}}
casey commented 1 week ago

This seems totally reasonable to me!