Skip to content

feat(build): add GitHub Action to make release - #427

Merged
bee-san merged 3 commits into
bee-san:masterfrom
PsypherPunk:83-release-deb
Apr 9, 2024
Merged

feat(build): add GitHub Action to make release#427
bee-san merged 3 commits into
bee-san:masterfrom
PsypherPunk:83-release-deb

Conversation

@PsypherPunk

@PsypherPunk PsypherPunk commented Jan 24, 2022

Copy link
Copy Markdown
Collaborator

Add config. to, when a new tag is pushed:

  • build a .deb file using cargo-deb;
  • include the resulting .deb file in the subsequent release.

An example of one such release can be seen here.

Relates #83

@bee-san

bee-san commented Apr 7, 2024

Copy link
Copy Markdown
Owner

Merge conflicts :(

@PsypherPunk

Copy link
Copy Markdown
Collaborator Author

@bee-san, I can look to resolve these but is there still interest in this PR?

@bee-san

bee-san commented Apr 7, 2024

Copy link
Copy Markdown
Owner

@bee-san, I can look to resolve these but is there still interest in this PR?

Oooh great question!

We have this release.yaml https://github.com/RustScan/RustScan/blob/master/.github/workflows/release.yml

But it does not do .deb , and we'd like to make it do .deb 😅

I am thinking you can just copy this PR's yaml into that one?

@PsypherPunk

Copy link
Copy Markdown
Collaborator Author

@bee-san, sure, I'll take a look. There's some nice matrix-build steps going on in there so I'll try to do something with it.

@bee-san

bee-san commented Apr 7, 2024

Copy link
Copy Markdown
Owner

@bee-san, sure, I'll take a look. There's some nice matrix-build steps going on in there so I'll try to do something with it.

Thank you, that would honestly be awesome. Before this we had a bulky Docker-builder to set up debs (feel free to delete https://github.com/RustScan/RustScan/tree/master/rustscan-debbuilder in your PR) 🙈

Because of how cumbersome it was, new releases don't have .deb files :(

I was just saying today one of the most important things I should add is .deb building automation!!

@PsypherPunk
PsypherPunk force-pushed the 83-release-deb branch 3 times, most recently from ceea86c to 5b05f23 Compare April 8, 2024 08:38
@PsypherPunk
PsypherPunk marked this pull request as draft April 8, 2024 08:47
@PsypherPunk
PsypherPunk force-pushed the 83-release-deb branch 10 times, most recently from f37a78c to cdb21dd Compare April 8, 2024 11:19
Comment thread .github/workflows/release.yml Outdated
@PsypherPunk

PsypherPunk commented Apr 8, 2024

Copy link
Copy Markdown
Collaborator Author

@bee-san, PR updated.

I've moved it to draft in case you have feedback; there's on odd line to which I've added a comment; it works—you can see the resulting release here—but there's probably a much better way to handle it (I could pull out the version as is done later and resolve the path to the .deb complete, I suppose).

Comment thread .github/workflows/release.yml Outdated
@PsypherPunk
PsypherPunk force-pushed the 83-release-deb branch 3 times, most recently from 3368fc1 to 5c21d3f Compare April 8, 2024 12:17
@PsypherPunk
PsypherPunk marked this pull request as ready for review April 8, 2024 12:31
@bee-san

bee-san commented Apr 8, 2024

Copy link
Copy Markdown
Owner

want me to review? looks ok to you? :)

@PsypherPunk

Copy link
Copy Markdown
Collaborator Author

@bee-san, it works insofar as it generate a .deb file and attaches it to a release as per the existing release.yml so…yes 😬

As long as you're happy with the changes (and I deleted the right files you mentioned) then LGTM.

@bee-san

bee-san commented Apr 9, 2024

Copy link
Copy Markdown
Owner

@bee-san, it works insofar as it generate a .deb file and attaches it to a release as per the existing release.yml so…yes 😬

As long as you're happy with the changes (and I deleted the right files you mentioned) then LGTM.

Thanks!!

We only build for x86_64-linux? Do you think we should use the matrix to add support for more architectures or? 🤔

@PsypherPunk

Copy link
Copy Markdown
Collaborator Author

I'm assuming it would only make sense to build .deb files for Linux and the only arch. is currently x86_64-linux…?

If that changes (say, adding i686), it should just be a matter of changing those == 'x86_64-linux' checks to =~ 'linux' or similar.

However, I'd probably consider doing that in a separate PR, once this one's proven with the existing arch./release-process…?

@bee-san

bee-san commented Apr 9, 2024

Copy link
Copy Markdown
Owner

I'm assuming it would only make sense to build .deb files for Linux and the only arch. is currently x86_64-linux…?

If that changes (say, adding i686), it should just be a matter of changing those == 'x86_64-linux' checks to =~ 'linux' or similar.

However, I'd probably consider doing that in a separate PR, once this one's proven with the existing arch./release-process…?

Ok thank you! GitHub's matrix sucks :P

@bee-san
bee-san merged commit 1ec8ab4 into bee-san:master Apr 9, 2024
@PsypherPunk

PsypherPunk commented Apr 9, 2024

Copy link
Copy Markdown
Collaborator Author

Thanks, @bee-san! If anything does go awry with this during the next release, please let me know and I'll aim to fix.

@PsypherPunk
PsypherPunk deleted the 83-release-deb branch April 9, 2024 08:26
@bee-san

bee-san commented Apr 21, 2024

Copy link
Copy Markdown
Owner

It appears the release did not run? :(

https://github.com/PsypherPunk/RustScan/actions/workflows/release.yml

name: Release
on:
  push:
    tags:
      - '[0-9]+.[0-9]+.[0-9]+'
  pull_request:
    branches:
      - master
    paths:
      - 'Cargo.toml'
      - 'Cargo.lock'
      - '.github/workflows/release.yml'

The latest tag is 2.2.2, I am nto sure why it would not run :(

https://github.com/RustScan/RustScan/releases/tag/2.2.2

@PsypherPunk

Copy link
Copy Markdown
Collaborator Author

@bee-san, can I check how you actually created the tag?

Not entirely sure if/why that would matter but I'll take a look 😬

@bee-san

bee-san commented Apr 21, 2024

Copy link
Copy Markdown
Owner

@bee-san, can I check how you actually created the tag?

Not entirely sure if/why that would matter but I'll take a look 😬

I made it in GitHub releases with
image

thank you for your contributions!

@bee-san

bee-san commented Apr 21, 2024

Copy link
Copy Markdown
Owner

image

Ok so it did run eventually, that's nice to know!! Docker and homebrew did not like it, stuff to fix 😂

@PsypherPunk

Copy link
Copy Markdown
Collaborator Author

Phew! And there's a .deb an' everything!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants