Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add the _install-dependencies task and call it from make config #144

Merged
merged 1 commit into from
Nov 21, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,7 @@ clean:: # Clean-up project resources (main) @Operations

config:: # Configure development environment (main) @Configuration
# TODO: Use only 'make' targets that are specific to this project, e.g. you may not need to install Node.js
make \
terraform-install
make _install-dependencies

# ==============================================================================

Expand Down
7 changes: 7 additions & 0 deletions scripts/init.mk
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,15 @@ githooks-run: # Run git hooks configured in this repository @Operations
--all-files

_install-dependency: # Install asdf dependency - mandatory: name=[listed in the '.tool-versions' file]; optional: version=[if not listed]
echo ${name}
asdf plugin add ${name} ||:
asdf install ${name} $(or ${version},)

_install-dependencies: # Install all the dependencies listed in .tool-versions
for plugin in $$(grep ^[a-z] .tool-versions | sed 's/[[:space:]].*//'); do
make _install-dependency name="$${plugin}"
done

clean:: # Remove all generated and temporary files (common) @Operations
rm -rf \
.scannerwork \
Expand Down Expand Up @@ -138,6 +144,7 @@ HELP_SCRIPT = \
# ==============================================================================

${VERBOSE}.SILENT: \
_install-dependencies \
_install-dependency \
clean \
config \
Expand Down
Loading