# ------ generic symbol ------------------------------------------
/ : root directory
~ : usr directory
./ : current directory path
.. : up directory path
!cmd : invoke last command
& : run job in background
# ------ file operation -----------------------------------------
man cmd : manual
ls : list the directory and files
ls -a : list all includes hidden directory and files
ls -l : format list
ll -a : format list
cd : change directory to the /home/user
cd ~ : ~ means the /home/user directory
cd dir_path : go to the dir_path directory
pwd : present working directory
mkdir dir : create a directory
touch file : create a file
vi file : vi editor
gvim file : gvim editor
chmod 777 dir : change r/w/x property
cat file : look at the file context on terminal
more file : view the file
less file : view the file like gvim or vi
cp -f file1 file2 : copy file1 to file2
cp -r dir1 dir2 : copy directory recursively
mv file1 dir|file2 : move (or rename) file1 to file2
wc file : count lines words and characters
wc -w file : count word of file
wc -l file : count line
rm file : remove file
rm -r dir : remove dir* (recursive)
rm -f file : enforced to remove file (force)
rm -rf dir : enforced to remove dir*
ln -s file link : create a symbolic link to file
grep pattern file : search pattern matched in file
grep error sim.log :
grep -r pattern dir : search pattern incursively in directory
find / -name file_name : search the file from / directory
find /etc -name '*con*' :
find / -size +100M :
#------ pack files -------------------------------
tar -cvf file.tar files : create a tar file
tar -xvf file.tar : extract a tar file
tar -czvf file.tar.gz files : create a gzip file
tar -xzvf file.tar.gz
tar -cjvf file.tar.bz2 files : create a bzip2 file
tar -xjvf file.tar.bz2
gzip file : create a file.gz file
gzip -d file.gz :
# ------ install rpm package ---------------------
rpm -qa : query all installed RPM packages
rpm -ivh RPM.rpm : install RPM package
./configure
make install
grep ERROR cmp.log > error.log
grep ERROR sim.log >> error.log
cat > file : sample the standard input and put them into the file
cmd | grep pattern : search pattern in cmd output
rpm -qa | grep vim
cat /etc/passwd | grep /bin/bash | wc -l
man ls | col -b > ls_man.txt
grep ERROR sim.log | tee -a error.log
#------ process manage -------------------------
ps : display the current active process
top : display all process of the OS
kill pid : stop the pid process
killall proc : stop all of the proc process
bg : list the suspended job in background
fg : resume the last suspended job in foreground
#------ system info ----------------------------
date : display system time
date +%Y%m%d
date +%s
date +%N
cal : display calendar
uptime :
w : display who logon and what are doing
whoami : print effective userid
uname -a : display all OS system info
which cmd : show the full path of the cmd
su root|usr : change the usr
exit : usr shell quit
echo $PATH : show the variable
clear : clear the info on the terminal
history : show the command history
!cmd : invoke the last cmd
make : invoke Makefile
make clean; make cpl; make sim :
cat /proc/cpuinfo : show CUP information
cat /proc/meminfo : show memory information
df : report file system disk space usage
du -b|k|m file|dir : estimate file space usage
du -s file|dir : summary
du -sm file|dir
# ------ network info --------------------------
ping host|IP : ping IP address and print the result
hostname : display system host name
ifconfig -a : configure the network
# ------ hot key -------------------------------
ctrl + c : stop the current command
ctrl + z : suspend the job and put it into background
'fg' can be used to resume the job
free the license and take it soon
# ------ added by qixin gongzuoshi -------------
ctrl + d : display directoy in cd command
linux & Gvim 常用命令Gvim常用命令linux常用命令Gvim常用命令# ------ open a file -----------vi file_name : open a file for editing on a terminalvim file_name :gvim file_name : gvim is a GUI of vi# when open a file , vi is in insert mode by defaulti : go
文章目录一、GVIM的三种工作模式二、命令模式操作2.1.光标移动2.2.复制/粘贴(copy/paste)2.3.剪切/删除(delete)2.4.改变/替换(change/replace)2.5.撤销/恢复(undo/Ctrl+return)三、末行模式操作3.1.保存与退出(write/quit)
一、GVIM的三种工作模式
命令模式(默认模式,打开GVIM即进入该模式)
插入模式(文本编...
实习后发现都是用 linux的;用linux很少在IDE里编程而是直接用 vim 进行编程。
由于vim太丑,在初期我都倔强的用gedit;后来同事说,你得学着用vim,这样才显得专业 ( ̄▽ ̄)"...
随着vim快捷键逐渐熟悉,慢慢明白vim的方便之处了~
vim是linux里的文本编辑器,但是比“记事本”(linux里是gedit)多了很多功能,而且支持很多功能、命令、快捷键,用熟了以后会大大提高文本编辑的便捷性。............
要在Linux下配置GVim,可以按以下步骤操作:
1. 安装GVim。可以使用Linux系统的包管理工具来完成安装,例如使用命令sudo apt-get install vim-gtk或sudo yum install vim-X11。
2. 配置GVim的外观。可以使用GVim的自定义主题,或者选择其他的主题。可以通过编辑~/.vimrc文件来进行配置。
3. 配置GVim的插件。可以选择安装各种插件来增强GVim的功能,例如自动补全、代码折叠等。可以使用插件管理器来完成安装。
4. 配置GVim的快捷键。可以修改默认的快捷键,或者添加自己的快捷键来提高工作效率。
5. 配置GVim的语法高亮。可以配置GVim来识别不同编程语言的语法,并进行高亮显示。
以上是在Linux下配置GVim的一些基本步骤,具体可以根据自己的需要进行调整。