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

configure verbosity in config file #670

Closed
crimson-med opened this issue May 21, 2020 · 7 comments
Closed

configure verbosity in config file #670

crimson-med opened this issue May 21, 2020 · 7 comments

Comments

@crimson-med
Copy link

I noticed we can run release-it --verbose and this will display the output of all hooks.
This is very practical as in my hooks I have some ssh commands that launch a script and thus I can see the output of scripts:

{
    "hooks": {
        "before:init": "echo 'Deploying XXX'",
        "after:bump": "git push origin master --follow-tags",
        "after:release": [
            "ssh -t -t user@dev 'sudo ./pack.sh v${version}'",
            "ssh -t -t user@prod 'sudo ./unpack.sh v${version} && . post-deploy.sh ${version}'",
            "echo Successfully released ${name} v${version} to ${repo.repository}.\n"
        ]
    }
  }

Is there any way to add --verbose to my: release-it.json so by default when I simply do the command release-it it will be with the verbose info

@webpro
Copy link
Collaborator

webpro commented May 21, 2020

Did you try to add "verbose": true? Otherwise it's a bug :)

@crimson-med
Copy link
Author

crimson-med commented May 21, 2020

Yes I also tried:

{
    "verbose": true,
    "hooks": {
        "before:init": "echo 'Deploying XXX'",
        "after:bump": "git push origin master --follow-tags",
        "after:release": [
            "ssh -t -t user@dev 'sudo ./pack.sh v${version}'",
            "ssh -t -t user@prod 'sudo ./unpack.sh v${version} && . post-deploy.sh ${version}'",
            "echo Successfully released ${name} v${version} to ${repo.repository}.\n"
        ]
    }

@webpro
Copy link
Collaborator

webpro commented May 21, 2020

OK, clear. On *nix you could add a function or alias for this, though, for example:

alias release="release-it --verbose"

@crimson-med
Copy link
Author

Seeing as we use release-it to make the deployment easier for multiple contributors of the project I wouldn't want to ask everyone to add an alias. Is this a confirmed bug that "verbose": true does not change anything or is it a pending feature?

@webpro
Copy link
Collaborator

webpro commented Jun 1, 2020

I think everything is working fine actually. Which version of release-it are you using?

  • "verbose": true - log hooks commands and their output
  • "verbose": 2 - log all (hooks + internal) commands and their output

Verified that this also works from a local .release-it.json config file.

I will updated the docs for raising the verbosity level from a config file.

@crimson-med
Copy link
Author

my current version is 13.6.2 and during post creation was 13.6.1

As of 13.6.2 this is now working

@webpro
Copy link
Collaborator

webpro commented Jun 3, 2020

The 13.6.x releases contain no related changes, but I'm happy it's working for you now.

@webpro webpro closed this as completed Jun 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants