Skip to content

Commit

Permalink
fix(docs): missing file
Browse files Browse the repository at this point in the history
  • Loading branch information
mkucharz committed Dec 27, 2017
1 parent ba65686 commit 66f17ee
Showing 1 changed file with 40 additions and 0 deletions.
40 changes: 40 additions & 0 deletions docs/cookbook/web/deployment/create-project-template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
# Creating your own project template

* Preparation time: **3 minutes**

### Create template

Check out `syncano-node` repository:

```sh
git clone [email protected]:Syncano/syncano-node.git
```

Then create your own template repository and copy empty template:

```sh
# syncano-template-project-<your own name of the template>
cp -r syncano-node/packages/template-project-hello syncano-template-project-my-template
```

Now you can start editing template configuration file `syncano-template-project-my-template/package.json`:
- edit name of the package
- edit template files in `syncano-template-project-my-template/template` folder

### Using template

You can install your template locally in you project. To do that go to your project folder and run:

```sh
# yarn add --dev <path to template>
yarn add --dev ../syncano-template-project-my-template
```

If you template was submitted to [NPM](https://www.npm.com) you can install it as any other dependency:

```sh
# yarn add --dev <name of the template>
yarn add --dev syncano-template-project-my-template
```

Now you will be able to find your template on the list of templates while executing `syncano-cli init` command.

0 comments on commit 66f17ee

Please sign in to comment.