0.3.18 • Published 7 years ago

@canner/canner-tools v0.3.18

Weekly downloads
1
License
Apache-2.0
Repository
-
Last release
7 years ago

canner-tools

These are the Canner Command Line Interface (CLI) Tools

Installation

$ npm install -g canner-tools

Usage

canner --help

Get Started

example

Commands

The command canner --help lists the available commands and canner <command> --help shows more details for and individual command.

Remeber to login first before you start to use these commands.

Administrative Commands

App Commands

Schema Commands

Data Commands

Statics Commands

You can use Canner to host your statics files, like html, css, js, image and etc. Just upload them to the app.

html files have to be placed in pages, and others in statics

  • pages
    • index.html
    • other.html
    • otherFolder
      • other1.html
  • statics
    • anyfiles

Files

.cannerrc

The file created when you use command canner init. You can also create this manually.

{
  "app": {
    "default": "<your app url>"
  }
}

canner.schema.js

This file declares the data info, and would be deploy when you use command canner schema:deploy. It's written with CannerTypes. To know more, you could read Canner Handbook

// canner.schema.js
/* global CannerTypes */
module.exports = {
  home: CannerTypes.object({
    intro: CannerTypes.string().description('介紹')
  }).description('首頁');
}

canner.data.js

This js file is the data you want to import to your app, would be imported when you use command canner data:import. To know more, you could read Canner Handbook

// canner.data.js
module.exports = {
  home: {
    intro: 'canner.data.js exports the data'
  }
}

You can use ImageService to uplaod image.

// canner.data.js
/* global ImageService */
module.exports = {
  home: {
    backgroundImg: ImageService.image('relative/path/to/img')
  }
}

.canner-image-uploaded.json

If you use feature auto upload image in canner.data.js. This json file saves the checksum and url of the uploaded images to prevent from uploading the duplicated images.

.canner-statics-uploaded.json

This json file saves the checksum of the statics file to prevent from uploading the duplicated files.

0.3.18

7 years ago

0.3.17

7 years ago

0.3.16

7 years ago

0.3.15

7 years ago

0.3.14

7 years ago

0.3.13

7 years ago

0.3.12

7 years ago

0.3.11

7 years ago

0.3.10

7 years ago

0.3.9

7 years ago

0.3.8

7 years ago

0.3.7

7 years ago

0.3.6

7 years ago

0.3.5

7 years ago

0.3.4

7 years ago

0.3.4-0

7 years ago

0.3.3

7 years ago

0.3.2

7 years ago

0.3.1

7 years ago

0.3.0

7 years ago

0.2.2

7 years ago

0.2.1

7 years ago

0.2.0

7 years ago

0.1.1

7 years ago

0.1.0

7 years ago

0.0.14

7 years ago

0.0.13

7 years ago

0.0.12

7 years ago

0.0.11

7 years ago

0.0.9

7 years ago

0.0.8

7 years ago

0.0.7

7 years ago

0.0.6

7 years ago

0.0.5

7 years ago

0.0.4

7 years ago

0.0.2

7 years ago

0.0.1

7 years ago