Linux命令(1)
cd <directory>
Short for "change directory".
The shorthand name for the current directory is .
The shorthand name for the parent directory is ..
pwd
present working directory
ls
list the contents of the present directory
mkdir <directory> //<directory> is the represent for the name of the directory
Short for "make directory",this command will create a new subdirectory called <directory> located in the current directory
cp <source> <destination> // 仅复制单个文件,不能复制文件夹
Short for "copy",this command will allow you to create a duplicate of the file you specify as <source>,whichi it will save in <destination>
eg. cp hello.c hi.c // copy hello.c and rename the copyfile as hi.c in the present directory
-r <directory> <destinction> //加了参数 -r 表示复制文件夹
Short for "recursive",copy the directory recursively.copy the <directory> and copy every folder that exists inside of it and every file that exists inside of it.In other words, It need to recursively dive down into <destincton> and make a copy of everything in there
rm <file> // 仅删除单个文件,不能删除文件夹
Short for "remove",this command will delete<file> after it asks you to confirm (y/n) you want to delete it.
-f <file>
Short for "force",foce rm to do exactly what we're telling it to do.
but use at your own peri!there's no undo.
-r <directory>
to delete entire directories you need to use the -r flag,just as was the case with cp.
-rf
combine the -r and -f flags into -rf .Again,careful!There's no undo!
mv // 移动文件
Short for "move",this command will allow you to effectively rename a file,moving it from <source> to <destination>.
Rename Source to DEST,or move SOURCE(s)to DIRECTORY.
problem: su command cannot use
sudo passwd // set root password;and then you can use su command
Linux命令(1)的更多相关文章
- Linux实战教学笔记04:Linux命令基础
第四节:Linux命令基础 标签(空格分隔):Linux实战教学笔记 第1章 认识操作环境 root:当前登陆的用户名 @分隔符 chensiqi:主机名 -:当前路径位置 用户的提示符 1.1 Li ...
- 像黑客一样使用 Linux 命令行
前言 之前在博客园看到一篇介绍 IntelliJ IDEA 配置的文章,它里面用的是 gif 动态图片进行展示,我觉得很不错.所以在我今天以及以后的博文中,我也会尽量使用 gif 动图进行展示.制作 ...
- 11 个很少人知道但很有用的 Linux 命令
Linux命令行吸引了大多数Linux爱好者.一个正常的Linux用户一般掌握大约50-60个命令来处理每日的任务.Linux命令和它们的转换对于Linux用户.Shell脚本程序员和管理员来说是最有 ...
- Linux命令随笔
Linux命令总结 man ==命令帮助; help ==命令的帮助(bash的内置命令); ls ==list,查看目录列表; -ld:查看目录权限; -l:(long)长格式显示属性; -F:给不 ...
- linux命令在线手册
下面几个网址有一些 Linux命令的在线手册,而且还是中文的,还可以搜索.非常方便 Linux命令手册 Linux命令大全 Linux中文man在线手册 每日一linux命令
- 常用的一些linux命令
最近接触到一些linux环境部署的事情,下面分享一些最近使用的比较频繁的一些linux命令~ 1.一次性移动多个文件到一个文件夹里 mv 被移动文件名 -t 目标文件夹 如:mv a.txt b.t ...
- 测试或运维工作过程中最常用的几个linux命令?
大家在测试工作过程中,可能会遇到需要你去服务器修改一些配置文件,譬如说某个字段的值是1 则关联老版本,是0则关联新版本,这时候你可能就需要会下vi的命令操作:或者查看session设置的时长,可能需 ...
- 每天一个 Linux 命令(21):find命令之xargs
在使用 find命令的-exec选项处理匹配到的文件时, find命令将所有匹配到的文件一起传递给exec执行.但有些系统对能够传递给exec的命令长度有限制,这样在find命令运行几分钟之后,就会出 ...
- 在windows下使用linux命令,GnuWin32的使用.
http://sourceforge.net/projects/getgnuwin32 使用过linxu的伙计估计都会喜欢上linux各种各样强大的命令如:grep, sed,awk,diff和pat ...
- 我常用的那些linux命令
我常用的那些linux命令 用linux也有些年头了,说来也忏愧,说是有些年头了,其实也还是个不长进的主.记得第一次接触linux是boss跟我说的怎么操作,什么编辑模式,按i,a,o进入编辑模式.在 ...
随机推荐
- JS中的提升(即变量和函数声明移动到代码顶部)
先看代码(第一个代码片段): console.log(a); var a = 1; 如果你认为这是一段不合法的代码,在调用console.log()的时候会输出undefined,你完全正确.但是如果 ...
- 从头学pytorch(四) softmax回归实现
FashionMNIST数据集共70000个样本,60000个train,10000个test.共计10种类别. 通过如下方式下载. mnist_train = torchvision.dataset ...
- Fluent_Python_Part4面向对象,08-ob-ref,对象引用、可变性和垃圾回收
第四部分第8章,对象引用.可变性和垃圾回收 1. 创建对象之后才会把变量分配给对象 变量是对象的标注,是对象的别名,是对象的引用,并不是对象存储的地方. 例子1. 证明赋值语句的右边先执行 class ...
- spark实验(四)--RDD编程(1)
一.实验目的 (1)熟悉 Spark 的 RDD 基本操作及键值对操作: (2)熟悉使用 RDD 编程解决实际具体问题的方法. 二.实验平台 操作系统:centos6.4 Spark 版本:1.5.0 ...
- 局域网内Linux下开启ftp服务的“曲折路”和命令复习
今天主要学习了Linux下网络配置以及vsftp(FTP)和samba的服务配置,学习起来,难度也就一般,并没有特别难,可是在可以做实验的时候,却并没有自己想像的那么顺利,可见,很多事情看起来不难,做 ...
- Emprie 使用基础笔记
0x01 简介 empire 是一个后渗透攻击框架,具有加密通信和灵活框架的功能.Empire可以在不需要Powershell.exe的情况下执行PowerShell代理,后期利用的模块很强大,如sc ...
- spring boot中配置文件中变量的引用
配置文件中 变量的自身引用 ${名称} java文件中引用:非静态变量 之间在变量上面注释@Value("${名称}") 静态变量 在set方法上注释@Value("$ ...
- Cat4500升级注意事项
第一部分:升级ROMMON 可以通过release note去查看什么Supervisor建议什么样的版本.例如:ROMMON Release Notes for the WS-X45-SUP7-E, ...
- Js 类继承 extends
html 及 js 代码 <!DOCTYPE html> <html lang="en"> <head> <meta charset=&q ...
- java_1:为什么我一搞PHP的要转JAVA
为什么我一搞PHP的要高JAVA? 没什么!就他妈逼的看不惯搞JAVA那群逼鄙视PHPer的样!你会JAVA,稍微发功老子一样搞!