aboutsummaryrefslogtreecommitdiffstats
path: root/devel
diff options
context:
space:
mode:
authorpi <pi@FreeBSD.org>2015-02-08 18:06:54 +0800
committerpi <pi@FreeBSD.org>2015-02-08 18:06:54 +0800
commitc7420ff3865267994e41549204e3125546455b4f (patch)
tree5384639e6e2f86f54121a161f19bf38c8015ff0b /devel
parentbb62209e01670fcce7a0c3dcf3bd9e5bcdb36b30 (diff)
downloadfreebsd-ports-gnome-c7420ff3865267994e41549204e3125546455b4f.tar.gz
freebsd-ports-gnome-c7420ff3865267994e41549204e3125546455b4f.tar.zst
freebsd-ports-gnome-c7420ff3865267994e41549204e3125546455b4f.zip
New port: devel/statik
statik allows you to embed a directory of static files into your Go binary to be later served from an http.FileSystem. Is this a crazy idea? No, not necessarily. If you're building a tool that has a Web component, you typically want to serve some images, CSS and JavaScript. You like the comfort of distributing a single binary, so you don't want to mess with deploying them elsewhere. If your static files are not large in size and will be browsed by a few people, statik is a solution you are looking for. WWW: https://github.com/rakyll/statik PR: 194987 Submitted by: cheffo@freebsd-bg.org
Diffstat (limited to 'devel')
-rw-r--r--devel/Makefile1
-rw-r--r--devel/statik/Makefile24
-rw-r--r--devel/statik/distinfo2
-rw-r--r--devel/statik/pkg-descr10
-rw-r--r--devel/statik/pkg-plist1
5 files changed, 38 insertions, 0 deletions
diff --git a/devel/Makefile b/devel/Makefile
index 4fc281fec3bf..5db91c64cd1c 100644
--- a/devel/Makefile
+++ b/devel/Makefile
@@ -4749,6 +4749,7 @@
SUBDIR += srecord
SUBDIR += st
SUBDIR += statcvs
+ SUBDIR += statik
SUBDIR += statsvn
SUBDIR += stfl
SUBDIR += stlfilt
diff --git a/devel/statik/Makefile b/devel/statik/Makefile
new file mode 100644
index 000000000000..7ba2f1afd97e
--- /dev/null
+++ b/devel/statik/Makefile
@@ -0,0 +1,24 @@
+# $FreeBSD$
+
+PORTNAME= statik
+PORTVERSION= 20141209
+CATEGORIES= devel
+
+MAINTAINER= cheffo@freebsd-bg.org
+COMMENT= Embed static files into a Go executable
+
+LICENSE= APACHE20
+
+BUILD_DEPENDS= go:${PORTSDIR}/lang/go
+
+ONLY_FOR_ARCHS= i386 amd64
+
+USE_GITHUB= yes
+GH_ACCOUNT= rakyll
+GH_PROJECT= statik
+GH_TAGNAME= ${GH_COMMIT}
+GH_COMMIT= 4a16c83
+
+.include <bsd.port.pre.mk>
+.include "${PORTSDIR}/lang/go/files/bsd.go.mk"
+.include <bsd.port.post.mk>
diff --git a/devel/statik/distinfo b/devel/statik/distinfo
new file mode 100644
index 000000000000..6133f1e45b45
--- /dev/null
+++ b/devel/statik/distinfo
@@ -0,0 +1,2 @@
+SHA256 (statik-20141209.tar.gz) = 6ac4c9fa02c442e588d4d240dbf8694a6cc1375356e88808cdea0255c1001435
+SIZE (statik-20141209.tar.gz) = 77645
diff --git a/devel/statik/pkg-descr b/devel/statik/pkg-descr
new file mode 100644
index 000000000000..48671e13a25e
--- /dev/null
+++ b/devel/statik/pkg-descr
@@ -0,0 +1,10 @@
+statik allows you to embed a directory of static files into your
+Go binary to be later served from an http.FileSystem. Is this a
+crazy idea? No, not necessarily. If you're building a tool that
+has a Web component, you typically want to serve some images, CSS
+and JavaScript. You like the comfort of distributing a single binary,
+so you don't want to mess with deploying them elsewhere. If your
+static files are not large in size and will be browsed by a few
+people, statik is a solution you are looking for.
+
+WWW: https://github.com/rakyll/statik
diff --git a/devel/statik/pkg-plist b/devel/statik/pkg-plist
new file mode 100644
index 000000000000..1581740f6ac6
--- /dev/null
+++ b/devel/statik/pkg-plist
@@ -0,0 +1 @@
+bin/%%GO_PKGNAME%%