aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorctucx <c@ctu.cx>2020-06-13 22:26:08 +0200
committerctucx <c@ctu.cx>2020-06-13 22:26:08 +0200
commitcc91219b0a45a034f35c9e510fb384a9abda0d99 (patch)
tree04a50b5737b71040db70b4895029adf83c38214a
parent82602f51c5e59a6a005736076a39e893585a93f7 (diff)
parentf4e7434c6c0552a87de74b86939b071c8204f114 (diff)
downloadgallery-cc91219b0a45a034f35c9e510fb384a9abda0d99.tar.gz
gallery-cc91219b0a45a034f35c9e510fb384a9abda0d99.tar.bz2
gallery-cc91219b0a45a034f35c9e510fb384a9abda0d99.zip
Merge branch 'master' of https://git.ctu.cx/ctucx/gallery
-rw-r--r--PKGBUILD20
-rw-r--r--README.md11
2 files changed, 31 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 0000000..937a49c
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,20 @@
+pkgname=gallery
+pkgver=0.1
+pkgrel=1
+arch=('x86_64')
+url="https://git.ctu.cx/ctucx/gallery/"
+license=('GPL-3')
+depends=('glibc' 'imagemagick')
+makedepends=( 'nim' 'nimble' )
+source=("${pkgname}-${pkgver}.tar.xz::https://git.ctu.cx/ctucx/gallery/archive/${pkgver}.tar.gz")
+sha256sums=('92b7672160000bd601e62e6608cf27151c0229d045465572d371c221443a96b4')
+
+build() {
+ cd "$srcdir/${pkgname}/"
+ nimble build -d:release -y
+}
+
+package() {
+ cd "$srcdir/${pkgname}"
+ install -Dm755 ./gallery "$pkgdir"/usr/bin/ctucx_gallery
+}
diff --git a/README.md b/README.md
index df05575..5786ad3 100644
--- a/README.md
+++ b/README.md
@@ -18,3 +18,14 @@ Dependencies: ImageMagick, nim >= 1.0.6, nimble
## infos
When running the program, a config file must be specified, then the program creates all necessary HTML and CSS objects to display the pages correctly and creates images in the following sizes: medium: 1920x1080, thumbnail: 200x200
+
+it's recommended to disable caching for the html files, here is an example config snippet for nginx:
+```
+location ~* \.html$ {
+ add_header Last-Modified $date_gmt;
+ add_header Cache-Control 'private no-store, no-cache, must-revalidate, proxy-revalidate, max-age=0';
+ if_modified_since off;
+ expires off;
+ etag off;
+}
+```