1
0
mirror of https://github.com/kataras/iris.git synced 2026-01-08 20:41:57 +00:00

Fix and improve the iris cmd according to this: https://github.com/kataras/iris/issues/506

This commit is contained in:
Gerasimos Maropoulos
2016-10-23 07:20:39 +03:00
parent fc9cd0a8c2
commit 9958337e5d
8 changed files with 266 additions and 246 deletions

View File

@@ -2,12 +2,14 @@
This package is the command line tool for [../](https://github.com/kataras/iris).
[![Iris get command preview](https://raw.githubusercontent.com/iris-contrib/website/gh-pages/assets/iriscmd.gif)](https://raw.githubusercontent.com/iris-contrib/website/gh-pages/assets/iriscmd.gif)
[![Iris help screen](https://raw.githubusercontent.com/iris-contrib/website/gh-pages/assets/iris_cli_screen.png)](https://raw.githubusercontent.com/iris-contrib/website/gh-pages/assets/iris_cli_screen.png)
[![Iris installed screen](https://raw.githubusercontent.com/iris-contrib/website/gh-pages/assets/iris_cli_screen2.png)](https://raw.githubusercontent.com/iris-contrib/website/gh-pages/assets/iris_cli_screen2.png)
## Install
Current version: 0.0.9
```sh
go get -u github.com/kataras/iris/iris
@@ -24,38 +26,20 @@ $ iris [command] [-flags]
> Note that you must have $GOPATH/bin to your $PATH system/environment variable.
## create
## get
**The create command** creates for you a start project in a directory
**The get command** downloads, installs and runs a project based on a `prototype`, such as `basic`, `static` and `mongo` .
> These projects are located [online](https://github.com/iris-contrib/examples/tree/master/AIO_examples)
```sh
iris create -t basic -d myprojects/iris1
iris get mongo
```
Will create the [basic](https://github.com/iris-contrib/iris-command-assets/tree/master/basic) sample package to the `$GOPATH/src/myprojects/iris1` directory and run the app.
Downloads the [mongo](https://github.com/iris-contrib/examples/tree/master/AIO_examples/mongo) sample protoype project to the `$GOPATH/src/github.com/iris-contrib/examples` directory(the iris cmd will open this folder to you, automatically) builds, runs and watch for source code changes (hot-reload)
```sh
iris create -t static -d myprojects/iris1
```
Will create the [static](https://github.com/iris-contrib/iris-command-assets/tree/master/static) sample package to the `$GOPATH/src/myprojects/iris1` directory and run the app.
The default
```sh
iris create
```
Will create the basic sample package to `$GOPATH/src/myiris` directory and run the app.
```sh
iris create -d myproject
```
Will create the basic sample package to the `$GOPATH/src/myproject` folder and run the app.
## run