un-ts / changesets-gitlab

GitLab CI cli for changesets like its GitHub Action.
https://opencollective.com/unts/projects/changesets-gitlab
MIT License
86 stars 33 forks source link

remove usage of `@actions/core` #170

Open meesvandongen opened 6 months ago

meesvandongen commented 6 months ago

In my previous issue I suggested changing the documentation to reflect the environment variables, but after some testing it seems that the environment variables are not set. Moreover, setting the environment variables is not possible from a child process (nodeJS) as far as I am aware.

For that problem specifically, I would suggest moving to files; e.g. changesets-gitlab-output.json

{
  "published": true,
  "publishedPackages": [
    { "name": "@xx/xx", "version": "1.2.0" },
    { "name": "@xx/xy", "version": "0.8.9" }
  ]
}

Then, a suggestion could be added to add the file to .gitignore.

More generally, @actions packages should not be used at all in this repo since it is only meant for Github actions.

If you are fine with such changes I can look into making a PR.

JounQin commented 6 months ago

Thanks @meesvandongen , actually I've never used the output feature previously.

I'm fine to migrate environment variables into ~/changesets-gitlab.output.json for example.

So, PR welcome!

meesvandongen commented 6 months ago

I have created a minimal change on https://github.com/un-ts/changesets-gitlab/pull/171, but haven't tested it yet.