webi-installers icon indicating copy to clipboard operation
webi-installers copied to clipboard

Add helper to check for git

Open coolaj86 opened this issue 4 years ago • 1 comments

We should have some helper functions that can check for system-level dependencies and be called in the __init_xxxx of any installer, and print out a helpful message if that tool isn't there.

We've partially done with this git, but it should be more universal - in almost every vim-* installer, for example.

_webi/template.sh (? or maybe bootstrap? I don't recall)

function webi_check_git() {
    # do the check / print the message
}

vim-prettier

function __init_vim_prettier() {
    webi_check_git
    # do stuff...
}

coolaj86 avatar Nov 24 '21 07:11 coolaj86

do you want bootstrap.sh to contain all the individual checks like function for checking git, vim, rg, or function should accept just the command name and check whether it is available or not.

rritik772 avatar Oct 05 '24 16:10 rritik772