summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorOleg Shparber2020-05-17 03:23:41 -0400
committerOleg Shparber2020-05-17 03:23:41 -0400
commit2a41eb63829da349b67406223fcf5a59406805aa (patch)
tree0261cf3403d02a15508727519a63fdd263ab8361
downloadaur-2a41eb63829da349b67406223fcf5a59406805aa.tar.gz
Add initial version
-rw-r--r--.SRCINFO15
-rw-r--r--PKGBUILD42
2 files changed, 57 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..158e2c8c0531
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,15 @@
+pkgbase = cascadia-code-git
+ pkgdesc = A new monospaced font that includes programming ligatures
+ pkgver = 1911.21.r9.g0610f2d
+ pkgrel = 1
+ url = https://github.com/microsoft/cascadia-code
+ arch = any
+ license = custom:OFL
+ makedepends = git
+ makedepends = python
+ provides = otf-cascadia-code=1911.21.r9.g0610f2d
+ source = git+https://github.com/microsoft/cascadia-code.git
+ sha256sums = SKIP
+
+pkgname = otf-cascadia-code-git
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..20169f3fe4bf
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,42 @@
+# Maintainer: Oleg Shparber <trollixx+aur@gmail.com>
+
+_gitname=cascadia-code
+pkgbase=cascadia-code-git
+pkgname=("otf-${pkgbase}") # "ttf-${pkgbase}"
+pkgver=1911.21.r9.g0610f2d
+pkgrel=1
+pkgdesc="A new monospaced font that includes programming ligatures"
+url="https://github.com/microsoft/${_gitname}"
+arch=('any')
+license=('custom:OFL')
+makedepends=('git' 'python')
+provides=("otf-cascadia-code=${pkgver}")
+#conflicts=('nerd-fonts-cascadia-code' 'ttf-cascadia-code' 'ttf-cascadia-code-git')
+source=("git+${url}.git")
+sha256sums=('SKIP')
+
+pkgver() {
+ cd "${_gitname}"
+ git describe --long | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
+}
+
+build() {
+ cd "${_gitname}"
+ # Using pip because deps in AUR are broken.
+ python -m venv .venv
+ source .venv/bin/activate
+ pip install -r requirements.txt
+ python build.py
+}
+
+package_otf-cascadia-code-git() {
+ cd "${_gitname}"
+ install -Dm644 build/*.otf -t "$pkgdir"/usr/share/fonts/OTF
+ install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
+}
+
+# package_ttf-cascadia-code-git() {
+ # cd "${_gitname}"
+ # install -Dm644 build/*.ttf -t "$pkgdir"/usr/share/fonts/TTF
+ # install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
+# }