View | Details | Raw Unified | Return to bug 144272
Collapse All | Expand All

(-)./moreutils/Makefile (-11 / +11 lines)
Lines 7-13 Link Here
7
#
7
#
8
8
9
PORTNAME=	moreutils
9
PORTNAME=	moreutils
10
PORTVERSION=	0.38
10
PORTVERSION=	0.39
11
CATEGORIES=	sysutils
11
CATEGORIES=	sysutils
12
MASTER_SITES=	${MASTER_SITE_DEBIAN_POOL}
12
MASTER_SITES=	${MASTER_SITE_DEBIAN_POOL}
13
DISTNAME=	${PORTNAME}_${PORTVERSION}
13
DISTNAME=	${PORTNAME}_${PORTVERSION}
Lines 15-26 Link Here
15
MAINTAINER=	corky1951@comcast.net
15
MAINTAINER=	corky1951@comcast.net
16
COMMENT=	Additional Unix utilities
16
COMMENT=	Additional Unix utilities
17
17
18
.if !defined(NO_INSTALL_MANPAGES)
19
BUILD_DEPENDS=	libxslt>=0:${PORTSDIR}/textproc/libxslt \
20
	${LOCALBASE}/share/xsl/docbook/manpages/docbook.xsl:${PORTSDIR}/textproc/docbook-xsl \
21
	${LOCALBASE}/share/xml/docbook/4.4/docbookx.dtd:${PORTSDIR}/textproc/docbook-xml-440
22
.endif
23
24
USE_PERL5=	yes
18
USE_PERL5=	yes
25
19
26
PLIST_FILES=	bin/combine \
20
PLIST_FILES=	bin/combine \
Lines 59-70 Link Here
59
ALL_TARGET+=	mans extraman
53
ALL_TARGET+=	mans extraman
60
MANCOMPRESSED=	no
54
MANCOMPRESSED=	no
61
55
62
# portlint will warn about the next line, but we need it this way
56
CANNED_MAN=	ifne.1 \
63
OLD_DTD=	/usr/share/xml/docbook/schema/dtd/4.4/docbookx.dtd
57
		isutf8.1 \
64
NEW_DTD=	${LOCALBASE}/share/xml/docbook/4.4/docbookx.dtd
58
		lckdo.1 \
59
		mispipe.1 \
60
		parallel.1 \
61
		pee.1 \
62
		sponge.1
65
63
66
post-patch:
64
post-patch:
67
	${REINPLACE_CMD} -E -e 's|${OLD_DTD}|${NEW_DTD}|g' ${WRKSRC}/*.docbook
65
.for f in ${CANNED_MAN}
66
	${CP} ${FILESDIR}/${f} ${WRKSRC}
67
.endfor
68
68
69
post-install:
69
post-install:
70
.for manpage in ${MAN1}
70
.for manpage in ${MAN1}
(-)./moreutils/distinfo (-3 / +3 lines)
Lines 1-3 Link Here
1
MD5 (moreutils_0.38.tar.gz) = 34f29dc728ead3cae50411e7d158a493
1
MD5 (moreutils_0.39.tar.gz) = 73477f418ea2de81a045019cc71267f3
2
SHA256 (moreutils_0.38.tar.gz) = 26223e8ac1fe9906dcc0e2e4395d510146001fe285e9f786e80daab8acb237c3
2
SHA256 (moreutils_0.39.tar.gz) = 6c982ed4c863f385da1ec9f90665cb9000c84f59b56340ca0832fea2d4b8bb98
3
SIZE (moreutils_0.38.tar.gz) = 40426
3
SIZE (moreutils_0.39.tar.gz) = 40591
(-)./moreutils/files/ifne.1 (+44 lines)
Line 0 Link Here
1
.\" -*- coding: us-ascii -*-
2
.if \n(.g .ds T< \\FC
3
.if \n(.g .ds T> \\F[\n[.fam]]
4
.de URL
5
\\$2 \(la\\$1\(ra\\$3
6
..
7
.if \n(.g .mso www.tmac
8
.TH ifne 1 2008-05-01 "" ""
9
.SH NAME
10
ifne \- Run command if the standard input is not empty
11
.SH SYNOPSIS
12
'nh
13
.fi
14
.ad l
15
\fBifne [-n] command\fR \kx
16
.if (\nx>(\n(.l/2)) .nr x (\n(.l/5)
17
'in \n(.iu+\nxu
18
'in \n(.iu-\nxu
19
.ad b
20
'hy
21
.SH DESCRIPTION
22
\fBifne\fR runs the following command if and only if
23
the standard input is not empty.
24
.SH OPTIONS
25
.TP 
26
\*(T<\fB\-n\fR\*(T>
27
Reverse operation. Run the command if the standard input is empty.
28
29
Note that if the standard input is not empty, it is passed through ifne
30
in this case.
31
.SH EXAMPLE
32
'nh
33
.fi
34
.ad l
35
\fBfind . -name core | ifne mail -s "Core files found" root\fR \kx
36
.if (\nx>(\n(.l/2)) .nr x (\n(.l/5)
37
'in \n(.iu+\nxu
38
'in \n(.iu-\nxu
39
.ad b
40
'hy
41
.SH AUTHOR
42
Copyright 2008 by Javier Merino <cibervicho@gmail.com>
43
.PP
44
Licensed under the GNU GPL
(-)./moreutils/files/isutf8.1 (+41 lines)
Line 0 Link Here
1
.\" -*- coding: us-ascii -*-
2
.if \n(.g .ds T< \\FC
3
.if \n(.g .ds T> \\F[\n[.fam]]
4
.de URL
5
\\$2 \(la\\$1\(ra\\$3
6
..
7
.if \n(.g .mso www.tmac
8
.TH isutf8 1 2006-02-19 "" ""
9
.SH NAME
10
isutf8 \- check whether files are valid UTF-8
11
.SH SYNOPSIS
12
'nh
13
.fi
14
.ad l
15
\fBisutf8\fR \kx
16
.if (\nx>(\n(.l/2)) .nr x (\n(.l/5)
17
'in \n(.iu+\nxu
18
[\fB-hq\fR] [\fB--help\fR] [\fB--quiet\fR] [\fIfile\fR\&...]
19
'in \n(.iu-\nxu
20
.ad b
21
'hy
22
.SH DESCRIPTION
23
\fBisutf8\fR checks whether files are
24
syntactically valid UTF-8. Input is either files named on the
25
command line, or the standard input. Notices about files with
26
invalid UTF-8 are printed to standard output.
27
.SH OPTIONS
28
.TP 
29
\*(T<\fB\-h\fR\*(T>, \*(T<\fB\-\-help\fR\*(T>
30
Print out a help summary.
31
.TP 
32
\*(T<\fB\-q\fR\*(T>, \*(T<\fB\-\-quiet\fR\*(T>
33
Don't print messages telling which files are
34
invalid UTF-8, merely indicate it with the exit
35
status.
36
.SH "EXIT STATUS"
37
If the file is valid UTF-8, the exit status is zero.
38
If the file is not valid UTF-8, or there is some
39
error, the exit status is non-zero.
40
.SH "SEE ALSO"
41
\fButf8\fR(7)
(-)./moreutils/files/lckdo.1 (+66 lines)
Line 0 Link Here
1
.\" -*- coding: us-ascii -*-
2
.if \n(.g .ds T< \\FC
3
.if \n(.g .ds T> \\F[\n[.fam]]
4
.de URL
5
\\$2 \(la\\$1\(ra\\$3
6
..
7
.if \n(.g .mso www.tmac
8
.TH lckdo 1 2007-08-15 "" ""
9
.SH NAME
10
lckdo \- run a program with a lock held
11
.SH SYNOPSIS
12
'nh
13
.fi
14
.ad l
15
\fBlckdo\fR \kx
16
.if (\nx>(\n(.l/2)) .nr x (\n(.l/5)
17
'in \n(.iu+\nxu
18
[options] {lockfile} {program} [arguments]
19
'in \n(.iu-\nxu
20
.ad b
21
'hy
22
.SH DESCRIPTION
23
\fBlckdo\fR runs a program with a lock
24
held, in order to prevent multiple processes from running in
25
parallel. Use just like \fBnice\fR or
26
\fBnohup\fR.
27
.SH OPTIONS
28
.TP 
29
\*(T<\fB\-w\fR\*(T>
30
If the lock is already held by another process,
31
wait for it to complete instead of failing
32
immediately.
33
.TP 
34
\*(T<\fB\-W {sec}\fR\*(T>
35
The same as -w but wait not more than sec
36
seconds.
37
.TP 
38
\*(T<\fB\-e\fR\*(T>
39
Execute the program directly without forking and
40
waiting (keeps an extra file descriptor open).
41
.TP 
42
\*(T<\fB\-E {nnn}\fR\*(T>
43
Set the file descriptor number to keep open when
44
exec()ing (implies -e).
45
.TP 
46
\*(T<\fB\-n\fR\*(T>
47
Do not create the lock file if it does not
48
exist.
49
.TP 
50
\*(T<\fB\-q\fR\*(T>
51
Produce no output if lock is already held.
52
.TP 
53
\*(T<\fB\-s\fR\*(T>
54
Lock in shared (read) mode.
55
.TP 
56
\*(T<\fB\-x\fR\*(T>
57
Lock in exclusive (write) mode (default).
58
.TP 
59
\*(T<\fB\-t\fR\*(T>
60
Test for lock existence.
61
.SH "EXIT STATUS"
62
If the lock was successfully acquired, the return value is that
63
of the program invoked by \fBlckdo\fR. If the lock
64
couldn't be acquired, EX_TEMPFAIL is returned. If there was a problem
65
opening/creating or locking the lock file, EX_CANTCREAT or EX_OSERR
66
will be returned.
(-)./moreutils/files/mispipe.1 (+35 lines)
Line 0 Link Here
1
.\" -*- coding: us-ascii -*-
2
.if \n(.g .ds T< \\FC
3
.if \n(.g .ds T> \\F[\n[.fam]]
4
.de URL
5
\\$2 \(la\\$1\(ra\\$3
6
..
7
.if \n(.g .mso www.tmac
8
.TH mispipe 1 2006-09-07 "" ""
9
.SH NAME
10
mispipe \- pipe two commands, returning the exit status of the first
11
.SH SYNOPSIS
12
'nh
13
.fi
14
.ad l
15
\fBmispipe\fR \kx
16
.if (\nx>(\n(.l/2)) .nr x (\n(.l/5)
17
'in \n(.iu+\nxu
18
[\fI"command1"\fR] [\fI"command2"\fR]
19
'in \n(.iu-\nxu
20
.ad b
21
'hy
22
.SH DESCRIPTION
23
\fBmispipe\fR pipes two commands
24
together like the shell does, but unlike piping in the
25
shell, the exit status of the first command is returned.
26
.PP
27
Note that some shells, notably \fBbash\fR,
28
do offer a pipefail option, however, that option does not
29
behave the same since it makes a failure of any command in
30
the pipeline be returned, not just the exit status of the
31
first.
32
.SH "EXIT STATUS"
33
The exit status of the first command. If the process
34
terminated abnormally (due to a signal), 128 will be added
35
to its exit status.
(-)./moreutils/files/parallel.1 (+105 lines)
Line 0 Link Here
1
.\" -*- coding: us-ascii -*-
2
.if \n(.g .ds T< \\FC
3
.if \n(.g .ds T> \\F[\n[.fam]]
4
.de URL
5
\\$2 \(la\\$1\(ra\\$3
6
..
7
.if \n(.g .mso www.tmac
8
.TH parallel 1 2009-07-02 "" ""
9
.SH NAME
10
parallel \- run programs in parallel
11
.SH SYNOPSIS
12
'nh
13
.fi
14
.ad l
15
\fBparallel\fR \kx
16
.if (\nx>(\n(.l/2)) .nr x (\n(.l/5)
17
'in \n(.iu+\nxu
18
[options] [command] \fB--\fR [argument ...]
19
'in \n(.iu-\nxu
20
.ad b
21
'hy
22
'nh
23
.fi
24
.ad l
25
\fBparallel\fR \kx
26
.if (\nx>(\n(.l/2)) .nr x (\n(.l/5)
27
'in \n(.iu+\nxu
28
[options] \fB--\fR [command ...]
29
'in \n(.iu-\nxu
30
.ad b
31
'hy
32
.SH DESCRIPTION
33
\fBparallel\fR runs the specified command,
34
passing it a single one of the specified arguments. This is
35
repeated for each argument. Jobs may be run in
36
parallel. The default is to run one job per CPU.
37
.PP
38
If no command is specified before the --,
39
the commands after it are instead run in parallel.
40
.SH OPTIONS
41
.TP 
42
\*(T<\fB\-j maxjobs\fR\*(T>
43
Use to limit the number of jobs
44
that are run at the same time.
45
.TP 
46
\*(T<\fB\-l maxload\fR\*(T>
47
Avoid starting new jobs when
48
the system's load average is not below
49
the specified limit.
50
.TP 
51
\*(T<\fB\-i\fR\*(T>
52
Normally the command is passed the
53
argument at the end of its command line. With
54
this option, the first instance of "{}" in
55
the command is replaced with the argument.
56
.TP 
57
\*(T<\fB\-n\fR\*(T>
58
Number of arguments to pass to a
59
command at a time. Default is 1.
60
Incompatible with -i
61
.SH EXAMPLE
62
'nh
63
.fi
64
.ad l
65
\fBparallel sh -c "echo hi; sleep 2; echo bye" -- 1 2 3\fR \kx
66
.if (\nx>(\n(.l/2)) .nr x (\n(.l/5)
67
'in \n(.iu+\nxu
68
'in \n(.iu-\nxu
69
.ad b
70
'hy
71
.PP
72
This runs three subshells that each print a message, delay,
73
and print another message. If your system has multiple
74
CPUs, parallel will run some of the jobs in parallel,
75
which should be clear from the order the messages are
76
output.
77
.PP
78
'nh
79
.fi
80
.ad l
81
\fBparallel -j 3 ufraw -o processed -- *.NEF\fR \kx
82
.if (\nx>(\n(.l/2)) .nr x (\n(.l/5)
83
'in \n(.iu+\nxu
84
'in \n(.iu-\nxu
85
.ad b
86
'hy
87
.PP
88
This runs three ufraw processes at the same time until
89
all of the NEF files have been processed.
90
.PP
91
'nh
92
.fi
93
.ad l
94
\fBparallel -j 3 -- ls df "echo hi"\fR \kx
95
.if (\nx>(\n(.l/2)) .nr x (\n(.l/5)
96
'in \n(.iu+\nxu
97
'in \n(.iu-\nxu
98
.ad b
99
'hy
100
.PP
101
This runs three independent commands in parallel.
102
.SH "EXIT STATUS"
103
Its exit status is the combination of the exit statuses of each
104
command ran, ORed together. (Thus, if any one command
105
exits nonzero, \fBparallel\fR as a whole will exit nonzero.)
(-)./moreutils/files/pee.1 (+32 lines)
Line 0 Link Here
1
.\" -*- coding: us-ascii -*-
2
.if \n(.g .ds T< \\FC
3
.if \n(.g .ds T> \\F[\n[.fam]]
4
.de URL
5
\\$2 \(la\\$1\(ra\\$3
6
..
7
.if \n(.g .mso www.tmac
8
.TH pee 1 2006-03-14 "" ""
9
.SH NAME
10
pee \- tee standard input to pipes
11
.SH SYNOPSIS
12
'nh
13
.fi
14
.ad l
15
\fBpee\fR \kx
16
.if (\nx>(\n(.l/2)) .nr x (\n(.l/5)
17
'in \n(.iu+\nxu
18
[\fI"command"\fR\&...]
19
'in \n(.iu-\nxu
20
.ad b
21
'hy
22
.SH DESCRIPTION
23
\fBpee\fR is like \fBtee\fR
24
but for pipes. Each command is run and fed a copy of the
25
standard input. The output of all commands is sent to
26
stdout.
27
.PP
28
Note that while this is similar to
29
\fBtee\fR, a copy of the input is not sent
30
to stdout, like tee does.
31
.SH "SEE ALSO"
32
\fBtee\fR(1)
(-)./moreutils/files/sponge.1 (+30 lines)
Line 0 Link Here
1
.\" -*- coding: us-ascii -*-
2
.if \n(.g .ds T< \\FC
3
.if \n(.g .ds T> \\F[\n[.fam]]
4
.de URL
5
\\$2 \(la\\$1\(ra\\$3
6
..
7
.if \n(.g .mso www.tmac
8
.TH sponge 1 2006-02-19 "" ""
9
.SH NAME
10
sponge \- soak up standard input and write to a file
11
.SH SYNOPSIS
12
'nh
13
.fi
14
.ad l
15
\fBsed '...' file | grep '...' | sponge file\fR \kx
16
.if (\nx>(\n(.l/2)) .nr x (\n(.l/5)
17
'in \n(.iu+\nxu
18
'in \n(.iu-\nxu
19
.ad b
20
'hy
21
.SH DESCRIPTION
22
\fBsponge\fR reads standard input and
23
writes it out to the specified file. Unlike a shell
24
redirect, sponge soaks up all its input before
25
opening the output file. This allows constricting
26
pipelines that read from and write to
27
the same file. 
28
.PP
29
If no output file is specified, sponge outputs to
30
stdout.

Return to bug 144272