跳到主要内容

命令说明

用户名与账号​

      UCSB identifies users of its Simple-Minded File System by:

(1) user name --

a character string of from one to eight alphameric characters
of SP, and

(2) account --

a character string of from one to four alphameric characters
or SP.

SMFS 在内部保存一对累加器: 一个存放用户名, 另一个存放账号; 两者要么是用户显式给出的字符串, 要么是 SMFS 提供的默认值(分别是用户的 TENEX 登录目录名与 "l"). 两个累加器初始都置为各自的默认值.

注: 如果用户的登录目录名长度超过 8 个字符, 用户必须显式给出用户名, 此时没有可用的默认值.

每当 SMFS 代表用户与 Santa Barbara 的服务器进程交互时, 使用的都是当时这两个累加器中的记账参数.

用户用 USER NAME 与 ACCOUNT 命令设置并查看用户名与账号:

      U[ser name]
[[currentusername]] newusername CR
SP [logindirectoryname]
CR

A[ccount]
[[currentaccount]] newaccount CR
SP [1]
CR

USER NAME 与 ACCOUNT 分别显示并可选择修改用户名累加器与账号累加器的内容:

      If 'newusername' or 'newaccount' is specified, it replaces the
current contents of the appropriate accumulator.

If SP is specified, the accumulator is set to the appropriate
default.

If CR is typed, the user name or account is left unchanged.

COPY​

COPY 命令用来把某文件的一份副本传入 UCSB 或从 UCSB 取出. 作为复制源的文件保持不变; 用户必须对它有读权限. 该命令的语法依传输方向取下列之一:

      C[opy]
[(to/from UCSB] T[o]
[(file)] localfilespec CR
[(store as file)] remotefilespec CR
[(create/replace)] C[reate]
R(eplace]

C[opy]
[to/from UCSB] F[rom]
[(file)] remotefilespec CR
[(store as file)] localfilespec CR

where 'localfilespec' and 'remotefilespec' are as defined in
Section V.

注意, 只要把 "localfilespec" 指定得与 "remotefilespec" 不同, 文件实际上可以在 TENEX 与 UCSB 之间的传输途中被改名. 更常见的情形是, 两个文件说明中的第二个干脆就是 ESC. 在 "localfilespec" 中不套用第 V 节的字段默认算法, 而适用通常的 TENEX 默认值.

若在复制到 UCSB 时用户指定 "create"; 而 UCSB 已存在同名文件, SMFS 将忽略该命令(并通知用户). 若指定 "replace"; 而 UCSB 并不存在同名文件, 该命令也会被忽略. 此外, 若指定 "replace", 用户必须对 UCSB 上已存在的该文件有写权限.

MOVE​

MOVE 命令的作用与 COPY 相同, 区别只在于: 该操作的源文件在成功传输之后被删除. 用户必须对源文件同时拥有读权限与写权限.

LOCATE​

LOCATE 命令用来核实 UCSB 上某个文件是否存在. 其语法为

      L[ocate (file)] filespec CR
[Archived at UCSB]
[Not Archived at UCSB]

对所指定的文件既不需要读权限, 也不需要写权限.

注: LOCATE 是现有条件下最接近 TENEX DIRECTORY 命令的东西. 由于 UCSB 施加的限制, 完整的 DIRECTORY 命令目前无法实现.

DELETE​

DELETE 命令删除此前复制或移动到 UCSB 的文件, 并释放分配给它的全部辅助存储:

      D[elete (file)] filespec CR

用户必须对 UCSB 上的该文件拥有写权限.

RENAME​

RENAME 命令改变此前一次移动或复制操作之后驻留在 UCSB 的文件名:

      R[ename (file)] filespec CR
[(new file)] newfilespec CR

用户必须对 UCSB 上的该文件拥有写权限, 并且那里不得已存在名为 "newfilespec" 的文件.

PASSWORD​

文件驻留在 UCSB 期间, 可以分别通过设置读口令和/或写口令来防止未经授权的访问或修改. 口令是 1 到 36 个字母数字字符或 SP 组成的字符串.

SMFS 在内部保存一对累加器: 一个始终为空或存放读口令, 另一个为空或存放写口令(两个累加器初始都为空). 每当用户发出的命令需要口令时(始终是隐含地需要), 就使用当时相应累加器中的那个口令. 累加器为空即意味着 "无口令".

用户用 PASSWORD 命令设置并查看这两个口令:

      P[assword]
[(read/write)] R[ead]
W[rite]
[[currentpassword]] newpassword CR
SP [none]
CR

PASSWORD 显示并可选择修改两个口令累加器之一的内容:

      If 'new password' is specified, it replaces the current contents
of the accumulator.

If SP is specified, the accumulator is made empty.

If CR is typed, the password is left unchanged.

NEWS​

NEWS 命令在用户终端上打印下列文件的内容:

      SRI-ARC: <SYSTEM >SMFS.NEWS1

该文件驻留在 UCSB. SRI-ARC 维护这个文件, 必要时把与 UCSB 归档服务用户有关的信息(例如命令语法的变更)写进去. 比如用户若对本文所述的某条命令遇到困难, NEWS 是获取帮助的好起点.

该命令的语法为:

      N[ews] CR

如果该新闻文件很长, SMFS 会周期性地暂停并打出 'Continue?'. 此时用户可回答 'N' 停止打印, 或回答 'Y' 或 CR 继续打印(当然, 在任何时候都可以用 control-O 中止打印).

QUIT​

QUIT 命令使 SMFS 返回 EXEC:

      Q[uit] CR

[This RFC was put into machine readable form for entry]
[into the online RFC archives by Helene Morin, Via Genie 12/99]