1 Star 0 Fork 5.3K

Clam06 / docs

forked from OpenHarmony / docs 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
rm.md 3.16 KB
一键复制 编辑 原始数据 按行查看 历史
wenjun 提交于 2020-09-08 10:08 . add OpenHarmony 1.0 baseline

rm

Command Function

This command is used to delete a file or folder.

Syntax

rm [-r] [dirname / filename]

Parameter Description

Table 1 Parameters

Parameter

Description

Value Range

-r

Deletes a directory. This parameter is optional. It is required if a directory is to be deleted.

N/A

dirname/filename

Indicates the name of the file or directory to be deleted. The value can be a path.

N/A

Usage

  • The rm command deletes only one file or directory at a time.
  • The rm -r command can be used to delete a non-empty directory.

Example

Example:

  1. Enter rm log1.txt.
  2. Enter rm -r sd.

Output

Figure 1 Deleting the log1.txt file

Figure 2 Deleting the sd directory

1
https://gitee.com/clam06/docs.git
git@gitee.com:clam06/docs.git
clam06
docs
docs
master

搜索帮助