{"action":"opened","issue":{"url":"https://api.github.com/repos/hustxiaoc/gulp-kmc/issues/5","labels_url":"https://api.github.com/repos/hustxiaoc/gulp-kmc/issues/5/labels{/name}","comments_url":"https://api.github.com/repos/hustxiaoc/gulp-kmc/issues/5/comments","events_url":"https://api.github.com/repos/hustxiaoc/gulp-kmc/issues/5/events","html_url":"https://github.com/hustxiaoc/gulp-kmc/issues/5","id":86042981,"number":5,"title":"gulp server自动给不需要添加前缀的js文件添加了define等前缀","user":{"login":"astarring","id":3505708,"avatar_url":"https://avatars.githubusercontent.com/u/3505708?v=3","gravatar_id":"","url":"https://api.github.com/users/astarring","html_url":"https://github.com/astarring","followers_url":"https://api.github.com/users/astarring/followers","following_url":"https://api.github.com/users/astarring/following{/other_user}","gists_url":"https://api.github.com/users/astarring/gists{/gist_id}","starred_url":"https://api.github.com/users/astarring/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/astarring/subscriptions","organizations_url":"https://api.github.com/users/astarring/orgs","repos_url":"https://api.github.com/users/astarring/repos","events_url":"https://api.github.com/users/astarring/events{/privacy}","received_events_url":"https://api.github.com/users/astarring/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-06-08T06:09:48Z","updated_at":"2015-06-08T06:09:48Z","closed_at":null,"body":"当我用yo bee项目搭建起一个移动html5项目作为我的一个项目开发骨架的项目时，然后根据我自己的需求，我建立了如下的项目结构：\r\n```\r\n|-- bee-demo\r\n    |-- src (这个是作为我们的所有的源码根目录)\r\n        |-- js (我们所有的js模块都放在这里)\r\n            |-- m (我们所有自定义的模块)\r\n            |-- kissy (kissy等模块)\r\n        |-- css （css,less文件\r\n    |-- build\r\n    |-- node_modules\r\n```\r\n然后安装了您的gulp-kmc之后，在命令行中用gulp启动了gulp-kmc server之后\r\n```shell\r\n> gulp\r\n...\r\nkmc server running at 5555\r\n[08:56:20] Finished 'kmc' after 2.6 s\r\n[08:56:20] Starting 'default'...\r\n[08:56:20] Finished 'default' after 3.37 μs\r\n```\r\n我现在在我的html是这样的\r\n```html\r\n<html>\r\n<head>\r\n<script src=\"http://localhost:5555/bee-demo/js/kissy/k/1.4.10/seed.js\"></script>\r\n<script src=\"http://localhost:5555/bee-demo/js/m/my_own_module/index.js\"></script>\r\n</head>\r\n<body>\r\n....\r\n</body>\r\n</html>\r\n```\r\n\r\n然后我有以下问题：\r\n* 我们一些kissy，kissy的配置文件(KISSY.config)，slide.js等js，不需要添加模块化，但是kmc server无论如何，会给我们src目录下的文件添加头，比如：\r\n```javascript\r\nKISSY.add('h5/config',[],function(S ,require, exports, module) {\r\n KISSY.config({\r\n\tpackages: [\r\n        {\r\n            name: 'bee-demo',\r\n            base: '.',\r\n            ignorePackageNameInUri: true,\r\n            debug: true,\r\n            combine:false\r\n        }\r\n    ]\r\n});\r\n});\r\n```\r\n* 我们src目录下的文件更新了，kmc server并不会自己发现我的文件更新了，然后帮我自动build新的文件到build。这样我就不需要重新启动kmc server了。\r\n* 我们发现gulpfile.js里面有一个地方配置kmc server服务的配置\r\n```javascript\r\nkmc.config({\r\n    packages:[{\r\n        name: pkg,\r\n        base: src\r\n    }]\r\n});\r\n```\r\n我希望这个配置能和我们工程统一的KISSY.config一起来用，也就是当我在本地开发的时候这个配置是我们kmc server的包配置，同时也是我个的html的包配置。这样我们就可以像http://m.kissyui.com/docs/quickstart.html 那样只依赖于包名而不用完全依赖于文件所在的路径名来命名我们的Kissy模块的包名。\r\n"}}