test.1 (247274) | test.1 (251208) |
---|---|
1.\"- 2.\" Copyright (c) 1991, 1993 3.\" The Regents of the University of California. All rights reserved. 4.\" 5.\" This code is derived from software contributed to Berkeley by 6.\" the Institute of Electrical and Electronics Engineers, Inc. 7.\" 8.\" Redistribution and use in source and binary forms, with or without --- 16 unchanged lines hidden (view full) --- 25.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 26.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 27.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 28.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 29.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 30.\" SUCH DAMAGE. 31.\" 32.\" @(#)test.1 8.1 (Berkeley) 5/31/93 | 1.\"- 2.\" Copyright (c) 1991, 1993 3.\" The Regents of the University of California. All rights reserved. 4.\" 5.\" This code is derived from software contributed to Berkeley by 6.\" the Institute of Electrical and Electronics Engineers, Inc. 7.\" 8.\" Redistribution and use in source and binary forms, with or without --- 16 unchanged lines hidden (view full) --- 25.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 26.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 27.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 28.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 29.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 30.\" SUCH DAMAGE. 31.\" 32.\" @(#)test.1 8.1 (Berkeley) 5/31/93 |
33.\" $FreeBSD: head/bin/test/test.1 247274 2013-02-25 19:05:40Z peterj $ | 33.\" $FreeBSD: head/bin/test/test.1 251208 2013-05-31 22:54:20Z jilles $ |
34.\" 35.Dd December 27, 2012 36.Dt TEST 1 37.Os 38.Sh NAME 39.Nm test , 40.Nm \&[ 41.Nd condition evaluation utility --- 122 unchanged lines hidden (view full) --- 164True if 165.Ar file 166exists and its group matches the effective group id of this process. 167.It Fl S Ar file 168True if 169.Ar file 170exists and is a socket. 171.It Ar file1 Fl nt Ar file2 | 34.\" 35.Dd December 27, 2012 36.Dt TEST 1 37.Os 38.Sh NAME 39.Nm test , 40.Nm \&[ 41.Nd condition evaluation utility --- 122 unchanged lines hidden (view full) --- 164True if 165.Ar file 166exists and its group matches the effective group id of this process. 167.It Fl S Ar file 168True if 169.Ar file 170exists and is a socket. 171.It Ar file1 Fl nt Ar file2 |
172True if both | 172True if |
173.Ar file1 | 173.Ar file1 |
174and 175.Ar file2 176exist and 177.Ar file1 178is newer than | 174exists and is newer than |
179.Ar file2 . | 175.Ar file2 . |
180.It Ar file1 Fl nt Ns Ar X Ns Ar Y Ar file2 181True if both 182.Ar file1 183and 184.Ar file2 185exist and 186.Ar file1 187has a more recent last access time 188.Pq Ar X Ns = Ns Cm a , 189inode creation time 190.Pq Ar X Ns = Ns Cm b , 191change time 192.Pq Ar X Ns = Ns Cm c , 193or modification time 194.Pq Ar X Ns = Ns Cm m 195than the last access time 196.Pq Ar Y Ns = Ns Cm a , 197inode creation time 198.Pq Ar Y Ns = Ns Cm b , 199change time 200.Pq Ar Y Ns = Ns Cm c , 201or modification time 202.Pq Ar Y Ns = Ns Cm m 203of 204.Ar file2 . 205Note that 206.Ic -ntmm 207is equivalent to 208.Ic -nt . | |
209.It Ar file1 Fl ot Ar file2 | 176.It Ar file1 Fl ot Ar file2 |
210True if both | 177True if |
211.Ar file1 | 178.Ar file1 |
212and 213.Ar file2 214exist and 215.Ar file1 216is older than | 179exists and is older than |
217.Ar file2 . | 180.Ar file2 . |
218Note that 219.Ar file1 220.Ic -ot 221.Ar file2 222is equivalent to 223.Ar file2 224.Ic -nt 225.Ar file1 226.It Ar file1 Fl ot Ns Ar X Ns Ar Y Ar file2 227Equivalent to 228.Ar file2 229.Ic -nt Ns Ar Y Ns Ar X 230.Ar file1 . | |
231.It Ar file1 Fl ef Ar file2 232True if 233.Ar file1 234and 235.Ar file2 236exist and refer to the same file. 237.It Ar string 238True if --- 175 unchanged lines hidden --- | 181.It Ar file1 Fl ef Ar file2 182True if 183.Ar file1 184and 185.Ar file2 186exist and refer to the same file. 187.It Ar string 188True if --- 175 unchanged lines hidden --- |