编译错误: /bin/sh: 1: pushd: not found的问题 http://www.cnblogs.com/wansui/p/4230869.html 查看原因:进入/bin目录,查看sh的链接文件,显示如下:表示sh命令链接到的是dash,而pushd命令需要在bash的环境中执
分类:
系统相关 时间:
2016-03-14 18:42:36
阅读次数:
414
自动补全命令需要用到源码包:branchmastertags选择相应的版本克隆岛本地#gitclonehttps://github.com/git/git也可以直接下载zip的源码包cp/contrib/completion/git-completion.bash~/.git-completion.bashsource~/.git-completion.bash或者将source写入~/.bashrc自动加载
分类:
系统相关 时间:
2016-03-14 17:01:37
阅读次数:
186
什么是Shell?bash是干啥的?有什么关系shell是你(用户)和Linux(或者更准确的说,是你和Linux内核)之间的接口程序。你在提示符下输入的每个命令都由shell先解释然后传给Linux内核。shell是一个命令语言解释器(command-languageinterpreter)。拥有自己内建的shell命令集。..
分类:
系统相关 时间:
2016-03-14 16:54:43
阅读次数:
290
修改用户标识符-bash-4.1$iduid=501(www)gid=501(www)组=501(www)-bash-4.1$su-密码:-bash-4.1#cp/etc/skel/.bash.bash_logout.bash_profile.bashrc-bash-4.1#cp/etc/skel/.bash*/home/www/-bash-4.1#chown-Rwww:www/home/www-bash-4.1#su-www[www@opark_gc_php_113~]$系统默..
分类:
其他好文 时间:
2016-03-14 16:44:21
阅读次数:
173
前一段时间,因工作需要在物理机上装了一个Centos6.5,但是,用了一段时间,发现再登录时,无论如何也登不进去了,并且也不提示用户名或者密码错误。我一度以为是在profile以及.bashrc或者.bash_profile里设置了logout命令,于是乎进入单用户模式,各种查看,也没有发现logo
分类:
其他好文 时间:
2016-03-14 16:31:26
阅读次数:
289
#!/bin/bash#Aliyunbot/sbin/iptables-IINPUT-miprange--src-range110.75.160.0-110.75.191.255-ptcp--dport80-jREJECT#Qihoo/sbin/iptables-IINPUT-miprange--src-range65.48.172.0-65.48.172.255-ptcp--dport80-jREJECT#Sougo/sbin/iptables-IINPUT-miprange--src-range220.1..
分类:
其他好文 时间:
2016-03-14 02:06:09
阅读次数:
181
#!/bin/bash
#date:2016-03-12
#desc:LAN/MPautoinstallscript
#Author:Djoker
#functionarea
#<---------------------start---------------------------------------->
#function:checkerror
runcheck(){
if[$1!=0];then
echo"------------------------"
echo"|Error,pl..
分类:
其他好文 时间:
2016-03-14 01:51:08
阅读次数:
260
linux下默认ll是ls -l的别名。OS X下默认不支持。习惯了linux下使用ll,我们同样也可以将习惯搬到os x下的shell中。 再当前用户家目录下新建.bash_profile文件。根据你的习惯,添加下面格式内容即可。 然后执行:source .bash_profile你还可以添加你喜
分类:
系统相关 时间:
2016-03-13 22:33:33
阅读次数:
246
#!/bin/bash
#szkwritenis2016/3/13
#宝宝,好玩不?
while:
do
read-p"请输入您的成绩:"n
n1=`echo$n|sed‘s/[0-9]//g‘`
if[-z$n]
then
echo"您未曾输入,请输入您的成绩"
continue
elif[!-z$n1]
then
echo"您输入的不是数字,请重新输入"
continue
fi
break
done
if[$n-lt60]&am..
分类:
其他好文 时间:
2016-03-13 18:08:44
阅读次数:
145
the canonical way to read one line of input with the read builtin is: 如: IFS=',' read -ra DEPS <<< ${dependencies} 转自: http://unix.stackexchange.com
分类:
其他好文 时间:
2016-03-13 17:23:09
阅读次数:
558