View | Details | Raw Unified | Return to bug 231632 | Differences between
and this patch

Collapse All | Expand All

(-)tuptime-new/Makefile (-7 / +5 lines)
Lines 2-8 Link Here
2
# $FreeBSD: head/sysutils/tuptime/Makefile 470610 2018-05-22 13:15:13Z mat $
2
# $FreeBSD: head/sysutils/tuptime/Makefile 470610 2018-05-22 13:15:13Z mat $
3
3
4
PORTNAME=	tuptime
4
PORTNAME=	tuptime
5
DISTVERSION=	3.3.3
5
DISTVERSION=	3.4.0
6
CATEGORIES=	sysutils
6
CATEGORIES=	sysutils
7
7
8
MAINTAINER=	jeremy@smart-serv.net
8
MAINTAINER=	jeremy@smart-serv.net
Lines 18-34 Link Here
18
NO_BUILD=	yes
18
NO_BUILD=	yes
19
NO_ARCH=	yes
19
NO_ARCH=	yes
20
USE_RC_SUBR=	${PORTNAME}
20
USE_RC_SUBR=	${PORTNAME}
21
SHEBANG_FILES=	${WRKSRC}/src/tuptime ${WRKSRC}/scripts/*
21
SHEBANG_FILES=	${WRKSRC}/src/tuptime
22
MANPAGES=	tuptime.1
22
SUB_FILES=	pkg-message
23
SUB_FILES=	pkg-message
23
24
24
PLIST_FILES=	bin/tuptime \
25
PLIST_FILES=	bin/tuptime \
25
		${EXAMPLESDIR}/db-tuptime-migrate.sh \
26
		man/man1/tuptime.1.gz
26
		${EXAMPLESDIR}/db-tuptime-migrate-3.0-to-3.1.sh
27
27
28
do-install:
28
do-install:
29
	@${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
30
	${INSTALL_SCRIPT} ${WRKSRC}/src/tuptime ${STAGEDIR}${PREFIX}/bin/tuptime
29
	${INSTALL_SCRIPT} ${WRKSRC}/src/tuptime ${STAGEDIR}${PREFIX}/bin/tuptime
31
	${INSTALL_SCRIPT} ${WRKSRC}/scripts/db-tuptime-migrate.sh ${STAGEDIR}${EXAMPLESDIR}/db-tuptime-migrate.sh
30
	${INSTALL_MAN} ${WRKSRC}/src/man/tuptime.1 ${STAGEDIR}${MANPREFIX}/man/man1
32
	${INSTALL_SCRIPT} ${WRKSRC}/scripts/db-tuptime-migrate-3.0-to-3.1.sh ${STAGEDIR}${EXAMPLESDIR}/db-tuptime-migrate-3.0-to-3.1.sh
33
31
34
.include <bsd.port.mk>
32
.include <bsd.port.mk>
(-)tuptime-new/distinfo (-3 / +3 lines)
Lines 1-3 Link Here
1
TIMESTAMP = 1519352885
1
TIMESTAMP = 1537724492
2
SHA256 (rfrail3-tuptime-3.3.3_GH0.tar.gz) = be4dc5207859eeb0e6cfef206db5dd62b553e69ac0641c7203278cdd61c95bea
2
SHA256 (rfrail3-tuptime-3.4.0_GH0.tar.gz) = 9f917daed6d3a6f592072a3165d99c7b41fc4e8ed6e2e4fbc4ab670fb0c1c82b
3
SIZE (rfrail3-tuptime-3.3.3_GH0.tar.gz) = 35348
3
SIZE (rfrail3-tuptime-3.4.0_GH0.tar.gz) = 43003
(-)tuptime-new/files/pkg-message.in (-5 lines)
Lines 4-12 Link Here
4
4
5
	*/5 * * * * root %%PREFIX%%/bin/tuptime -x > /dev/null
5
	*/5 * * * * root %%PREFIX%%/bin/tuptime -x > /dev/null
6
6
7
If you are upgrading from an older version you need to run the following scripts:
8
9
	%%EXAMPLESDIR%%/db-tuptime-migrate.sh
10
	%%EXAMPLESDIR%%/db-tuptime-migrate-3.0-to-3.1.sh
11
12
======================================================================
7
======================================================================
(-)tuptime-new/files/tuptime.in (-8 / +14 lines)
Lines 1-32 Link Here
1
#!/bin/sh
1
#!/bin/sh
2
#
2
#
3
# $FreeBSD: head/sysutils/tuptime/files/tuptime.in 400493 2015-10-30 08:35:56Z danfe $
4
#
5
# PROVIDE: tuptime
3
# PROVIDE: tuptime
4
# REQUIRE: DAEMON
6
# KEYWORD: nojail shutdown
5
# KEYWORD: nojail shutdown
7
6
8
. /etc/rc.subr
7
. /etc/rc.subr
9
8
10
name="tuptime"
9
name="tuptime"
11
rcvar=tuptime_enable
10
rcvar=tuptime_enable
12
11
tuptime_user="tuptime"
13
command="%%PREFIX%%/bin/tuptime"
14
12
15
start_cmd="${name}_start"
13
start_cmd="${name}_start"
16
stop_cmd="${name}_stop"
14
stop_cmd="${name}_stop"
17
15
16
export PATH=$PATH:/usr/local/bin/
17
18
tuptime_start()
18
tuptime_start()
19
{
19
{
20
	command_args="-x"
20
	command_args="-x"
21
21
	if /usr/sbin/pw usershow "${tuptime_user}" >/dev/null 2>&1; then
22
	$command $command_args
22
		su -m ${tuptime_user} -c "$name $command_args"
23
	else
24
		$name $command_args
25
	fi
23
}
26
}
24
27
25
tuptime_stop()
28
tuptime_stop()
26
{
29
{
27
	command_args="-xg"
30
	command_args="-xg"
28
31
	if /usr/sbin/pw usershow "${tuptime_user}" >/dev/null 2>&1; then
29
	$command $command_args
32
		su -m ${tuptime_user} -c "$name $command_args"
33
	else
34
		$name $command_args
35
	fi
30
}
36
}
31
37
32
load_rc_config $name
38
load_rc_config $name

Return to bug 231632