Github messages for voidlinux
 help / color / mirror / Atom feed
From: daniel-eys <daniel-eys@users.noreply.github.com>
To: ml@inbox.vuxu.org
Subject: Re: [WIP] nerd-fonts: fix font source
Date: Mon, 09 Mar 2020 16:27:16 +0100	[thread overview]
Message-ID: <20200309152716.WuRwiwgUUoVob0J-sbGKOrd2rsXwUNPSg9bx4QkckqM@z> (raw)
In-Reply-To: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-19976@inbox.vuxu.org>

[-- Attachment #1: Type: text/plain, Size: 2207 bytes --]

New comment by daniel-eys on void-packages repository

https://github.com/void-linux/void-packages/pull/19976#issuecomment-596599343

Comment:
* `create_wrksrc` and `build_wrksrc` are not needed anymore, upstream's tarball follows void's standard `${pkgname}-${version}`

* No need to fetch those `i_*.sh` scripts anymore, upstream's tarball includes them already.

* `do_install()` needed some adjustments to reflect the structure of the new tarball.

* I switched to `find ... -exec install ...` to really collect all .otf / .ttf files.

This is what I came up with. Feel free to include my suggestions.

```sh
# Template file for 'nerd-fonts'
pkgname=nerd-fonts
version=2.1.0
revision=2
archs=noarch
depends="font-util xbps-triggers nerd-fonts-ttf nerd-fonts-otf"
short_desc="Iconic font aggregator, collection and patcher"
maintainer="cinerea0 <cinerea0@protonmail.com>"
license="MIT"
homepage="https://nerdfonts.com"
distfiles="https://github.com/ryanoasis/nerd-fonts/archive/v${version}.tar.gz"
checksum="a084ca91a174b547bab4523507824c76aa91ebcf38f9256a4ffd181813f87bd8"

do_install() {
	vmkdir usr/share/fonts/NerdFonts/otf
	vmkdir usr/share/fonts/NerdFonts/ttf
	vmkdir usr/lib/NerdFonts

	find patched-fonts -name '*.otf' -exec install -Dm644 '{}' ${DESTDIR}/usr/share/fonts/NerdFonts/otf \;
	find patched-fonts -name '*.ttf' -exec install -Dm644 '{}' ${DESTDIR}/usr/share/fonts/NerdFonts/ttf \;

	# Remove Windows Compatible font versions
	find ${DESTDIR}/usr/share/fonts/NerdFonts -name '*Windows Compatible.*tf' -delete

	for sh in bin/scripts/lib/i_*.sh; do
		vinstall $sh 744 usr/lib/NerdFonts
	done

	vlicense LICENSE
}

nerd-fonts-otf_package() {
	archs=noarch
	short_desc="Iconic font aggregator, collection and patcher - otf fonts"
	font_dirs="usr/share/fonts/NerdFonts/otf"
	depends="font-util xbps-triggers"
	pkg_install() {
		vmove usr/share/fonts/NerdFonts/otf
	}
}

nerd-fonts-ttf_package() {
	archs=noarch
	short_desc="Iconic font aggregator, collection and patcher - ttf fonts"
	font_dirs="usr/share/fonts/NerdFonts/ttf"
	depends="font-util xbps-triggers"
	pkg_install() {
		vmove usr/share/fonts/NerdFonts/ttf
	}
}
```


       reply	other threads:[~2020-03-09 15:27 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-19976@inbox.vuxu.org>
2020-03-09 15:27 ` daniel-eys [this message]
2020-03-10  2:50 ` cinerea0

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200309152716.WuRwiwgUUoVob0J-sbGKOrd2rsXwUNPSg9bx4QkckqM@z \
    --to=daniel-eys@users.noreply.github.com \
    --cc=ml@inbox.vuxu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).