summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorMark Wagie2024-05-03 09:31:25 -0600
committerMark Wagie2024-05-03 09:31:25 -0600
commit6787fe13637d653f1764a7d322edcb29c29f9676 (patch)
treee09bfce5eca5d45cdade3c4118de2efde6b1c9db
parent080eb40a82ccb19f3215055b3d103b949660f6c5 (diff)
downloadaur-6787fe13637d653f1764a7d322edcb29c29f9676.tar.gz
Fixes & improvements ...
- Add patch to build with reveal.js - Restore hardcoded Fira fonts
-rw-r--r--.SRCINFO15
-rw-r--r--0001-Use-system-font.patch34
-rw-r--r--2-rm-reveal-check.patch13
-rw-r--r--PKGBUILD37
-rw-r--r--embed-reveal.patch11
5 files changed, 33 insertions, 77 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 42dd16d5b862..da2fde3cdaef 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,11 +1,10 @@
pkgbase = apostrophe-git
pkgdesc = A distraction free Markdown editor for GNU/Linux made with GTK+
- pkgver = 2.6.3.r327.g5666e17
+ pkgver = 3.0.r0.gdff1c5e
pkgrel = 1
url = https://world.pages.gitlab.gnome.org/apostrophe
arch = any
license = GPL-3.0-or-later
- checkdepends = appstream
makedepends = git
makedepends = gobject-introspection
makedepends = meson
@@ -20,18 +19,18 @@ pkgbase = apostrophe-git
depends = python-pypandoc
depends = python-regex
depends = python-setuptools
+ depends = ttf-fira-mono
+ depends = ttf-fira-sans
depends = webkitgtk-6.0
optdepends = mathjax: for formula preview
optdepends = texlive-bin: for the pdftex module
- optdepends = ttf-fira-mono: recommended Mono font
- optdepends = ttf-fira-sans: recommended Sans font
provides = apostrophe
conflicts = apostrophe
source = git+https://gitlab.gnome.org/World/apostrophe.git
- source = 0001-Use-system-font.patch
- source = 2-rm-reveal-check.patch
+ source = https://github.com/hakimel/reveal.js/archive/5.1.0/reveal.js-5.1.0.tar.gz
+ source = embed-reveal.patch
sha256sums = SKIP
- sha256sums = e909c05f259a874afd5e414fd13b0f162972e59c61c23e6d619e502254fcd4fe
- sha256sums = a3e2eea5fca084f53fd6d0f9e61ace8e14b4c83d9c2f1d5ea74c8589c8c10b8f
+ sha256sums = ddc83539ec50583eac9a972e88f892971b37c44e70dd0c08be069e2688684b71
+ sha256sums = d9f140a58a2f65395450a4907263b8c925d6186f90c59e37cc378141be695f5c
pkgname = apostrophe-git
diff --git a/0001-Use-system-font.patch b/0001-Use-system-font.patch
deleted file mode 100644
index d8ffdd50f708..000000000000
--- a/0001-Use-system-font.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From 2bda071943a224ac424b1c46828acd35ee04f3e7 Mon Sep 17 00:00:00 2001
-From: Kimiblock <pn3535@icloud.com>
-Date: Tue, 29 Aug 2023 20:38:16 +0800
-Subject: [PATCH] Use system font
-
----
- data/media/css/gtk/style.css | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/data/media/css/gtk/style.css b/data/media/css/gtk/style.css
-index 9b6840d..c0357ec 100644
---- a/data/media/css/gtk/style.css
-+++ b/data/media/css/gtk/style.css
-@@ -32,7 +32,7 @@
- }
-
- .apostrophe-editor {
-- font-family: 'Fira Mono', monospace;
-+ font-family: monospace;
- font-size: 1.091em;
- /*text-decoration-color: @error_color;
- background: @base_color;
-@@ -88,7 +88,7 @@
- }
-
- .lexikon {
-- font-family: serif;
-+ font-family: sans-serif;
- font-size: 12px;
- background: @theme_selected_bg_color;
- border: 4px solid @theme_selected_bg_color;
---
-2.42.0
-
diff --git a/2-rm-reveal-check.patch b/2-rm-reveal-check.patch
deleted file mode 100644
index a040b52ebb1d..000000000000
--- a/2-rm-reveal-check.patch
+++ /dev/null
@@ -1,13 +0,0 @@
---- meson.build 2024-01-12 14:18:57.598799803 +0800
-+++ meson.build 2024-01-12 14:38:59.351937376 +0800
-@@ -60,9 +60,7 @@
- #bindir = join_paths(get_option('prefix'), get_option('bindir'))
- podir = meson.source_root() / 'po'
-
--if not fs.exists(join_paths(pkgdatadir, 'libs/reveal.js'))
-- error('No valid reveal.js installation found')
--endif
-+
-
- subdir('data')
- #subdir('help')
diff --git a/PKGBUILD b/PKGBUILD
index fb68460a3626..3a7d11ac5178 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -3,8 +3,9 @@
# Contributor: Kimiblock
# Contributor: Philip Goto <philip.goto@gmail.com>
pkgname=apostrophe-git
-pkgver=2.6.3.r327.g5666e17
+pkgver=3.0.r0.gdff1c5e
pkgrel=1
+_reveal_ver=5.1.0
pkgdesc="A distraction free Markdown editor for GNU/Linux made with GTK+"
arch=('any')
url="https://world.pages.gitlab.gnome.org/apostrophe"
@@ -21,6 +22,8 @@ depends=(
'python-pypandoc'
'python-regex'
'python-setuptools'
+ 'ttf-fira-mono'
+ 'ttf-fira-sans'
'webkitgtk-6.0'
)
makedepends=(
@@ -28,21 +31,18 @@ makedepends=(
'gobject-introspection'
'meson'
)
-checkdepends=('appstream')
optdepends=(
'mathjax: for formula preview'
'texlive-bin: for the pdftex module'
- 'ttf-fira-mono: recommended Mono font'
- 'ttf-fira-sans: recommended Sans font'
)
provides=("${pkgname%-git}")
conflicts=("${pkgname%-git}")
source=('git+https://gitlab.gnome.org/World/apostrophe.git'
- '0001-Use-system-font.patch'
- '2-rm-reveal-check.patch')
+ "https://github.com/hakimel/reveal.js/archive/${_reveal_ver}/reveal.js-${_reveal_ver}.tar.gz"
+ 'embed-reveal.patch')
sha256sums=('SKIP'
- 'e909c05f259a874afd5e414fd13b0f162972e59c61c23e6d619e502254fcd4fe'
- 'a3e2eea5fca084f53fd6d0f9e61ace8e14b4c83d9c2f1d5ea74c8589c8c10b8f')
+ 'ddc83539ec50583eac9a972e88f892971b37c44e70dd0c08be069e2688684b71'
+ 'd9f140a58a2f65395450a4907263b8c925d6186f90c59e37cc378141be695f5c')
pkgver() {
cd "${pkgname%-git}"
@@ -51,21 +51,11 @@ pkgver() {
prepare() {
cd "${pkgname%-git}"
+ mkdir -p "${pkgname%-git}/libs/reveal.js"
+ cp -r "$srcdir/reveal.js-${_reveal_ver}"/* "${pkgname%-git}/libs/reveal.js"
- # Bug 1953395 - Apostrophe can't export to HTML
- sed -i 's|/app/share/fonts/FiraSans-Regular.ttf|/usr/share/fonts/OTF/FiraSans-Regular.otf|' \
- data/media/css/web/base.css
- sed -i 's|/app/share/fonts/FiraMono-Regular.ttf|/usr/share/fonts/OTF/FiraMono-Regular.otf|' \
- data/media/css/web/base.css
-
- # W: hidden-file-or-dir
- rm apostrophe/.pylintrc
-
- # Use system monospace & sans font instead of hard dependency on Fira Mono / Fira Sans
- patch -Np1 -i "$srcdir/0001-Use-system-font.patch"
-
- ## TODO Find a way to package reveal.js
- patch "$srcdir/apostrophe/meson.build" < "$srcdir/2-rm-reveal-check.patch"
+ # Point Meson to the reveal.js files
+ patch meson.build < "$srcdir/embed-reveal.patch"
}
build() {
@@ -79,4 +69,7 @@ check() {
package() {
meson install -C build --destdir "$pkgdir"
+
+ install -d "$pkgdir/usr/share/${pkgname%-git}/libs/reveal.js"
+ cp -r "reveal.js-${_reveal_ver}"/* "$pkgdir/usr/share/${pkgname%-git}/libs/reveal.js"
}
diff --git a/embed-reveal.patch b/embed-reveal.patch
new file mode 100644
index 000000000000..ece2ef4d4c1e
--- /dev/null
+++ b/embed-reveal.patch
@@ -0,0 +1,11 @@
+--- meson.build.reveal 2024-05-02 12:06:31.019408494 +0300
++++ meson.build 2024-05-02 12:10:17.583277672 +0300
+@@ -60,7 +60,7 @@
+ #bindir = join_paths(get_option('prefix'), get_option('bindir'))
+ podir = meson.source_root() / 'po'
+
+-if not fs.exists(join_paths(pkgdatadir, 'libs/reveal.js'))
++if not fs.exists(meson.source_root() / meson.project_name() / 'libs/reveal.js')
+ error('No valid reveal.js installation found')
+ endif
+