diff --git a/HELP.md b/HELP.md index ef239f5c..663acf5c 100644 --- a/HELP.md +++ b/HELP.md @@ -95,6 +95,7 @@ Cloud Commander supports command line parameters: | `--vim` | enable vim hot keys | `--keys-panel` | show keys panel | `--columns` | set visible columns +| `--cache` | enable cache | `--no-server` | do not start server | `--no-auth` | disable authorization | `--no-online` | load scripts from local server @@ -113,6 +114,7 @@ Cloud Commander supports command line parameters: | `--no-vim` | disable vim hot keys | `--no-keys-panel` | hide keys panel | `--no-columns` | set visible default columns +| `--no-cache` | disable cache If no parameters given Cloud Commander reads information from `~/.cloudcmd.json` and use port from it (`8000` default). if port variables `PORT` or `VCAP_APP_PORT` isn't exist. @@ -365,7 +367,7 @@ Here is description of options: "dirStorage" : true, /* store directory listing to localStorage */ "online" : true, /* load js files from cdn or local path */ "open" : false /* open web browser when server started */ - "cache" : true, /* add cache-control */ + "cache" : true, /* enable cache */ "keysPanel" : true, /* show classic panel with buttons of keys */ "port" : 8000, /* http port */ "ip" : null, /* ip or null(default) */ diff --git a/app.json b/app.json index 8a71c68e..3e8db9c4 100644 --- a/app.json +++ b/app.json @@ -111,6 +111,11 @@ "description": "confirm move", "value": "true", "required": false + }, + "CLOUDCMD_CACHE": { + "description": "enable cache", + "value": "true", + "required": false } } } diff --git a/bin/cloudcmd.js b/bin/cloudcmd.js index 4a985c04..01c5e4ce 100755 --- a/bin/cloudcmd.js +++ b/bin/cloudcmd.js @@ -33,6 +33,7 @@ const args = require('minimist')(argv.slice(2), { ], boolean: [ 'auth', + 'cache', 'repl', 'save', 'server', @@ -56,6 +57,7 @@ const args = require('minimist')(argv.slice(2), { server : true, name : choose(env('name'), config('name')), auth : choose(env('auth'), config('auth')), + cache : choose(env.bool('cache'), config('cache')), port : config('port'), online : config('online'), open : config('open'), @@ -113,6 +115,7 @@ function main() { config('name', args.name); config('auth', args.auth); + config('cache', args.cache); config('online', args.online); config('open', args.open); config('username', args.username); diff --git a/json/help.json b/json/help.json index f3078ed0..0e573346 100644 --- a/json/help.json +++ b/json/help.json @@ -29,6 +29,7 @@ "--vim ": "enable vim hot keys", "--columns ": "set visible columns", "--keys-panel ": "show keys panel", + "--cache ": "enable cache", "--no-server ": "do not start server", "--no-auth ": "disable authorization", "--no-online ": "load scripts from local server", @@ -46,5 +47,6 @@ "--no-terminal ": "disable terminal", "--no-vim ": "disable vim hot keys", "--no-keys-panel ": "hide keys panel", - "--no-columns ": "set default visible columns" + "--no-columns ": "set default visible columns", + "--no-cache ": "disable cache" } diff --git a/man/cloudcmd.1 b/man/cloudcmd.1 index a60c5225..e79afee4 100644 --- a/man/cloudcmd.1 +++ b/man/cloudcmd.1 @@ -52,6 +52,7 @@ programs in browser from any computer, mobile or tablet device. --vim enable vim hot keys --columns set visible columns --keys-panel show keys panel + --cache enable cache --no-auth disable authorization --no-server do not start server --no-online load scripts from local server @@ -70,6 +71,7 @@ programs in browser from any computer, mobile or tablet device. --no-vim disable vim hot keys --no-columns set visible default columns --no-keys-panel hide keys panel + --no-cache disable cache .SH RESOURCES AND DOCUMENTATION