首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 操作系统 > UNIXLINUX >

写一个最简略的shell程序 cd home/test

2013-04-21 
写一个最简单的shell程序 cd home/test新建了一个文件a,里面写了一句 cd home/a保存退出后,在本目录下, ./

写一个最简单的shell程序 cd home/test
新建了一个文件a,里面写了一句

 

cd home/a


保存退出后,在本目录下, ./a 想运行这个shell程序,但失败了

bash: ./a: Permission denied


怎么回事?
[解决办法]
#!/bin/bash
#This script is a test!
echo -n "Date and Time is:"
date
echo "The executable path is:"$PATH
echo "Your name is :`whoami`"
echo -n "Your current directory is:"
pwd
#end

热点排行