Log inUsernamePassword
Log me on automatically each visit    
Register
Register
Log in to check your private messages
Log in to check your private messages
Zaurus 中文论坛 Forum Index » pdaXrom & debain & openBSD

This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.
Z机的命令行
View previous topic :: View next topic  
Author Message
ccpaging



Joined: 07 Dec 2006
Posts: 757

小企鹅: 16604

PostPosted: 2006-Apr-15 Sat, pm1:41 Reply with quote
 Post subject: Z机的命令行

俺的C1000要4月低到手,找个pdaxrom在vmware下的virtual环境先试试手。因为原来做zhcon的缘故,所以对字符环境console有特别的兴趣。初步研究padxrom的命令跟redhat差不多,有些小变化。下面对常用的命令做些总结:
1、进入命令行
linux启动后,先login,这时就已经是命令行了,如果你不输入startx的话。
2、任务管理器,可以看到当前运行的进程
ps
3、杀掉进程
kill <pid>
pid参数是ps中显示出的进程号,pid=process id
4、重启动
reboot
或者
shutdown -r now

从命令行关闭机器
shutdown -h now

5、命令行的文件管理器
好久没用DOS了,dir文件,拷贝文件,删除文件的命令都忘了吧?你根本就不知道DOS,那太好了。
输入以下命令:
mc
怎么样?看到跟windows的资源管理器差不多的东东了吧,其实它更像DOS下的NC或者PC Tools,不管是什么,好用就行。

6、检查环境变量
跟DOS环境一样,console也有环境变量,包括搜索路径、命令行提示符等,以下命令显示全部的环境变量:
env
修改环境变量,例如:
PS1=="[\w]# ";export PS1
在命令行的前面是不是能看到当前路径了。
不过这只是临时的,重启动以后会恢复成原来那个光秃秃的#,能不能做成启动缺省的设置呢?
按照标准的bash命令,应该修改~/.bashrc,这里~是你的home目录,如果你用root登录,~等价于/home/root。
在~目录中建立.bashrc文件,输入以下内容:
# .bashrc

# User specific aliases and functions

alias rm='rm -i'
alias cp='cp -i'
alias mv='mv -i'

# Source global definitions
if [ -f /etc/bashrc ]; then
. /etc/bashrc
fi

alias ls="ls --color=tty --show-control-chars"
alias dir="ls --color=tty --show-control-chars"

保存后重启动,登录root后进入命令行环境。
有问题!还是光秃秃的#,以上的修改没有作用,试试输入以下命令:
bash
命令行提示符改变了,加上了路径,这至少说明我们的.bashrc是有效的。
看来pdaxrom的shell程序不是bash,分析后我们发现世纪上是busybox,不熟悉,继续搜索系统,发现有个/etc/profile,让我们按以下方式修改这个文件:
修改
PS="[\w]# "

增加
alias ls="ls --color=tty --show-control-chars"
alias dir="ls --color=tty --show-control-chars"

保存后,重启动机器,login后,全部OK啦。输入
ls
或者
dir
彩色方式显示目录,太棒了。
Back to top
View user's profile Send private message
ccpaging



Joined: 07 Dec 2006
Posts: 757

小企鹅: 16604

PostPosted: 2006-Apr-15 Sat, pm2:13 Reply with quote
 Post subject: zhcon在Z机上能用吗?

看起来padxrom的命令行用的是frame buffer的图形显示方式,在启动时能看到小企鹅图标,估计zhcon应该可以用。

zhcon是什么东西?
它是linux console,也就是命令行环境下的中文字符显示环境,是外挂式的CJK console,支持中日韩文,日文的单字符有点问题。

装zhcon以后,看文本小说就轻松多了。字体显示支持16/24点阵,用原来UCDOS的字库,绝对漂亮。点阵可以支持更高,不过在z机的640X480下,太大点阵就没用了。

原来在命令行上看不到中文目录,zhcon可以解决。其实命令行下面可以干不少事的。

等拿到C1000,俺做小白鼠试试。
Back to top
View user's profile Send private message
badog
论坛管理员


Joined: 01 Nov 2006
Posts: 1021

小企鹅: 6575

PostPosted: 2006-Apr-15 Sat, pm4:13 Reply with quote
 Post subject:

zhcon没有人编译成Z机用的.我什么时候也去"公社"看一眼
Back to top
View user's profile Send private message Send e-mail
ccpaging



Joined: 07 Dec 2006
Posts: 757

小企鹅: 16604

PostPosted: 2006-Apr-15 Sat, pm5:03 Reply with quote
 Post subject:

I should try when possible
zhcon的主页不在公社,在
http://zhcon.sf.net/
Back to top
View user's profile Send private message
Display posts from previous:     
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Zaurus 中文论坛 Forum Index » pdaXrom & debain & openBSD All times are GMT + 8 Hours
Page 1 of 1

 
Jump to:   
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum

[ 页面生成时间: 秒 ] :: [ 次查询 ] :: [ ]
Powered by phpBB © 2001, 2002 phpBB Group
iCGstation v1.0 Template By Ray © 2003, 2004 iOptional