action-automatic-releases icon indicating copy to clipboard operation
action-automatic-releases copied to clipboard

Update node version to 16

Open lautitoti opened this issue 2 years ago • 24 comments

As node 12 has been deprecated and Github is looking to upgrade all github actions to node 16 (more https://github.blog/changelog/2022-09-22-github-actions-all-actions-will-begin-running-on-node16-instead-of-node12/ ) this commit will update the node version used.

lautitoti avatar Oct 19 '22 01:10 lautitoti

I think this PR covers more warnings: https://github.com/marvinpinto/actions/pull/546

taysta avatar Oct 20 '22 10:10 taysta

Is there any fork we can use until it merged?

Enase avatar Jan 12 '23 17:01 Enase

Till such PRs are merged, I am using the commit hashes of the PRs. For this PR, to resolve Node 12 warning, I could use:

uses: marvinpinto/action-automatic-releases@6273874b61ebc8c71f1a61b2d98e234cf389b303

rtrad89 avatar Jan 18 '23 21:01 rtrad89

cc @marvinpinto 🙏🏻

dimaqq avatar Mar 01 '23 02:03 dimaqq

@marvinpinto Please merge

reubensamuel avatar Mar 14 '23 15:03 reubensamuel

Is there an alternative repo that we can use?

michelkok avatar Mar 14 '23 15:03 michelkok

@michelkok look at https://github.com/softprops/action-gh-release

gurza avatar Apr 15 '23 21:04 gurza

@gurza do you have any advice on a config that can replicate how this works with https://github.com/softprops/action-gh-release

taysta avatar Apr 16 '23 08:04 taysta

@gurza do you have any advice on a config that can replicate how this works with https://github.com/softprops/action-gh-release

Here is an example of a workflow using action-gh-release. The workflow is triggered whenever a new tag is pushed to your repository.

name: Release

on:
  push:
    tags:
      - '*'

jobs:
  release:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout code
        uses: actions/checkout@v2

      - name: Build project
        run: |
          # insert your project's build command here

      - name: Create GitHub Release
        uses: softprops/action-gh-release@v1
        with:
          files: |
            path/to/file1
            path/to/file2
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

The GITHUB_TOKEN secret is a GitHub App installation access token and is used to authenticate in order to create the release.

gurza avatar Jun 22 '23 13:06 gurza

Dude, I've forked this due to this NOT being merged.

https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/

You need to get this fix into the repository.

Dude, I've forked this due to this NOT being merged.

https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/

You need to get this fix into the repository.

Hey, on my side I switched to softprops/action-gh-release and it is working perfectly : https://github.com/Nyuwb/wsl-switch/commit/80800cc925db1f15bf677e2ced63fb7d7f498c43

Nyuwb avatar Sep 15 '23 12:09 Nyuwb

Dude, I've forked this due to this NOT being merged. https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/ You need to get this fix into the repository.

Hey, on my side I switched to softprops/action-gh-release and it is working perfectly : Nyuwb/wsl-switch@80800cc

It doesn't really work the same for me, have to bump a version tag with the one you linked, unless I'm missing something

taysta avatar Sep 25 '23 11:09 taysta

Dude, I've forked this due to this NOT being merged. https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/ You need to get this fix into the repository.

Hey, on my side I switched to softprops/action-gh-release and it is working perfectly : Nyuwb/wsl-switch@80800cc

It doesn't really work the same for me, have to bump a version tag with the one you linked, unless I'm missing something

Do you have anything to link ?

And for everyone, this will be outdated soon as Github is switching to node 20 soon : https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/

Nyuwb avatar Sep 25 '23 12:09 Nyuwb

@marvinpinto has not pushed any commits into GH at all (i.e. any activity in any repo) since April, 2023; I'd consider this project abandoned at this point.

mmllc-jsilverman avatar Nov 17 '23 15:11 mmllc-jsilverman

So I spent a couple days trying to find a suitable alternative that can replace this action. My criteria was getting a similar changelog because the other options don't exactly do the same. I've finally settled on something so might as well share so you don't have to waste time.

I ended up using https://github.com/tj-actions/git-cliff to generate the changelog and then https://github.com/ncipollo/release-action to upload the release with the changelog and artifacts. Both of these projects are actively maintained at the time of writing this.

name: Release

on:
  push:
    tags:
      - 'v*.*.*'

jobs:
  release:
    name: Release
    runs-on: ubuntu-latest
    steps:
      - name: Checkout code
        uses: actions/checkout@v4
        with:
          fetch-depth: 0 # Important for changelog

      - name: Generate changelog with git-cliff
        uses: tj-actions/git-cliff@v1
        with:
          args: --latest --strip all
          output: "CHANGELOG.md"

      - name: Create Release
        uses: ncipollo/release-action@v1
        with:
          artifacts: "dist/*"
          token: ${{ secrets.GITHUB_TOKEN }}
          bodyFile: "CHANGELOG.md"
          draft: false
          prerelease: false

Ravencentric avatar Nov 18 '23 14:11 Ravencentric

Abandoning this action, I did a direct replacement using gh-release.

ptr727 avatar Nov 26 '23 18:11 ptr727

Abandoning this action, I did a direct replacement using gh-release.

I found that this setup just appends the artifacts to an existing release instead of creating a new one, were you able to fix that?

taysta avatar Feb 04 '24 10:02 taysta

This action has been forked and updated in a backwards-compatible way at https://github.com/crowbarmaster/GH-Automatic-Releases

Actions marketplace URL: https://github.com/marketplace/actions/cbgh-automatic-releases This aims to be a drop-in replacement for this action while requiring node20 (and packing in more improvements).

koushik-ms avatar Feb 17 '24 15:02 koushik-ms

Abandoning this action, I did a direct replacement using gh-release.

I found that this setup just appends the artifacts to an existing release instead of creating a new one, were you able to fix that?

Seems to create new releases for me?
My code

ptr727 avatar Feb 18 '24 17:02 ptr727

Abandoning this action, I did a direct replacement using gh-release.

I found that this setup just appends the artifacts to an existing release instead of creating a new one, were you able to fix that?

Seems to create new releases for me? My code

That would be because you are pushing to a new tag each time, in my case I just push to 'latest' tag

taysta avatar Feb 23 '24 06:02 taysta

That would be because you are pushing to a new tag each time, in my case I just push to 'latest' tag

I see, I'm not familiar with that use in GH releases, it is not like a docker tag. If you use an actual versioned tag for release and prerelese then the github API can give you the latest released and latest prerelease version.

ptr727 avatar Feb 23 '24 15:02 ptr727

That would be because you are pushing to a new tag each time, in my case I just push to 'latest' tag

I see, I'm not familiar with that use in GH releases, it is not like a docker tag. If you use an actual versioned tag for release and prerelese then the github API can give you the latest released and latest prerelease version.

Yes but not everyone uses semver, my point was simply that the softprops alternative behaved differently as a drop-in replacement for our use case

taysta avatar Feb 23 '24 15:02 taysta

This action has been forked and updated in a backwards-compatible way at https://github.com/crowbarmaster/GH-Automatic-Releases

Actions marketplace URL: https://github.com/marketplace/actions/cbgh-automatic-releases

This aims to be a drop-in replacement for this action while requiring node20 (and packing in more improvements).

This one however is working a charm 👌

taysta avatar Feb 23 '24 15:02 taysta

This one however is working a charm 👌

Will keep it in mind as backup, thx.

ptr727 avatar Feb 23 '24 15:02 ptr727