edokeh / spm-chaos-build-example

A simple example for spm-chaos-build

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

提示: 没有那个文件或目录

opened this issue · comments

我进入到js文件夹,执行下面命令,
spm chaos-build example -C seajs-config.js
控制台输出:: 没有那个文件或目录
我已经安装spm chaos-build,版本为2.1.1

不对啊,我的 spm-chaos-build 版本现在才是 0.1.9
你说的 2.1.1 是 spm 的版本号吧?
你执行下 npm list -g 看看是不是没有装 spm-chaos-build ?

或者执行下 spm chaos-build -h 看看能不能输出帮助信息

@edokeh
/usr/bin/spm-chaos-build -> /usr/lib/node_modules/spm-chaos-build/bin/spm-chaos-build

spm-chaos-build@0.1.9 postinstall /usr/lib/node_modules/spm-chaos-build
node scripts/postinstall.js

spm-chaos-build@0.1.9 /usr/lib/node_modules/spm-chaos-build
├── commander@1.1.1 (keypress@0.1.0)
├── grunt-contrib-copy@0.4.1
├── grunt-contrib-cssmin@0.6.0 (clean-css@1.0.2, grunt-lib-contrib@0.6.1)
├── grunt-contrib-compress@0.5.0 (prettysize@0.0.2, lazystream@0.1.0, archiver@0.4.3)
├── grunt-contrib-uglify@0.1.2 (grunt-lib-contrib@0.5.3, uglify-js@2.2.5)
├── grunt-cmd-transport@0.2.3 (clean-css@1.0.2, cmd-util@0.3.6, handlebars@1.0.10, uglify-js@2.2.5)
├── grunt-cmd-concat@0.2.2 (cmd-util@0.3.6)
├── spm-grunt@0.1.4 (spmrc@0.1.3, grunt@0.4.1)
├── grunt-md5@0.1.10 (grunt-cli@0.1.8, grunt@0.4.1)
├── grunt@0.4.1 (dateformat@1.0.2-1.2.3, which@1.0.5, colors@0.6.0-1, async@0.1.22, hooker@0.2.3, rimraf@2.0.3, eventemitter2@0.4.11, nopt@1.0.10, minimatch@0.2.12, glob@3.1.21, coffee-script@1.3.3, underscore.string@2.2.0rc, iconv-lite@0.2.8, lodash@0.9.2, findup-sync@0.1.2, js-yaml@2.0.5)
└── grunt-contrib-clean@0.4.1
这个是已经安装完成了吧?
我再执行spm chaos-build -h,命令行输出
: 没有那个文件或目录

可能是spm插件注册失败了,你试过用 npm 重新安装一下 spm-chaos-build 吗?

刚才就是重新安装的,因为提示: 没有那个文件或目录,所以我又装了一遍,复制过来的,结果还是不好使,纠结啊

你直接执行 spm 命令有输出吗?

root@GE:/home/spm-chaos-build-example/js# spm

Static Package Manager

Usage: spm [options]

Options:

-h, --help     output usage information
-V, --version  output the version number

System Commands:

plugin         plugin system for spm
config         configuration for spm
help           show help information

Package Commands:

tree           show dependencies tree
info           information of a module
login          login your account
search         search modules
install        install a module
publish        publish a module
unpublish      unpublish a module

Plugin Commands:

build          Build a standar cmd module.
deploy         deploy a module with scp.
chaos-build    Build SeaJS Business Modules by Chaos's way.

linux 系统?抱歉,之前只试过 win7 ,我找个 linux 机器试试

汗!node什么的还是Linux上使用感觉好一些,windows的cmd看着实在不舒服

恩,主要工作环境都是 win7 ,所以之前就没测 linux

我也是windows工作,然后搭个Linux虚拟机,把项目都在Linux上面跑,ssh加上samba,把Linux一隐藏,就和在windows下一样,用着也爽了

确实是会报这个错误,应该跟linux系统里面一些机制有关系,我再研究下,估计要明天才能给你答复了,抱歉

哦,没关系`~麻烦你了哈~~我不着急

OK了,已经解决了,你重新安装一下新版本就好了,新版本号是 0.1.10
原来是我犯了个低级错误,在 windows 下执行了 npm publish ,导致可执行文件的换行符是 \r\n ,在 linux 下无法识别

哈哈,好的,版本还升级了