These are the Canner Command Line Interface (CLI) Tools
$ npm install -g canner-tools
canner --help lists the available commands and
canner <command> --help shows more details for and individual command.
login first before you start to use these commands.
|login||Log in to canner. Required before using other commands|
|logout||Log out from canner.|
|app:list||List all your apps their infos.|
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
|serve||This will serve the current folder. Before you upload statics files to app, you could use this command to confirm the result is correct.|
Upload the directories,
The file created when you use command
canner init. You can also create this manually.
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.schema.js/* global CannerTypes */moduleexports =home: CannerTypesobjectintro: CannerTypesdescription'介紹'description'首頁';
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.data.jsmoduleexports =home:intro: 'canner.data.js exports the data'
You can use
ImageService to uplaod image.
// canner.data.js/* global ImageService */moduleexports =home:backgroundImg: ImageService
If you use feature
auto upload image in
canner.data.js. This json file saves the
url of the uploaded images to prevent from uploading the duplicated images.
This json file saves the
checksum of the statics file to prevent from uploading the duplicated files.