{"action":"opened","issue":{"url":"https://api.github.com/repos/NEYouFan/nei-toolkit/issues/18","repository_url":"https://api.github.com/repos/NEYouFan/nei-toolkit","labels_url":"https://api.github.com/repos/NEYouFan/nei-toolkit/issues/18/labels{/name}","comments_url":"https://api.github.com/repos/NEYouFan/nei-toolkit/issues/18/comments","events_url":"https://api.github.com/repos/NEYouFan/nei-toolkit/issues/18/events","html_url":"https://github.com/NEYouFan/nei-toolkit/issues/18","id":156963928,"number":18,"title":"nei构建iOS工程时对参数namePrefix的统一处理","user":{"login":"agger0207","id":5696474,"avatar_url":"https://avatars.githubusercontent.com/u/5696474?v=3","gravatar_id":"","url":"https://api.github.com/users/agger0207","html_url":"https://github.com/agger0207","followers_url":"https://api.github.com/users/agger0207/followers","following_url":"https://api.github.com/users/agger0207/following{/other_user}","gists_url":"https://api.github.com/users/agger0207/gists{/gist_id}","starred_url":"https://api.github.com/users/agger0207/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/agger0207/subscriptions","organizations_url":"https://api.github.com/users/agger0207/orgs","repos_url":"https://api.github.com/users/agger0207/repos","events_url":"https://api.github.com/users/agger0207/events{/privacy}","received_events_url":"https://api.github.com/users/agger0207/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2016-05-26T11:36:41Z","updated_at":"2016-05-26T11:36:41Z","closed_at":null,"body":"当前nei构建工程时，对于文件前缀存在三个参数进行描述：\r\n\r\n1. 命令行或者build.json中通过参数`--namePrefix`指定的网络请求前缀；如果不指定，默认为HT;\r\n2. NEI_Key.json中指定的模板替换规则 \"Prefix\":\"XYZ\"会将工程模板中的{{Prefix}}替换成为指定的字符串\r\n3. NEI_Key.json中指定的模板替换规则\"CategoryPrefix\":\"xyz\"会将工程模板中的{{CategoryPrefix}}替换成为指定的字符串。\r\n\r\n使用者在构建自己的工程时，需要指定以上三个参数才可以正确生成自己想要的工程，不便于使用；因此希望toolkit改进如下：\r\n\r\n1. NEI_Key.json中不再需要指定Prefix或者CategoryPrefix；\r\n2. 即使在NEI_Key.json中指定了Prefix或者CategoryPrefix, 一概忽略；\r\n3. 通过`--namePrefix`传递的参数默认替换掉{{Prefix}}, 并且以小写形式替换掉{{CategoryPrefix}}; 则用户只需要传递一个参数.\r\n4. 如果没有传递`--namePrefix`参数，直接报错，不继续执行。\r\n5. nei mobile如果没有传递`--namePrefix`参数，也直接报错，不继续执行；即不再提供默认的`HT`前缀；\r\n\r\n例如：\r\n\r\n--namePrefix HTE, 则使用`HTE`替换掉模板文件中的{{Prefix}}, 使用`hte`替换掉模板文件中的{{CategoryPrefix}}.\r\n"}}
{"actor":{"display_login":"agger0207"}}