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

chore: Release the binary to the package manager for different Platform​ #5247

Open
1 of 3 tasks
Zheaoli opened this issue Dec 10, 2023 · 10 comments
Open
1 of 3 tasks
Labels
github_actions Pull requests that update GitHub Actions code platform:linux Linux related issues and PRs platform:mac macOS related issues and PRs platform:windows Windows related issues and PRs type:refactor Refactoring on codebase

Comments

@Zheaoli
Copy link
Collaborator

Zheaoli commented Dec 10, 2023

Description

For now, We release the binary file by using the GitHub release page. And the people may need to download the binary manually.

So I propose here to release the binary file to the package manager for different platform.

The following is the design detail

Pre Step

Release Interval

We will release two different binary

  1. Stable release
  2. Daily Nightly release automatically.

Platform release

MacOS

The arch we will release binary for are

  1. x86_64
  2. Apple Silicon

Or maybe we can release a universal binary?

We will choose the homebrew as our target package manager.

We may need to maintain a tap repo on our own, like https://github.com/wez/homebrew-wezterm. So we just need to patch the version and checksum field in the file in the release workflow and commit it. All the processes would be automatic.

Linux

Linux release is a little bit different. There are too many distributions, so we need to decide to choose the distribution we will take care of. I think the following distribution would be great.

  1. Ubuntu
  2. Arch Linux based.

The arch we will release binary for are:

  1. X86_64
  2. aarch64?(not sure about it)

For ubuntu, the electron has supported the official Snapcraft release plugin. FYI: https://www.electronjs.org/docs/latest/tutorial/snapcraft , I will investigate it if it works or not

For Arch Linux, we need to maintain a git repo like https://github.com/Zheaoli/linux-xanmod-manjusaka.So we just need to patch the version and checksum field in the file in the release workflow, commit it, and push it to the aur repo. All the processes would be automatic.

I think the package name should be:

  1. affine-official
  2. affine-nightly-official

Windows

I'm not sure we need to support windows package manager.

Use case

No response

Anything else?

No response

Are you willing to submit a PR?

  • Yes I'd like to help by submitting a PR!
@Zheaoli Zheaoli added the story Features perceivable by end-users label Dec 10, 2023
@github-project-automation github-project-automation bot moved this to 🆕 *Untriaged in AFFiNE Project Dec 10, 2023
@Zheaoli Zheaoli added platform:windows Windows related issues and PRs platform:mac macOS related issues and PRs platform:linux Linux related issues and PRs and removed story Features perceivable by end-users labels Dec 10, 2023
@Zheaoli
Copy link
Collaborator Author

Zheaoli commented Dec 10, 2023

@Brooooooklyn Would mind taking a look at this proposal when you get time?

We can discuss about the detail in the issue

@STRRL
Copy link

STRRL commented Dec 10, 2023

I used affine beta with Appimage on linux, basically it works well.

@SteveLauC
Copy link

For Linux, I recommend releasing it to FlatHub

@joooye34 joooye34 added type:refactor Refactoring on codebase github_actions Pull requests that update GitHub Actions code labels Dec 12, 2023
@Brooooooklyn
Copy link
Member

We have Homebrew cask for our stable version, so I think we only need to consider the Linux distibutions https://formulae.brew.sh/cask/affine

@Pkcarreno
Copy link

On Windows exist Chocolatey and Scoop

I'm familiar with Scoop, this project meets the criteria to be accepted on the extra bucket (buckets are repos with apps, and the extra bucket is for GUI apps). I can make a manifest and then add a PR to Scoop's extra repo so Affine can be on Scoop

@Pkcarreno
Copy link

Sorry for the delay
I have some updates:

There is already a PR for Affine in the Scoop Extras repo, but this one was for version 0.7.2 and that one installed Affine from the .zip file.... Well, that .zip file no longer exists since version 0.7.3.

This "new" installer has a strange behavior (for me) in the installation. normally what scoop does is to take a portable version of an app or the executable and place it inside the scoop directory, this way scoop can manipulate the app (to update or remove it, etc...) but I don't know how to adapt this installer to what scoop expects.

It reminds me of the chrome installer (somehow) so I checked the chrome manifest in scoop (the file with the installation steps) and discovered that using an argument it is possible to manipulate the behavior of the installer, in this case to place the app data inside the scoop directory. Does the Affine installer have some arguments to manipulate the data? or where can I learn about how the Affine installer works in order to understand the behavior to see what I can do?

@EYHN EYHN moved this from 🆕 *Untriaged to 🙋 Upvoting in AFFiNE Project Mar 11, 2024
@affine-issue-bot
Copy link

Issue Status: 🙋 Upvoting

🙋 Upvoting

We are currently evaluating demand for the issue and checking whether it requires complicated or risky changes. Please leave a vote or comment if you think it should be prioritized.

This is an automatic reply by the bot.

@aliesbelik
Copy link

Added to scoop's Extras bucket (ScoopInstaller/Extras#11734):

scoop bucket add extras
scoop install affine

@pengx17
Copy link
Collaborator

pengx17 commented Mar 22, 2024

@aliesbelik thank you :)

@XotEmBotZ
Copy link

XotEmBotZ commented Feb 15, 2025

For linux I also do suggest flathub over any distribution specific packaging format.
This allows to allocate more resources in development of the project than maintaining different packaging format.

(For context I am currently replying you from a microsoft Edge which in available in flathub)

Also it would be beneficial to get a rough deadline on the release.
I noticed that there is a flatpak build already present. So in my understanding pushing that to flathub shouldn't be a huge issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
github_actions Pull requests that update GitHub Actions code platform:linux Linux related issues and PRs platform:mac macOS related issues and PRs platform:windows Windows related issues and PRs type:refactor Refactoring on codebase
Projects
Status: 🙋 Upvoting
Development

No branches or pull requests

9 participants