diff options
-rw-r--r-- | .SRCINFO | 23 | ||||
-rw-r--r-- | 0001-Don-t-require-pry-by-default.patch | 25 | ||||
-rw-r--r-- | PKGBUILD | 42 | ||||
-rwxr-xr-x | devdocs-cli.sh | 4 | ||||
-rwxr-xr-x | devdocs-server.sh | 4 | ||||
-rw-r--r-- | devdocs.service | 4 | ||||
-rw-r--r-- | devdocsgjs-git.install | 12 |
7 files changed, 85 insertions, 29 deletions
@@ -1,8 +1,9 @@ -pkgbase = devdocs-git - pkgdesc = API Documentation Browser - pkgver = r1033.ddf87bb - pkgrel = 2 - url = http://devdocs.io +pkgbase = devdocsgjs-git + pkgdesc = API Documentation Browser (with GJS/GIR support) + pkgver = r2928.ac8ae363 + pkgrel = 1 + url = https://gitlab.gnome.org/GNOME/devdocsgjs + install = devdocsgjs-git.install arch = any license = MPL makedepends = git @@ -12,14 +13,16 @@ pkgbase = devdocs-git depends = nodejs depends = coffee-script provides = devdocs-git - source = devdocs-git::git+https://github.com/Thibaut/devdocs + source = devdocsgjs-git::git+https://gitlab.gnome.org/GNOME/devdocsgjs.git#branch=gnome source = devdocs-server.sh source = devdocs-cli.sh source = devdocs.service + source = 0001-Don-t-require-pry-by-default.patch md5sums = SKIP - md5sums = SKIP - md5sums = SKIP - md5sums = SKIP + md5sums = 6f2d514aa412c9b4d0165d35aaa48544 + md5sums = d4a2ceec03f265cc60f3091b30eced5c + md5sums = 2ef3b5bc9519e6929355d49063c1132c + md5sums = ef9bece544b2f2e713e54479257d4c82 -pkgname = devdocs-git +pkgname = devdocsgjs-git diff --git a/0001-Don-t-require-pry-by-default.patch b/0001-Don-t-require-pry-by-default.patch new file mode 100644 index 000000000000..5596d988413a --- /dev/null +++ b/0001-Don-t-require-pry-by-default.patch @@ -0,0 +1,25 @@ +From dd2eb7368ac121c900f597608bab079ee3c82bd6 Mon Sep 17 00:00:00 2001 +From: Senya <senya@riseup.net> +Date: Thu, 10 Sep 2020 10:13:01 +0300 +Subject: [PATCH] Don't require pry by default + +--- + Gemfile | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/Gemfile b/Gemfile +index 61004330..c821c80e 100644 +--- a/Gemfile ++++ b/Gemfile +@@ -3,7 +3,7 @@ ruby '~> 2.6.0' + + gem 'rake' + gem 'thor' +-gem 'pry', '~> 0.12.0' ++gem 'pry', '~> 0.12.0', require: false + gem 'activesupport', '~> 5.2', require: false + gem 'yajl-ruby', require: false + gem 'html-pipeline' +-- +2.28.0 + @@ -1,16 +1,32 @@ -# Maintainer: Jonian Guveli <https://github.com/jonian/> -pkgname=devdocs-git -pkgver=r1033.ddf87bb -pkgrel=2 -pkgdesc="API Documentation Browser" +# Maintainer: Senya <senya@riseup.net> +# Contributor: Jonian Guveli <https://github.com/jonian/> +pkgname=devdocsgjs-git +pkgver=r2928.ac8ae363 +pkgrel=1 +pkgdesc="API Documentation Browser (with GJS/GIR support)" arch=("any") -url="http://devdocs.io" +url="https://gitlab.gnome.org/GNOME/devdocsgjs" license=("MPL") depends=("ruby" "ruby-bundler" "curl" "nodejs" "coffee-script") makedepends=("git") provides=("devdocs-git") -source=("$pkgname::git+https://github.com/Thibaut/devdocs" "devdocs-server.sh" "devdocs-cli.sh" "devdocs.service") -md5sums=("SKIP" "SKIP" "SKIP" "SKIP") +source=("$pkgname::git+https://gitlab.gnome.org/GNOME/devdocsgjs.git#branch=gnome" + "devdocs-server.sh" + "devdocs-cli.sh" + "devdocs.service" + "0001-Don-t-require-pry-by-default.patch") +md5sums=('SKIP' + '6f2d514aa412c9b4d0165d35aaa48544' + 'd4a2ceec03f265cc60f3091b30eced5c' + '2ef3b5bc9519e6929355d49063c1132c' + 'ef9bece544b2f2e713e54479257d4c82') + +install=devdocsgjs-git.install + +prepare() { + cd "$srcdir/$pkgname" + patch -p1 --forward --strip=1 --input="${srcdir}/0001-Don-t-require-pry-by-default.patch" +} pkgver() { cd "$srcdir/$pkgname" @@ -30,10 +46,10 @@ package() { cp "$srcdir/devdocs-server.sh" "$pkgdir/opt/$pkgname/devdocs-server.sh" cp "$srcdir/devdocs-cli.sh" "$pkgdir/opt/$pkgname/devdocs-cli.sh" - cp "$srcdir/devdocs.service" "$pkgdir/usr/lib/systemd/system/devdocs.service" + cp "$srcdir/devdocs.service" "$pkgdir/usr/lib/systemd/system/devdocsgjs.service" - ln -s "/opt/$pkgname/devdocs-server.sh" "$pkgdir/usr/bin/devdocs-server" - ln -s "/opt/$pkgname/devdocs-cli.sh" "$pkgdir/usr/bin/devdocs-cli" + ln -s "/opt/$pkgname/devdocs-server.sh" "$pkgdir/usr/bin/devdocsgjs-server" + ln -s "/opt/$pkgname/devdocs-cli.sh" "$pkgdir/usr/bin/devdocsgjs-cli" mkdir -p "$pkgdir/opt/$pkgname/tmp" @@ -43,6 +59,6 @@ package() { chmod -R g+w "$pkgdir/opt/$pkgname/public" chmod -R g+w "$pkgdir/opt/$pkgname/tmp" - cd "$pkgdir/opt/$pkgname" && bundle install --path .bundle - cd "$pkgdir/opt/$pkgname" && bundle exec thor assets:clean && bundle exec thor assets:compile + env -iC "$pkgdir/opt/$pkgname" sh -lc "bundle install --path .bundle" + env -iC "$pkgdir/opt/$pkgname" sh -lc "bundle exec thor assets:clean && bundle exec thor assets:compile" } diff --git a/devdocs-cli.sh b/devdocs-cli.sh index 3974ca897799..5aabee43e88e 100755 --- a/devdocs-cli.sh +++ b/devdocs-cli.sh @@ -1,3 +1,3 @@ -#!/bin/bash -cd /opt/devdocs-git && bundle exec thor "$@" +#!/usr/bin/env -iS bash --login +cd /opt/devdocsgjs-git && bundle exec thor "$@" diff --git a/devdocs-server.sh b/devdocs-server.sh index 2834825224bb..f9ce94962abc 100755 --- a/devdocs-server.sh +++ b/devdocs-server.sh @@ -1,3 +1,3 @@ -#!/bin/bash -cd /opt/devdocs-git && bundle exec rackup "$@" +#!/usr/bin/env -iS bash --login +cd /opt/devdocsgjs-git && bundle exec rackup "$@" diff --git a/devdocs.service b/devdocs.service index 3c1263e7697e..65ae3c516b49 100644 --- a/devdocs.service +++ b/devdocs.service @@ -1,9 +1,9 @@ [Unit] -Description=DevDocs +Description=DevDocs GJS After=network.target [Service] -ExecStart=/usr/bin/devdocs-server +ExecStart=/usr/bin/devdocsgjs-server ExecReload=/bin/kill -HUP $MAINPID [Install] diff --git a/devdocsgjs-git.install b/devdocsgjs-git.install new file mode 100644 index 000000000000..3156feb46d1e --- /dev/null +++ b/devdocsgjs-git.install @@ -0,0 +1,12 @@ +post_install() { + echo "Running gir:generate_all ..." + devdocsgjs-cli gir:generate_all + echo "Finished running gir:generate_all" +} + +pre_remove() { + rm -rf /opt/devdocsgjs-git/tmp + rm -rf /opt/devdocsgjs-git/public/docs + rm -rf /opt/devdocsgjs-git/lib/docs/scrapers/gnome/generated + rm -rf /opt/devdocsgjs-git/docs +} |