Path: /usr/ports/editors/openoffice-1.0 Path: /usr/ports/editors/openoffice-1.0-ar Path: /usr/ports/editors/openoffice-1.0-dk Path: /usr/ports/editors/openoffice-1.0-es Path: /usr/ports/editors/openoffice-1.0-gr Path: /usr/ports/editors/openoffice-1.0-it Path: /usr/ports/editors/openoffice-1.0-nl Path: /usr/ports/editors/openoffice-1.0-se Path: /usr/ports/editors/openoffice-1.0-t...
本帖最后由 candytao819 于 2010-06-01 11:44 编辑 想在shell中写个从数据库中取数据的脚本,现在是取出数据了,两个量之间是用空格分隔的,想在两个数据之间用逗号分隔,该怎么处理下? 取出的数据是:590746 1478873 1586607 想要变成 :590746,1478873,1586607
app目录下: busybox ip_route usb_test wget list文件: app/busybox app/ip_route app/hello 我想得到的目标是: busybox,ip_route 写了个脚本,发现不满足要求 #!/bin/sh set -x cd ../app dir=$(find ./ -maxdepth 1 -type d -name "??*"|xargs -i basename {}) cd - awk '{print}' ./list |xargs -i basename {} |while read line do for i in $dir do if [[ "$i" == "$line" ]] then select_dir = ${select_di...