Linux初学者笔记 续

first: bash command

ls parameters :-a (all); -l(detailed)
rm parameters :-r (recursion); -f(force)
cp parameters :-r
mkdir parameters :-p
touch
mv
cd parameters :~ ; ;..
cat
chmod
chown
chgrp
history parameters :number
sudo apt-get install pakagename
sudo apt-get update
wget url :download
diff -u 1 2:Compare the different 1 and 2
tree
whoami:Check username
sudo:To root identity to do certain things

bash shortcuts

ctril c:End process
ctril z:hung and Steering backstage execution

second:vim command

vim’s configuration

vi .vimrc in home and then write configuration something in it, for example
, set number
you can installing plugins in the .vim in home, if you want to creat a
version about the .vimrc and vim, you shoud make a fake .vimrc in home and
write “runtime vimrc” in it, and you shoud creat the “vimrc” file in the .vim,
and then write some configuration in it.

label

ctags hello.c
vi hello.c
ctrl-]
ctrl-o

third:git command

sudo apt-get install git-core
sudo apt-get install tig

clone a file from internet

git clone url:clone a file

set up the verson control

git init:set up a necessary file
git add filename:stages your file, adding it to a list of files to be committed
git commit -a -m “something”(or git ci “something”):commits you files, adding the message “something”

when you need do a change in your file ,you shoud execution this command “git commit -a -m “something”” again.

In a change at a version control

tig
d : view a version
q : exit

you need creat a Repo in github and then perform following operations

git remote add origin git@github.com:username/filename.git: sets the origin for the file repo
git push origin master:sends your commit to github

back to the past

git reset –hard HEAD^

View manual

man git-commit

forth:firefox command

ctrl-r:refresh
F11:enter or quit fullscreen

Chinese garbled problem

view -> character encoding -> UTF-8

See page source

ctrl-u

fivth:markdown command

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值