'\" te .\" Copyright 1989 AT&T Copyright (c) 1995, Sun Microsystems, Inc. All Rights Reserved Portions Copyright (c) 1992, X/Open Company Limited All Rights Reserved .\" Sun Microsystems, Inc. gratefully acknowledges The Open Group for permission to reproduce portions of its copyrighted documentation.Original documentation from The Open Group can be obtained online at http://www.opengroup.org/bookstore/. .\" The Institute of Electrical and Electronics Engineers and The Open Group, have given us permission to reprint portions of their documentation.In the following statement, the phrase"this text" refers to portions of the system documentation.Portions of this text are reprinted and reproduced in electronic form in the Sun OS Reference Manual, from IEEE Std 1003.1, 2004 Edition, Standard for Information Technology -- Portable Operating System Interface (POSIX), The Open Group Base Specifications Issue 6, Copyright (C) 2001-2004 by the Institute of Electrical and Electronics Engineers, Inc and The Open Group.In the event of any discrepancy between these versions and the original IEEE and The Open Group Standard,the original IEEE and The Open Group Standard is the referee document.The original Standard can be obtained online at http://www.opengroup.org/unix/online.html.This notice shall appear on any product containing this material. .TH line 1 "1995 年 2 月 1 日" "SunOS 5.11" "用户命令" .SH 名称 line \- 读取一行 .SH 用法概要 .LP .nf \fBline\fR .fi .SH 描述 .sp .LP \fBline\fR 实用程序会从标准输入中复制一行(直到并包括换行符)并将其写入标准输出。它会在 \fB\fR\fBEOF\fR\fB 时返回退出状态 1,\fR并始终会至少输出一个换行符。通常用于 shell 文件中,以从用户终端进行读取。 .SH 退出状态 .sp .LP 退出状态为: .sp .ne 2 .mk .na \fB\fB0\fR\fR .ad .RS 6n .rt 成功完成 .RE .sp .ne 2 .mk .na \fB\fB>0\fR\fR .ad .RS 6n .rt 输入时文件结束。 .RE .SH 属性 .sp .LP 有关下列属性的说明,请参见 \fBattributes\fR(5): .sp .sp .TS tab() box; cw(2.75i) |cw(2.75i) lw(2.75i) |lw(2.75i) . 属性类型属性值 _ 可用性system/core-os .TE .SH 另请参见 .sp .LP \fBsh\fR(1)、\fBread\fR(2)、\fBattributes\fR(5)