{"action":"created","issue":{"url":"https://api.github.com/repos/NativeScript/nativescript-cli/issues/1218","labels_url":"https://api.github.com/repos/NativeScript/nativescript-cli/issues/1218/labels{/name}","comments_url":"https://api.github.com/repos/NativeScript/nativescript-cli/issues/1218/comments","events_url":"https://api.github.com/repos/NativeScript/nativescript-cli/issues/1218/events","html_url":"https://github.com/NativeScript/nativescript-cli/pull/1218","id":117804844,"number":1218,"title":"Add support for different templates","user":{"login":"rosen-vladimirov","id":8351653,"avatar_url":"https://avatars.githubusercontent.com/u/8351653?v=3","gravatar_id":"","url":"https://api.github.com/users/rosen-vladimirov","html_url":"https://github.com/rosen-vladimirov","followers_url":"https://api.github.com/users/rosen-vladimirov/followers","following_url":"https://api.github.com/users/rosen-vladimirov/following{/other_user}","gists_url":"https://api.github.com/users/rosen-vladimirov/gists{/gist_id}","starred_url":"https://api.github.com/users/rosen-vladimirov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rosen-vladimirov/subscriptions","organizations_url":"https://api.github.com/users/rosen-vladimirov/orgs","repos_url":"https://api.github.com/users/rosen-vladimirov/repos","events_url":"https://api.github.com/users/rosen-vladimirov/events{/privacy}","received_events_url":"https://api.github.com/users/rosen-vladimirov/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/NativeScript/nativescript-cli/labels/feature","name":"feature","color":"84b6eb"}],"state":"open","locked":false,"assignee":{"login":"rosen-vladimirov","id":8351653,"avatar_url":"https://avatars.githubusercontent.com/u/8351653?v=3","gravatar_id":"","url":"https://api.github.com/users/rosen-vladimirov","html_url":"https://github.com/rosen-vladimirov","followers_url":"https://api.github.com/users/rosen-vladimirov/followers","following_url":"https://api.github.com/users/rosen-vladimirov/following{/other_user}","gists_url":"https://api.github.com/users/rosen-vladimirov/gists{/gist_id}","starred_url":"https://api.github.com/users/rosen-vladimirov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rosen-vladimirov/subscriptions","organizations_url":"https://api.github.com/users/rosen-vladimirov/orgs","repos_url":"https://api.github.com/users/rosen-vladimirov/repos","events_url":"https://api.github.com/users/rosen-vladimirov/events{/privacy}","received_events_url":"https://api.github.com/users/rosen-vladimirov/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/NativeScript/nativescript-cli/milestones/27","html_url":"https://github.com/NativeScript/nativescript-cli/milestones/1.6.0%20(Under%20consideration)","labels_url":"https://api.github.com/repos/NativeScript/nativescript-cli/milestones/27/labels","id":1338575,"number":27,"title":"1.6.0 (Under consideration)","description":"","creator":{"login":"teobugslayer","id":5443453,"avatar_url":"https://avatars.githubusercontent.com/u/5443453?v=3","gravatar_id":"","url":"https://api.github.com/users/teobugslayer","html_url":"https://github.com/teobugslayer","followers_url":"https://api.github.com/users/teobugslayer/followers","following_url":"https://api.github.com/users/teobugslayer/following{/other_user}","gists_url":"https://api.github.com/users/teobugslayer/gists{/gist_id}","starred_url":"https://api.github.com/users/teobugslayer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/teobugslayer/subscriptions","organizations_url":"https://api.github.com/users/teobugslayer/orgs","repos_url":"https://api.github.com/users/teobugslayer/repos","events_url":"https://api.github.com/users/teobugslayer/events{/privacy}","received_events_url":"https://api.github.com/users/teobugslayer/received_events","type":"User","site_admin":false},"open_issues":31,"closed_issues":2,"state":"open","created_at":"2015-10-05T16:14:56Z","updated_at":"2015-11-30T11:18:37Z","due_on":null,"closed_at":null},"comments":6,"created_at":"2015-11-19T12:33:32Z","updated_at":"2015-11-30T13:15:49Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/NativeScript/nativescript-cli/pulls/1218","html_url":"https://github.com/NativeScript/nativescript-cli/pull/1218","diff_url":"https://github.com/NativeScript/nativescript-cli/pull/1218.diff","patch_url":"https://github.com/NativeScript/nativescript-cli/pull/1218.patch"},"body":"Add support for --template option when creating new project.\r\nThe value for `--template` can be anything that you can `npm install`. For example valid calls are:\r\n* `tns create app1 --template tns-template-hello-world`\r\n* `tns create app1 --template https://github.com/NativeScript/template-hello-world-ts/tarball/master`\r\n* `tns create app1 --template ../myTemplate`\r\n* `tns create app1 --template https://github.com/NativeScript/template-hello-world-ts.git`\r\n* `tns create app1 --template https://github.com/NativeScript/template-hello-world-ts.git#master`\r\n\r\nIn case you use:\r\n`tns create app1 --template typescript` or `tns create app1 --template tsc`, CLI will try to install `tns-template-hello-world-ts` template.\r\nIn case you use `tns create app1 --template typescript@1.2.0` we will install version 1.2.0 of `tns-template-hello-world-ts`.\r\n\r\nWhen a custom template is used, CLI will extend its App_Resources with the ones from default template in case any of them is missing.\r\n\r\n> NOTE: Updating npm version to latest 2.x as our current version (2.6.1) fails when trying to execute: `npm install https://github.com/nativescript/template-hello-world.git`\r\n```\r\nnpm ERR! fetch failed https://github.com/nativescript/template-hello-world.git\r\nnpm WARN retry will retry, error on last attempt: Error: fetch failed with status code 406\r\nnpm ERR! fetch failed https://github.com/nativescript/template-hello-world.git\r\nnpm WARN retry will retry, error on last attempt: Error: fetch failed with status code 406\r\n```\r\n\r\nImplements https://github.com/NativeScript/nativescript-cli/issues/374 "},"comment":{"url":"https://api.github.com/repos/NativeScript/nativescript-cli/issues/comments/160624202","html_url":"https://github.com/NativeScript/nativescript-cli/pull/1218#issuecomment-160624202","issue_url":"https://api.github.com/repos/NativeScript/nativescript-cli/issues/1218","id":160624202,"user":{"login":"teobugslayer","id":5443453,"avatar_url":"https://avatars.githubusercontent.com/u/5443453?v=3","gravatar_id":"","url":"https://api.github.com/users/teobugslayer","html_url":"https://github.com/teobugslayer","followers_url":"https://api.github.com/users/teobugslayer/followers","following_url":"https://api.github.com/users/teobugslayer/following{/other_user}","gists_url":"https://api.github.com/users/teobugslayer/gists{/gist_id}","starred_url":"https://api.github.com/users/teobugslayer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/teobugslayer/subscriptions","organizations_url":"https://api.github.com/users/teobugslayer/orgs","repos_url":"https://api.github.com/users/teobugslayer/repos","events_url":"https://api.github.com/users/teobugslayer/events{/privacy}","received_events_url":"https://api.github.com/users/teobugslayer/received_events","type":"User","site_admin":false},"created_at":"2015-11-30T13:15:49Z","updated_at":"2015-11-30T13:15:49Z","body":":+1: "}}