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

Inject debug|info|error bash functions to the plugins #401

Open
arm4b opened this issue Feb 14, 2023 · 0 comments
Open

Inject debug|info|error bash functions to the plugins #401

arm4b opened this issue Feb 14, 2023 · 0 comments
Labels

Comments

@arm4b
Copy link
Member

arm4b commented Feb 14, 2023

Try to inject from the BitOps core bash functions into the plugins.

And so we could do this in plugin deploy.sh:

#!/bin/bash

info "This is an info message"
debug "This is debug"
error "Error message"

which will be consistent with the BitOps py core and follow the same color palette.

This way, depending on the real BITOPS_LOGGING_LEVEL set by the user in config, we use the respective logging level in the plugins (deploy.sh) bash code too.

This will help dealing with the logging mess in the plugins (set -x) and overall improve #270, allowing to use BitOps more as a framework and consistent system with helpers.

https://unix.stackexchange.com/questions/233091/bash-functions-in-shell-variables/233142#233142

@arm4b arm4b added the feature label Feb 14, 2023
@arm4b arm4b changed the title Plugins: inject debug|info|error bash functions Jnject debug|info|error bash functions to the plugins Feb 14, 2023
@arm4b arm4b changed the title Jnject debug|info|error bash functions to the plugins Inject debug|info|error bash functions to the plugins Feb 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant