[gimp-web-devel/hugo] tool for updating API docs
- From: Jehan <jehanp src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp-web-devel/hugo] tool for updating API docs
- Date: Thu, 4 Aug 2022 14:30:30 +0000 (UTC)
commit 1e420fedf6a78c5aa7982c3cf0838c8a8bb8da44
Author: robin-swift <robinswiftart gmail com>
Date: Wed Jul 27 16:26:51 2022 +0100
tool for updating API docs
scripts/make_api_docs.sh | 25 -------------------------
scripts/update_api_docs.sh | 29 +++++++++++++++++++++++++++++
2 files changed, 29 insertions(+), 25 deletions(-)
---
diff --git a/scripts/update_api_docs.sh b/scripts/update_api_docs.sh
new file mode 100644
index 0000000..c448d78
--- /dev/null
+++ b/scripts/update_api_docs.sh
@@ -0,0 +1,29 @@
+#!/bin/bash
+
+function get_api_docs () {
+DOWNLOAD_URL="https://download.gimp.org/pub/gimp/v$1"
+
+echo "Looking up current revision..."
+VERSION=`wget -O - $DOWNLOAD_URL | grep "0.0_LATEST-IS" | sed "s/.*LATEST-IS-//;s|</a>.*||"`
+
+echo "Getting tarball..."
+wget $DOWNLOAD_URL/gimp-$VERSION.tar.bz2
+
+echo "Extracting..."
+tar xf gimp-$VERSION.tar.bz2
+
+echo "Installing into static/..."
+mkdir -p static/libgimp/$1
+mkdir -p static/libgimp-ui/$1
+
+mv gimp-$VERSION/devel-docs/libgimp/html/* static/libgimp/$1
+mv gimp-$VERSION/devel-docs/libgimp-ui/html/* static/libgimp-ui/$1
+
+echo "Tidying up..."
+rm -fr gimp-$VERSION gimp-$VERSION.tar.bz2
+
+echo "Done."
+}
+
+get_api_docs 2.8
+get_api_docs 2.10
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]