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

Colourise output #82

Open
Mrtenz opened this issue Jul 14, 2023 · 0 comments
Open

Colourise output #82

Mrtenz opened this issue Jul 14, 2023 · 0 comments
Assignees

Comments

@Mrtenz
Copy link
Member

Mrtenz commented Jul 14, 2023

The output can be a bit unreadable, especially with lots of changes. See the output below for example. This would be a lot more readable if "Warning" was yellow, errors were red, and so on. We can accomplish this with chalk.

morten:snaps/ (main) $ yarn create-release-branch                                                                   
WARNING: Could not determine changes for workspace package @metamask/create-snap version 0.36.1-flask.1 based on Git tag "@metamask/[email protected]"; using tag for root package root version 0.36.1-flask.1, "v0.36.1-flask.1", instead.
WARNING: Could not determine changes for workspace package @metamask/example-snaps version 0.36.1-flask.1 based on Git tag "@metamask/[email protected]"; using tag for root package root version 0.36.1-flask.1, "v0.36.1-flask.1", instead.
WARNING: Could not determine changes for workspace package @metamask/snaps-browserify-plugin version 0.36.1-flask.1 based on Git tag "@metamask/[email protected]"; using tag for root package root version 0.36.1-flask.1, "v0.36.1-flask.1", instead.
WARNING: Could not determine changes for workspace package @metamask/rpc-methods version 0.36.1-flask.1 based on Git tag "@metamask/[email protected]"; using tag for root package root version 0.36.1-flask.1, "v0.36.1-flask.1", instead.
WARNING: Could not determine changes for workspace package @metamask/snaps-cli version 0.36.1-flask.1 based on Git tag "@metamask/[email protected]"; using tag for root package root version 0.36.1-flask.1, "v0.36.1-flask.1", instead.
WARNING: Could not determine changes for workspace package @metamask/snaps-controllers version 0.36.1-flask.1 based on Git tag "@metamask/[email protected]"; using tag for root package root version 0.36.1-flask.1, "v0.36.1-flask.1", instead.
WARNING: Could not determine changes for workspace package @metamask/snaps-execution-environments version 0.36.1-flask.1 based on Git tag "@metamask/[email protected]"; using tag for root package root version 0.36.1-flask.1, "v0.36.1-flask.1", instead.
WARNING: Could not determine changes for workspace package @metamask/snaps-jest version 0.36.1-flask.1 based on Git tag "@metamask/[email protected]"; using tag for root package root version 0.36.1-flask.1, "v0.36.1-flask.1", instead.
WARNING: Could not determine changes for workspace package @metamask/snaps-rollup-plugin version 0.36.1-flask.1 based on Git tag "@metamask/[email protected]"; using tag for root package root version 0.36.1-flask.1, "v0.36.1-flask.1", instead.
WARNING: Could not determine changes for workspace package @metamask/snaps-simulator version 0.36.1-flask.1 based on Git tag "@metamask/[email protected]"; using tag for root package root version 0.36.1-flask.1, "v0.36.1-flask.1", instead.
WARNING: Could not determine changes for workspace package @metamask/snaps-types version 0.36.1-flask.1 based on Git tag "@metamask/[email protected]"; using tag for root package root version 0.36.1-flask.1, "v0.36.1-flask.1", instead.
WARNING: Could not determine changes for workspace package @metamask/snaps-ui version 0.36.1-flask.1 based on Git tag "@metamask/[email protected]"; using tag for root package root version 0.36.1-flask.1, "v0.36.1-flask.1", instead.
WARNING: Could not determine changes for workspace package @metamask/snaps-utils version 0.36.1-flask.1 based on Git tag "@metamask/[email protected]"; using tag for root package root version 0.36.1-flask.1, "v0.36.1-flask.1", instead.
WARNING: Could not determine changes for workspace package @metamask/snaps-webpack-plugin version 0.36.1-flask.1 based on Git tag "@metamask/[email protected]"; using tag for root package root version 0.36.1-flask.1, "v0.36.1-flask.1", instead.
WARNING: Could not determine changes for workspace package @metamask/test-snaps version 0.36.1-flask.1 based on Git tag "@metamask/[email protected]"; using tag for root package root version 0.36.1-flask.1, "v0.36.1-flask.1", instead.
Project appears to have workspaces. Following monorepo workflow.
Release spec already exists. Picking back up from previous run.
Error: Your release spec could not be processed due to the following issues:

* The following packages, which have changed since their latest release, are missing.

  - @metamask/create-snap
  - @metamask/example-snaps
  - @metamask/rpc-methods
  - @metamask/snaps-browserify-plugin
  - @metamask/snaps-cli
  - @metamask/snaps-controllers
  - @metamask/snaps-jest
  - @metamask/snaps-rollup-plugin
  - @metamask/snaps-types

  Consider including them in the release spec so that any packages that rely on them won't break in production.

  If you are ABSOLUTELY SURE that this won't occur, however, and want to postpone the release of a package, then list it with a directive of "intentionally-skip". For example:

    packages:
      "@metamask/create-snap": intentionally-skip
      "@metamask/example-snaps": intentionally-skip
      "@metamask/rpc-methods": intentionally-skip
      "@metamask/snaps-browserify-plugin": intentionally-skip
      "@metamask/snaps-cli": intentionally-skip
      "@metamask/snaps-controllers": intentionally-skip
      "@metamask/snaps-jest": intentionally-skip
      "@metamask/snaps-rollup-plugin": intentionally-skip
      "@metamask/snaps-types": intentionally-skip

The release spec file has been retained for you to edit again and make the necessary fixes. Once you've done this, re-run this tool.

/var/folders/8w/2tkyvh9n30n0jqqzvxmkzhs80000gn/T/create-release-branch/root/RELEASE_SPEC
    at validateReleaseSpecification (./node_modules/@metamask/create-release-branch/dist/release-specification.js:231:15)
    at async followMonorepoWorkflow (./snaps/node_modules/@metamask/create-release-branch/dist/monorepo-workflow-operations.js:74:34)
    at async main (./snaps/node_modules/@metamask/create-release-branch/dist/main.js:22:9)
    at async cli (./Mrtenz/snaps/node_modules/@metamask/create-release-branch/dist/cli.js:8:5)
@Mrtenz Mrtenz self-assigned this Jul 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants