aboutsummaryrefslogtreecommitdiff
path: root/build-aux
diff options
context:
space:
mode:
authorArun Isaac2022-01-05 17:22:58 +0530
committerArun Isaac2022-01-05 17:22:58 +0530
commitdeed349d37a1f825086af6fe1e69d2f9882d12e3 (patch)
tree299a7d8c1a4f2a1b62de35f346d6192b33d4bbc4 /build-aux
parent7eee5d0760d7a770ec93e01ebb4d0006538fab9e (diff)
downloadkolam-deed349d37a1f825086af6fe1e69d2f9882d12e3.tar.gz
kolam-deed349d37a1f825086af6fe1e69d2f9882d12e3.tar.lz
kolam-deed349d37a1f825086af6fe1e69d2f9882d12e3.zip
README: Add releases.
* README.org (Download): Add releases. * build-aux/build-home-page.el (org-dblock-write:releases): New function. (build-website): Update dynamic blocks before exporting.
Diffstat (limited to 'build-aux')
-rw-r--r--build-aux/build-home-page.el14
1 files changed, 14 insertions, 0 deletions
diff --git a/build-aux/build-home-page.el b/build-aux/build-home-page.el
index ac55bf9..e005756 100644
--- a/build-aux/build-home-page.el
+++ b/build-aux/build-home-page.el
@@ -35,6 +35,20 @@
org-html-head-include-scripts nil
org-html-postamble nil)
+(defun org-dblock-write:releases (params)
+ "Dynamically write releases block."
+ (call-process "git" nil t nil
+ "for-each-ref" "--sort=-taggerdate"
+ (let ((release-file "./releases/kolam-%(refname:short).tar.lz"))
+ (format "--format=- %%(taggerdate:short) [[%s][%s]] [[%s.asc][GPG Signature]]"
+ release-file
+ (file-name-nondirectory release-file)
+ release-file))
+ "refs/tags/v*")
+ ;; Fix tarball filenames.
+ (replace-string "kolam-v" "kolam-" nil nil nil t))
+
(defun build-website ()
(with-current-buffer (find-file "README.org")
+ (org-update-all-dblocks)
(org-export-to-file 'html "website/index.html")))