aboutsummaryrefslogtreecommitdiff
path: root/ja_JP.eucJP/man/man1/test.1
diff options
context:
space:
mode:
Diffstat (limited to 'ja_JP.eucJP/man/man1/test.1')
-rw-r--r--ja_JP.eucJP/man/man1/test.1280
1 files changed, 0 insertions, 280 deletions
diff --git a/ja_JP.eucJP/man/man1/test.1 b/ja_JP.eucJP/man/man1/test.1
deleted file mode 100644
index 2511ae3188..0000000000
--- a/ja_JP.eucJP/man/man1/test.1
+++ /dev/null
@@ -1,280 +0,0 @@
-.\" Copyright (c) 1991, 1993
-.\" The Regents of the University of California. All rights reserved.
-.\"
-.\" This code is derived from software contributed to Berkeley by
-.\" the Institute of Electrical and Electronics Engineers, Inc.
-.\"
-.\" Redistribution and use in source and binary forms, with or without
-.\" modification, are permitted provided that the following conditions
-.\" are met:
-.\" 1. Redistributions of source code must retain the above copyright
-.\" notice, this list of conditions and the following disclaimer.
-.\" 2. Redistributions in binary form must reproduce the above copyright
-.\" notice, this list of conditions and the following disclaimer in the
-.\" documentation and/or other materials provided with the distribution.
-.\" 3. All advertising materials mentioning features or use of this software
-.\" must display the following acknowledgement:
-.\" This product includes software developed by the University of
-.\" California, Berkeley and its contributors.
-.\" 4. Neither the name of the University nor the names of its contributors
-.\" may be used to endorse or promote products derived from this software
-.\" without specific prior written permission.
-.\"
-.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
-.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
-.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
-.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
-.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
-.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
-.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
-.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
-.\" SUCH DAMAGE.
-.\"
-.\" @(#)test.1 8.1 (Berkeley) 5/31/93
-.\" %FreeBSD: src/bin/test/test.1,v 1.11.2.3 2001/08/16 10:01:11 ru Exp %
-.\"
-.\" $FreeBSD: doc/ja_JP.eucJP/man/man1/test.1,v 1.14 2001/07/29 05:14:53 horikawa Exp $
-.\"
-.Dd May 31, 1993
-.Dt TEST 1
-.Os
-.Sh 名称
-.Nm test ,
-.Nm \&[
-.Nd 条件式評価ユーティリティ
-.Sh 書式
-.Nm
-.Ar expression
-.Nm \&[
-.Ar expression Cm ]
-.Sh 解説
-.Nm
-ユーティリティは、式を評価し、結果が真なら 0 (true) を、
-偽なら 1 (false) を戻り値として返します。引数の式がない
-場合も 1 (false) を返します。
-.Pp
-演算子やフラグなどは、一つ一つ独立な引数として
-.Nm
-ユーティリティに渡します。
-.Pp
-式は以下の基本要素から構成されます:
-.Bl -tag -width Ar
-.It Fl b Ar file
-.Ar file
-が存在し、それがブロック特殊ファイルであるならば真になります。
-.It Fl c Ar file
-.Ar file
-が存在し、それがキャラクタ特殊ファイルであるならば真になります。
-.It Fl d Ar file
-.Ar file
-が存在し、それがディレクトリであるならば真になります。
-.It Fl e Ar file
-.Ar file
-が存在すれば真になります (ファイルの種類に依りません)。
-.It Fl f Ar file
-.Ar file
-が存在し、それが通常ファイルであるならば真になります。
-.It Fl g Ar file
-.Ar file
-が存在し、それに setgid フラグが立っていれば真になります。
-.It Fl h Ar file
-.Ar file
-が存在し、それがシンボリックリンクであるならば真になります。
-この演算子は、本プログラムの以前のバージョンとの互換性のためにあります。
-この演算子があることに依存しないようにしてください。
-代りに
-.Fl L
-を使用してください。
-.It Fl k Ar file
-.Ar file
-が存在し、それにスティッキービットが立っていれば真になります。
-.It Fl n Ar string
-.Ar string
-の長さが 0 でなければ真になります。
-.It Fl p Ar file
-.Ar file
-が名前つきパイプ
-.Pq Tn FIFO
-であるならば真になります。
-.It Fl r Ar file
-.Ar file
-が存在し、それが読み込み可能であれば真になります。
-.It Fl s Ar file
-.Ar file
-が存在し、そのファイルサイズが 0 より大きければ真になります。
-.It Fl t Op Ar file_descriptor
-ファイルディスクリプタ番号が
-.Ar file_descriptor
-であるファイルがオープンされており、これが端末に
-結びつけられていれば
-真になります。
-.It Fl u Ar file
-.Ar file
-が存在し、それに setuid フラグが立っていれば真になります。
-.It Fl w Ar file
-.Ar file
-が存在し、書き込み可能であれば真になります。真ということは、
-書き込み可能フラグが立っていることを表すに過ぎません。
-ファイルが読み込み専用のファイルシステム上にあると、たとえ
-この判定が真であっても書き込みはできません。
-.It Fl x Ar file
-.Ar file
-が存在し、実行可能であれば真になります。真ということは、
-実行可能フラグが立っていることを表すに過ぎません。
-.Ar file
-がディレクトリの場合、真は
-.Ar file
-が検索可能であることを表します。
-.It Fl z Ar string
-.Ar string
-の長さが 0 であれば真になります。
-.It Fl L Ar file
-.Ar file
-が存在し、シンボリックリンクの場合に真になります。
-.It Fl O Ar file
-.Ar file
-が存在し、
-その所有者と本プロセスの実効ユーザ ID とがマッチする場合に真になります。
-.It Fl G Ar file
-.Ar file
-が存在し、
-そのグループと本プロセスの実効グループ ID とがマッチする場合に真になります。
-.It Fl S Ar file
-.Ar file
-が存在し、ソケットの場合に真になります。
-.It Ar file1 Fl nt Ar file2
-.Ar file1
-が存在し、
-.Ar file2
-よりも新しい場合に真になります。
-.It Ar file1 Fl ot Ar file2
-.Ar file1
-が存在し、
-.Ar file2
-よりも古い場合に真になります。
-.It Ar file1 Fl ef Ar file2
-.Ar file1
-と
-.Ar file2
-が存在し、これらが同一のファイルを参照する場合に真になります。
-.It Ar string
-.Ar string
-が空文字列でなければ真になります。
-.It Ar \&s\&1 Cm \&= Ar \&s\&2
-文字列
-.Ar \&s\&1
-と
-.Ar \&s\&2
-が同一であれば真になります。
-.It Ar \&s\&1 Cm \&!= Ar \&s\&2
-文字列
-.Ar \&s\&1
-と
-.Ar \&s\&2
-が同一でなければ真になります。
-.It Ar \&s\&1 Cm \&< Ar \&s\&2
-文字列
-.Ar \&s\&1
-が文字列
-.Ar \&s\&2
-に対し、文字の ASCII 順において前に来る場合に真になります。
-.It Ar \&s\&1 Cm \&> Ar \&s\&2
-文字列
-.Ar \&s\&1
-が文字列
-.Ar \&s\&2
-に対し、文字の ASCII 順において後に来る場合に真になります。
-.It Ar \&s\&1
-文字列
-.Ar \&s\&1
-が空文字列でない場合に真になります。
-.It Ar \&n\&1 Fl \&eq Ar \&n\&2
-整数
-.Ar \&n\&1
-と
-.Ar \&n\&2
-が等しければ真になります。
-.It Ar \&n\&1 Fl \&ne Ar \&n\&2
-整数
-.Ar \&n\&1
-と
-.Ar \&n\&2
-が等しくなければ真になります。
-.It Ar \&n\&1 Fl \&gt Ar \&n\&2
-整数
-.Ar \&n\&1
-が
-.Ar \&n\&2
-がより大きければ真になります。
-.It Ar \&n\&1 Fl \&ge Ar \&n\&2
-整数
-.Ar \&n\&1
-が
-.Ar \&n\&2
-より大きいか等しければ真になります。
-.It Ar \&n\&1 Fl \&lt Ar \&n\&2
-整数
-.Ar \&n\&1
-が
-.Ar \&n\&2
-より小さければ真になります。
-.It Ar \&n\&1 Fl \&le Ar \&n\&2
-整数
-.Ar \&n\&1
-が
-.Ar \&n\&2
-より小さいか等しければ真になります。
-.El
-.Pp
-これらの基本要素は以下の演算子と組み合わせることができます:
-.Bl -tag -width Ar
-.It Cm \&! Ar expression
-.Ar expression
-が偽ならば真になります。
-.It Ar expression1 Fl a Ar expression2
-.Ar expression1
-と
-.Ar expression2
-の両方が真ならば真になります。
-.It Ar expression1 Fl o Ar expression2
-.Ar expression1
-と
-.Ar expression2
-のどちらかが真ならば真になります。
-.It Cm \&( Ns Ar expression Ns Cm \&)
-.Ar expression
-が真ならば真になります。
-.El
-.Pp
-.Fl a
-演算子は
-.Fl o
-演算子より優先されます。
-.Sh 文法の曖昧性
-.Nm
-に使用されている文法は本質的に曖昧です。ある程度の一貫性を確保するため、
-.St -p1003.2
-の D11.2/4.62.4 節で述べられているケースに関しては、この標準化文書が
-規定する規則に一貫して従った評価が行われます。しかしその他のケース
-では、コマンドの持つ意味の曖昧さに左右されます。
-.Sh 戻り値
-.Nm
-ユーティリティは次のいずれかの値を返します。
-.Bl -tag -width Ds
-.It 0
-式を評価した結果が真である
-.It 1
-式を評価した結果が偽であるか、式がない
-.It >1
-エラーが発生した
-.El
-.Sh 関連項目
-.Xr expr 1 ,
-.Xr sh 1
-.Sh 規格
-.Nm
-ユーティリティは、
-.St -p1003.2
-仕様の上位互換実装です。