cloudcmd 19.21.4 → 19.22.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist-dev/sw.js CHANGED
@@ -23,7 +23,7 @@ eval("{// shim for using process in browser\nvar process = module.exports = {};\
23
23
  \*************************/
24
24
  (__unused_rspack___webpack_module__, __webpack_exports__, __webpack_require__) {
25
25
  "use strict";
26
- eval("{__webpack_require__.r(__webpack_exports__);\n/* import */ var node_process__rspack_import_0 = __webpack_require__(/*! node:process */ \"./node_modules/process/browser.js\");\n/* import */ var try_to_catch__rspack_import_1 = __webpack_require__(/*! try-to-catch */ \"./node_modules/try-to-catch/lib/try-to-catch.js\");\n/* import */ var currify__rspack_import_2 = __webpack_require__(/*! currify */ \"./node_modules/currify/lib/currify.js\");\n\n\n\nconst isDev = \"development\" === 'development';\nconst isGet = a => a.method === 'GET';\nconst isBasic = a => a.type === 'basic';\nconst wait = currify__rspack_import_2((f, e) => e.waitUntil(f()));\nconst respondWith = currify__rspack_import_2((f, e) => {\n const {\n request\n } = e;\n const {\n url\n } = request;\n const pathname = getPathName(url);\n if (url.endsWith('/') || /\\^\\/fs/.test(pathname)) return;\n if (!isGet(request)) return;\n if (!isBasic(request)) return;\n if (pathname.startsWith('/api')) return;\n if (/^socket.io/.test(pathname)) return;\n e.respondWith(f(e));\n});\nconst getPathName = url => new URL(url).pathname;\nconst date = \"Sun Oct 25 2026 14:11:57 GMT+0200 (Eastern European Standard Time)\";\nconst NAME = `cloudcmd: ${date}`;\nconst createRequest = a => new Request(a, {\n credentials: 'same-origin'\n});\nconst getRequest = (a, request) => {\n if (a !== '/') return request;\n return createRequest('/');\n};\nglobalThis.addEventListener('install', wait(onInstall));\nglobalThis.addEventListener('fetch', respondWith(onFetch));\nglobalThis.addEventListener('activate', wait(onActivate));\nasync function onActivate() {\n console.info(`cloudcmd: sw: activate: ${NAME}`);\n await globalThis.clients.claim();\n const keys = await caches.keys();\n const deleteCache = caches.delete.bind(caches);\n await Promise.all(keys.map(deleteCache));\n}\nasync function onInstall() {\n console.info(`cloudcmd: sw: install: ${NAME}`);\n await globalThis.skipWaiting();\n}\nasync function onFetch(event) {\n const {\n request\n } = event;\n const {\n url\n } = request;\n const pathname = getPathName(url);\n const newRequest = getRequest(pathname, event.request);\n const cache = await caches.open(NAME);\n const response = await cache.match(request);\n if (!isDev && response) return response;\n const [e, resp] = await (0,try_to_catch__rspack_import_1.tryToCatch)(fetch, newRequest, {\n credentials: 'same-origin'\n });\n if (e) return new Response(e.message);\n await addToCache(request, resp.clone());\n return resp;\n}\nasync function addToCache(request, response) {\n const cache = await caches.open(NAME);\n return cache.put(request, response);\n}\n\n//# sourceURL=file://cloudcmd//Users/coderaiser/cloudcmd/client/sw/sw.js\n}");
26
+ eval("{__webpack_require__.r(__webpack_exports__);\n/* import */ var node_process__rspack_import_0 = __webpack_require__(/*! node:process */ \"./node_modules/process/browser.js\");\n/* import */ var try_to_catch__rspack_import_1 = __webpack_require__(/*! try-to-catch */ \"./node_modules/try-to-catch/lib/try-to-catch.js\");\n/* import */ var currify__rspack_import_2 = __webpack_require__(/*! currify */ \"./node_modules/currify/lib/currify.js\");\n\n\n\nconst isDev = \"development\" === 'development';\nconst isGet = a => a.method === 'GET';\nconst isBasic = a => a.type === 'basic';\nconst wait = currify__rspack_import_2((f, e) => e.waitUntil(f()));\nconst respondWith = currify__rspack_import_2((f, e) => {\n const {\n request\n } = e;\n const {\n url\n } = request;\n const pathname = getPathName(url);\n if (url.endsWith('/') || /\\^\\/fs/.test(pathname)) return;\n if (!isGet(request)) return;\n if (!isBasic(request)) return;\n if (pathname.startsWith('/api')) return;\n if (/^socket.io/.test(pathname)) return;\n e.respondWith(f(e));\n});\nconst getPathName = url => new URL(url).pathname;\nconst date = \"Sun Nov 08 2026 00:07:52 GMT+0200 (Eastern European Standard Time)\";\nconst NAME = `cloudcmd: ${date}`;\nconst createRequest = a => new Request(a, {\n credentials: 'same-origin'\n});\nconst getRequest = (a, request) => {\n if (a !== '/') return request;\n return createRequest('/');\n};\nglobalThis.addEventListener('install', wait(onInstall));\nglobalThis.addEventListener('fetch', respondWith(onFetch));\nglobalThis.addEventListener('activate', wait(onActivate));\nasync function onActivate() {\n console.info(`cloudcmd: sw: activate: ${NAME}`);\n await globalThis.clients.claim();\n const keys = await caches.keys();\n const deleteCache = caches.delete.bind(caches);\n await Promise.all(keys.map(deleteCache));\n}\nasync function onInstall() {\n console.info(`cloudcmd: sw: install: ${NAME}`);\n await globalThis.skipWaiting();\n}\nasync function onFetch(event) {\n const {\n request\n } = event;\n const {\n url\n } = request;\n const pathname = getPathName(url);\n const newRequest = getRequest(pathname, event.request);\n const cache = await caches.open(NAME);\n const response = await cache.match(request);\n if (!isDev && response) return response;\n const [e, resp] = await (0,try_to_catch__rspack_import_1.tryToCatch)(fetch, newRequest, {\n credentials: 'same-origin'\n });\n if (e) return new Response(e.message);\n await addToCache(request, resp.clone());\n return resp;\n}\nasync function addToCache(request, response) {\n const cache = await caches.open(NAME);\n return cache.put(request, response);\n}\n\n//# sourceURL=file://cloudcmd//Users/coderaiser/cloudcmd/client/sw/sw.js\n}");
27
27
 
28
28
  },
29
29
  "./node_modules/try-to-catch/lib/try-to-catch.js"
package/json/help.json CHANGED
@@ -20,7 +20,7 @@
20
20
  "--confirm-move ": "confirm move",
21
21
  "--open ": "open web browser when server started",
22
22
  "--name ": "set tab name in web browser",
23
- "--menu ": "set menu: \"supermenu\" or \"aleman\"",
23
+ "--menu ": "set menu: \"supermenu\", \"aleman\" or \"lunes\"",
24
24
  "--one-file-panel ": "show one file panel",
25
25
  "--keys-panel ": "show keys panel",
26
26
  "--config-dialog ": "enable config dialog",
package/man/cloudcmd.1 CHANGED
@@ -34,7 +34,7 @@ programs in browser from any computer, mobile or tablet device.
34
34
  --show-dot-files show dot files
35
35
  --show-file-name show file name in view and edit modes
36
36
  --editor set editor: "dword", "edward", "deepword" or "qword"
37
- --menu set menu: "supermenu" or "aleman"
37
+ --menu set menu: "supermenu", "aleman" or "lunes"
38
38
  --packer set packer: "tar" or "zip"
39
39
  --root set root directory
40
40
  --prefix set url prefix
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cloudcmd",
3
- "version": "19.21.4",
3
+ "version": "19.22.0",
4
4
  "type": "module",
5
5
  "author": "coderaiser <mnemonic.enemy@gmail.com> (https://github.com/coderaiser)",
6
6
  "description": "File manager for the web with console and editor",
@@ -168,7 +168,7 @@
168
168
  "@rspack/core": "^2.1.4",
169
169
  "@supertape/loader-css": "^1.0.0",
170
170
  "@types/node-fetch": "^2.6.11",
171
- "aleman": "^2.0.4",
171
+ "aleman": "^2.2.1",
172
172
  "auto-globals": "^4.0.0",
173
173
  "babel-loader": "^10.0.0",
174
174
  "babel-plugin-macros": "^3.0.0",
@@ -35,10 +35,10 @@ export const editor = (name, {exit = _exit} = {}) => {
35
35
  };
36
36
 
37
37
  export const menu = (name, {exit = _exit} = {}) => {
38
- const reg = /^(supermenu|aleman)$/;
38
+ const reg = /^(supermenu|aleman|lunes)$/;
39
39
 
40
40
  if (!reg.test(name))
41
- exit('cloudcmd --menu: could be "supermenu" or "aleman" only');
41
+ exit('cloudcmd --menu: could be "supermenu", "aleman" or "lunes" only');
42
42
  };
43
43
 
44
44
  export const packer = (name, {exit = _exit} = {}) => {
package/tmpl/config.hbs CHANGED
@@ -74,10 +74,11 @@
74
74
  Vim
75
75
  </label>
76
76
  </li>
77
- <li title="Menu: supermenu, aleman">
77
+ <li title="Menu: supermenu, aleman, lunes">
78
78
  <select data-name="js-menu" class="form-control full-width" title="Menu">
79
79
  <option {{ aleman-selected }}>aleman</option>
80
80
  <option {{ supermenu-selected }}>supermenu</option>
81
+ <option {{ lunes-selected }}>lunes</option>
81
82
  </select>
82
83
  </li>
83
84
  <li title="Inner buffer used to copy files">