AUR package
Mohan-cloud opened this issue ยท 11 comments
Hi, I am looking into creating an AUR package for this project. Do you have any thoughts on that? Thank you!
Hi, thanks for your suggestion.
I'm not using Arch, so neither AUR, I don't know if that's a common practice to publish python packages on AUR in addition to pip.
I was recently trying to automate PyPI pushing and versioning with Github Action. If we want to create an AUR Package, the process has to be automated too, to avoid the hassle of uploading and versioning every minor patch.
I've searched a bit and there appear to be existing solutions:
Publication: https://github.com/marketplace/actions/publish-aur-package
Build and publication: https://github.com/marketplace/actions/build-aur-package-push-to-the-aur
Did you already pushed on AUR, or have any experience in AUR/Github automation?
Yes, installing from official repo/AUR is the recommended way to install python packages. (https://wiki.archlinux.org/title/Python#Package_management).
The GitHub action for AUR seems like the ideal way to publish. And to answer your question, I don't have previous experience with AUR/GitHub actions.
Well, I looked into it and there seems to be lively conversations about python packages on Arch forums :)
So, we would need a PKGBUILD
file, which does not look too complicated. The only thing is I wanted to switch from setup.py
to pyproject.toml
, I'm not quite sure the procedure is exactly the same.
Then, the other tricky part is dependencies. yaml
is available on AUR but not py_cui
. From what I understand we would need to make an AUR package for py_cui
too. Which is not ideal as we would need to maintain it I guess.
Any thoughts ? As I said I'm not familiar with AUR and Arch systems.
I do have a working PKGBUILD
file. If you do switch to pyproject.toml
we can follow these steps outlined in the archwiki
py_cui will be installed from requirements.txt and there will no need to maintain an AUR package for it.
Ok, that looks good to me!
If you want to, you can try to make a test build with your PKGBUILD
file, and you may also make a test install. If it works, you can make a PR. I'll get a testing env to give it a try too.
I'll look into it in the next few days, and will include a GitHub Action to automate the build/publish process.
For reference. PKGBUILD.txt
Though I think if you are using GitHub actions this won't be needed and everything can be automated at your end. I'll happily help with testing. Thanks!
Alright! I think I got it done :)
So, the package is uploaded on AUR. I'm testing on a Docker Arch image and I think everything works fine.
I'm currently using:
git clone https://aur.archlinux.org/python-recoverpy.git
cd python-recoverpy
makepkg -sri
Do you see any other preferable installation procedure ?
Also, can you give it a try on your system ?
That's great! I can confirm successful installation in my system.
Installation can also be done with AUR helpers like yay
or paru
.
Ok, I'll add a line regarding AUR package installation in the README.
Do you think yay -S python-recoverpy
will suit Arch users? Meaning there is no major conflit about yay
in Arch community? :)
It should totally be fine! AFAIK there is no conflict about it! ๐
Perfect! :)
I'll close this issue. Thanks for the suggestion and your help. I've learned a bit about Arch ecosystem doing it.
Feel free to suggest anything else!