Closed MartinHelmut closed 3 years ago
One idea is using categories, defining sub commands that can run for specific folder or list of folders:
[commands.install]
script = "jest"
[commands.install.cpp]
script = "some install script"
# dir = "src/cpp"
dir = [ "src/cpp1", "src/cpp2" ]
This would give the option to run all, one or multiple with the comma operator:
# All
litr install
# One
litr install cpp
# Multiple specific
litr install cpp,js,java
Note: Not using a glob pattern is to avoid matching of files and to be specific. Every folder serves as a "cwd" (current working directory) to the executed command. Therefore executing every of those commands in every folder.
Sub-commands and folder restrictions are added to https://github.com/krieselreihe/litr/wiki/Setup
There needs to be a way to run different scripts per folder with one command. E.g.
litr test
executes different scripts on different folders.