Index: head/net/syncthing/Makefile =================================================================== --- head/net/syncthing/Makefile (revision 383385) +++ head/net/syncthing/Makefile (revision 383386) @@ -1,44 +1,45 @@ # Created by: Steve Wills # $FreeBSD$ PORTNAME= syncthing PORTVERSION= 0.10.30 +PORTREVISION= 1 CATEGORIES= net DISTVERSIONPREFIX= v MAINTAINER= swills@FreeBSD.org COMMENT= Encrypted file sync tool BUILD_DEPENDS= ${LOCALBASE}/bin/go:${PORTSDIR}/lang/go USE_GITHUB= yes USE_RC_SUBR= syncthing PLIST_FILES= bin/syncthing PORTDOCS= * USERS= syncthing GROUPS= syncthing STRIP= # stripping can break go binaries post-patch: @cd ${WRKSRC} ; ${MKDIR} src/github.com/${PORTNAME}/${PORTNAME} ; \ ${MV} AUTHORS CONTRIBUTING.md Godeps LICENSE README.md \ build.go build.sh check-contrib.sh assets cmd gui internal \ protocol test src/github.com/${PORTNAME}/${PORTNAME} do-build: # timestamp here refers to source, not build time cd ${WRKSRC}/src/github.com/${PORTNAME}/${PORTNAME} ; \ ${SETENV} GOPATH=${WRKSRC} go run build.go -no-upgrade=true -version v${PORTVERSION} do-install: ${INSTALL_PROGRAM} ${WRKSRC}/src/github.com/${PORTNAME}/${PORTNAME}/bin/syncthing \ ${STAGEDIR}${PREFIX}/bin/ ${MKDIR} ${STAGEDIR}${DOCSDIR} .for x in AUTHORS CONTRIBUTING.md LICENSE README.md ${INSTALL_MAN} ${WRKSRC}/src/github.com/${PORTNAME}/${PORTNAME}/${x} \ ${STAGEDIR}${DOCSDIR} .endfor .include Index: head/net/syncthing/files/syncthing.in =================================================================== --- head/net/syncthing/files/syncthing.in (revision 383385) +++ head/net/syncthing/files/syncthing.in (revision 383386) @@ -1,52 +1,52 @@ #!/bin/sh # $FreeBSD$ # # PROVIDE: syncthing # REQUIRE: LOGIN # KEYWORD: shutdown # # Add the following lines to /etc/rc.conf.local or /etc/rc.conf # to enable this service: # # syncthing_enable (bool): Set to NO by default. # Set it to YES to enable syncthing. # syncthing_user (user): Set user to run syncthing. # Default is "syncthing". # syncthing_group (group): Set group to run syncthing. # Default is "syncthing". # syncthing_dir (dir): Set dir to run syncthing in. -# Default is "/var/tmp/syncthing". +# Default is "/var/db/syncthing". . /etc/rc.subr name=syncthing rcvar=syncthing_enable load_rc_config $name : ${syncthing_enable:="NO"} : ${syncthing_user:="syncthing"} : ${syncthing_group:="syncthing"} : ${syncthing_dir:="/var/db/syncthing"} pidfile=/var/run/syncthing.pid procname="%%PREFIX%%/bin/syncthing" command="/usr/sbin/daemon" command_args="-f -p ${pidfile} ${procname} -home=${syncthing_dir} -no-browser ${syncthing_args}" start_precmd=syncthing_startprecmd syncthing_startprecmd() { if [ ! -e ${pidfile} ]; then install -o ${syncthing_user} -g ${syncthing_group} /dev/null ${pidfile}; fi if [ ! -d ${syncthing_dir} ]; then install -d -o ${syncthing_user} -g ${syncthing_group} ${syncthing_dir} fi } run_rc_command "$1"