finos / git-proxy

Deploy custom push protections and policies on top of Git
https://git-proxy.finos.org
Apache License 2.0
110 stars 72 forks source link

chore: automatically increment version in package.json on new release #596

Open divinetettey opened 3 months ago

divinetettey commented 3 months ago

This PR attempts to resolve this issue Automatically increment version in package.json on new release 📦 . The PR aims at automating the update off the version in pacakge.json

  1. A new step has been added to extract the version number from the draft release. this version number is then used in subsequent steps to update the package.json
  2. The extracted version number is used to update the package.json,package-lock.json and the docusaurus.config.js
  3. after update the update a commit is pushed back to the repository
linux-foundation-easycla[bot] commented 3 months ago

CLA Signed

The committers listed above are authorized under a signed CLA.

netlify[bot] commented 3 months ago

Deploy Preview for endearing-brigadeiros-63f9d0 canceled.

Name Link
Latest commit 54a7efe02b3de7f280b4faaede504440dd1ab437
Latest deploy log https://app.netlify.com/sites/endearing-brigadeiros-63f9d0/deploys/66633207a7d8a5000830adc6
netlify[bot] commented 3 months ago

Deploy Preview for endearing-brigadeiros-63f9d0 canceled.

Name Link
Latest commit 6b86691c3a5515b027734762757e132d45656402
Latest deploy log https://app.netlify.com/sites/endearing-brigadeiros-63f9d0/deploys/66fd617d02b9890008718bf3
JamieSlome commented 3 months ago

Thanks for the PR, @divinetettey 👍 Is there anyway we can update the package.json and package-lock.json version before we run the release? i.e. include the latest version number in the actual release itself

divinetettey commented 3 months ago

Thanks for the PR, @divinetettey 👍 Is there anyway we can update the package.json and package-lock.json version before we run the release? i.e. include the latest version number in the actual release itself

sure, let me take a look at this

divinetettey commented 3 months ago

Thanks for the PR, @divinetettey 👍 Is there anyway we can update the package.json and package-lock.json version before we run the release? i.e. include the latest version number in the actual release itself

sure, let me take a look at this

should this run before/after the release-drafter

JamieSlome commented 3 months ago

@divinetettey - we want the file bumps to occur before we make the NPM and GitHub releases. This is to ensure that the releases themselves include the correct version number.

codecov[bot] commented 3 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 57.39%. Comparing base (3b6cb6b) to head (6b86691).

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #596 +/- ## ======================================= Coverage 57.39% 57.39% ======================================= Files 46 46 Lines 1582 1582 ======================================= Hits 908 908 Misses 674 674 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

JamieSlome commented 3 months ago

@divinetettey, the @divinecodes will also need to authorise with EasyCLA to merge this pull request (heads up).

divinetettey commented 3 months ago

@divinetettey, the @divinecodes will also need to authorise with EasyCLA to merge this pull request (heads up).

yeah, my gitconfigs got messed and the commit was pushed with my personal account. I am going to squash the commit and push it with @divinetettey

divinetettey commented 3 months ago

Happy from my end. @divinetettey - have you been able to test the update_version step?

Yes, getting some failures with release-drafter, taking a look

divinetettey commented 3 months ago

Happy from my end. @divinetettey - have you been able to test the update_version step?

all good on my end