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

addpkg(main/gleamfonts): CLI tool to install nerdfonts on Termux #21121

Closed
wants to merge 1 commit into from

Conversation

massix
Copy link
Contributor

@massix massix commented Aug 14, 2024

Gleamfonts is a small CLI tool which allows user to easily fetch, install and configure patched fonts for Termux environments.

@Biswa96
Copy link
Member

Biswa96 commented Aug 14, 2024

This just downloads compiled binaries from repository instead of compiling it from source.

@massix
Copy link
Contributor Author

massix commented Aug 14, 2024

This just downloads compiled binaries from repository instead of compiling it from source.

That's correct, since it runs on the Erlang VM there is no need to compile them first.

I can change the recipe to compile them if needed, it should not be that difficult

@massix massix marked this pull request as draft August 14, 2024 09:52
@massix massix force-pushed the feat/add-gleamfonts branch 2 times, most recently from 875378c to 75d9f25 Compare August 14, 2024 11:01
Gleamfonts is a small CLI which allows user to easily fetch, install and
configure patched fonts for Termux environments.
@TomJo2000
Copy link
Member

TomJo2000 commented Aug 14, 2024

Regardless if the Erlang VM would make it work with pre-compiled binaries, we build all packages from source.
You will need to set up the gleam toolchain as a termux_step_pre_configure() as well.

A termux_setup_gleam helper (similar to the ones available for other languages) should have been added with the package,
but evidently wasn't.
@cattokomo would you be available to do that?

@TomJo2000
Copy link
Member

TomJo2000 commented Aug 14, 2024

Also, since opening a PR skips the package request template.
Let me quickly fill that out here for this package.


Why is it worth to add this package?

Utility for downloading NerdFonts.

Home page URL

https://github.com/massix/gleamfonts

Source code URL

https://github.com/massix/gleamfonts

Packaging policy acknowledgement

  • The project is actively developed.
  • The project has existing packages and is "well known".
  • Licensed under an open source license.
  • Not available through a language package manager: pip, npm, cpan, cargo, etc.
  • Not taking up too much disk space (< 100MiB per architecture, exceptions can be made)
  • Not duplicating the functionality of existing packages.
  • Not serving hacking, malware, phishing, spamming, spying, ddos functionality.
  • I certify that I have read Termux Packaging Policy and understand that my request will be denied if it is found lacking.

Additional information

The package depends on erlang and libsqlite.

I think the main issue I see with adding this package to the main repository is that,
for lack of a nicer way to put this,
it's a personal hobby project you started last week.

That's great, and I'm happy you're having fun writing it.
But unfortunately maintainer time and repository space don't come free.
This project is probably a better fit for the Termux User Repository.
https://github.com/termux-user-repository/tur

You can of course continue to use this PR for CI testing.

@TomJo2000
Copy link
Member

On a personal note.
I actually have a similar utility, in the form of a Bash script, as part of my dotfiles.
https://github.com/TomJo2000/.dotfiles/blob/main/.config/meta/fetch_fonts.sh

I've been meaning to polish it up for inclusion in the termux-tools package.

@massix
Copy link
Contributor Author

massix commented Aug 14, 2024

I think the main issue I see with adding this package to the main repository is that, for lack of a nicer way to put this, it's a personal hobby project you started last week.

That's great, and I'm happy you're having fun writing it. But unfortunately maintainer time and repository space don't come free. This project is probably a better fit for the Termux User Repository. https://github.com/termux-user-repository/tur

You can of course continue to use this PR for CI testing.

I do completely understand and there are no bad feelings (so don't worry about finding "a nicer way of putting this" 😄 ), I just thought it would be a good idea to have it distributed via Termux, despite the fact that I am the developer.

I will take a look at TUR and add it there instead, I didn't even know that TUR existed to be honest 😅

[x] Not available through a language package manager: pip, npm, cpan, cargo, etc.
I'm actually not sure on that one

Regarding this point, gleam and erlang packages are much similar to rust crates or Golang packages, so it should be the same principle!

I actually have a similar utility, in the form of a Bash script, as part of my dotfiles.
https://github.com/TomJo2000/.dotfiles/blob/main/.config/meta/fetch_fonts.sh

I too have something similar but Termux is quite special, in that it accepts only a single font and it must be installed on a specific path for it to work. Of course a simple bash script or nix derivation could easily solve it, but I thought why not, let's do something more generic 😅

I don't want to waste any more minutes of your CI so feel free to close this if you are definitely sure that you won't be accepting this in upstream!

@TomJo2000
Copy link
Member

I do completely understand and there are no bad feelings (so don't worry about finding "a nicer way of putting this" 😄 ), I just thought it would be a good idea to have it distributed via Termux, despite the fact that I am the developer.

Thanks for being so understanding about the situation.
We're always happy to have upstream involved in packaging when the interest is there.

I will take a look at TUR and add it there instead, I didn't even know that TUR existed to be honest 😅

It's at a similar level of officiality as resources like Arch's AUR, or Fedora's COPR.
We offer an official tur-repo "package" to access TUR packages
(similar to the x11-repo or root-repo "packages" for accessing those repositories)
but we do not handle package requests, bug reports or infrastructure for the TUR.

We do commonly collaborate with the TUR maintainers.
And packages can absolutely move from one to the other.
But it's a separate repository with separate infrastructure.

Regarding this point, gleam and erlang packages are much similar to rust crates or Golang packages, so it should be the same principle!

Yep that makes sense to me, I'm just not familiar with Gleam or Erlang as a language.

Of course a simple bash script or nix derivation could easily solve it, but I thought why not, let's do something more generic 😅

👍

I don't want to waste any more minutes of your CI so feel free to close this if you are definitely sure that you won't be accepting this in upstream!

No worries about that.
You can also enable Actions on your fork of termux/termux-packages,
or use our package build container or environment setup locally if you have access to a "regular" Linux (or even WSL) machine.
https://github.com/termux/termux-packages/wiki/Build-environment#setting-up

I will be closing this PR as per your request.

@TomJo2000 TomJo2000 closed this Aug 14, 2024
@mbekkomo
Copy link
Contributor

A termux_setup_gleam helper (similar to the ones available for other languages) should have been added with the package, but evidently wasn't. @cattokomo would you be available to do that?

I can work on that, but one problem is to get Erlang working in CI. I've tried packaging rebar3 with CI's Erlang but it not went smoothly. I tried providing Erlang with Kerl but it failed to build it.

@TomJo2000
Copy link
Member

So we'd need a termux_setup_erlang as well.

@massix
Copy link
Contributor Author

massix commented Aug 14, 2024

A termux_setup_gleam helper (similar to the ones available for other languages) should have been added with the package, but evidently wasn't. @cattokomo would you be available to do that?

I can work on that, but one problem is to get Erlang working in CI. I've tried packaging rebar3 with CI's Erlang but it not went smoothly. I tried providing Erlang with Kerl but it failed to build it.

It will probably be of no help but I got rebar3 working on Termux with this script if you might be interested!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants