Closed psprint closed 1 year ago
Sorry but I don't see why this should ever be part of zinit.
This is feature creep and only caters the need of a single person. Correct if I'm wrong but I just don't believe there's anyone else beside you that will use this.
I in general agree with you @pschmitt Yes it's a narrow feature. However I by intuition think that it can be part of zinit, because zinit is used to provide commands via shims. The INI commands can be seen as a manual shims. User could build a command that has its IO redirections tightly set and CWD and others. So for example instead of writing script or creating alias for fzf that greps files in a directory one could create an INI file with CWD set to the directory with some fancy input redirection like <(ls -1 $PWD)
for example.
Sure, but scripts are portable and this is not.
Not to beat a dead horse, but it would bitrot in zinit.
Could this not be an annex?
Description
A new feature: running of commands stored in INI file. The INI file of a command allows to set:
Example command (included in the PR):
Motivation and Context
I've created a bigger project zseriveces/command-CI-server however it didn't start with momentum, so I thought that extending zinit might be a good idea – it has some sense to provide limited
run
support to just run the commands. It's nice, for example, that editing zinit sources afterzi cmd zi
that executes the example INI file (zinit.git/cmds/zi.ini
) is possible.The commands are searched in
~/.config/zinit/cmds
and in$ZINIT[BIN_DIR]/cmds
by default. Other commands will be found in$ZICMD_COMMAND_PATH
variable (:
-separated paths).Related Issue(s)
Usage examples
How Has This Been Tested?
Types of changes
Checklist: