@cloudbase/cloudbase-mcp 1.8.22 → 1.8.23
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/cli.cjs +3 -3
- package/dist/index.cjs +3 -3
- package/dist/index.js +1 -1
- package/package.json +1 -1
- package/dist/440.cli.cjs +0 -1
- package/dist/440.index.cjs +0 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cloudbase/cloudbase-mcp",
|
|
3
|
-
"version": "1.8.
|
|
3
|
+
"version": "1.8.23",
|
|
4
4
|
"description": "腾讯云开发 MCP Server,通过AI提示词和MCP协议+云开发,让开发更智能、更高效,当你在Cursor/ VSCode GitHub Copilot/WinSurf/CodeBuddy/Augment Code/Claude Code等AI编程工具里写代码时,它能自动帮你生成可直接部署的前后端应用+小程序,并一键发布到腾讯云开发 CloudBase。",
|
|
5
5
|
"main": "./dist/index.cjs",
|
|
6
6
|
"module": "./dist/index.js",
|
package/dist/440.cli.cjs
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";exports.id=440,exports.ids=[440],exports.modules={83440:(e,r,o)=>{o.r(r),o.d(r,{apps:()=>k,default:()=>O,openApp:()=>$});var t=o(81329),n=o(6258),i=o(26743),a=o(42413),s=o(3776),c=o(60636),l=o(94658),m=o(81258),p=o(89971);let d,f;function u(){return void 0===f&&(f=(()=>{try{return p.statSync("/run/.containerenv"),!0}catch{return!1}})()||(void 0===d&&(d=function(){try{return p.statSync("/.dockerenv"),!0}catch{return!1}}()||function(){try{return p.readFileSync("/proc/self/cgroup","utf8").includes("docker")}catch{return!1}}()),d)),f}const w=()=>{if("linux"!==t.platform)return!1;if(m.release().toLowerCase().includes("microsoft"))return!u();try{return!!p.readFileSync("/proc/version","utf8").toLowerCase().includes("microsoft")&&!u()}catch{return!1}},g=t.env.__IS_WSL_TEST__?w:w(),h=(()=>{const e="/mnt/";let r;return async function(){if(r)return r;const o="/etc/wsl.conf";let t=!1;try{await l.access(o,l.constants.F_OK),t=!0}catch{}if(!t)return e;const n=await l.readFile(o,{encoding:"utf8"}),i=/(?<!#.*)root\s*=\s*(?<mountPoint>.*)/g.exec(n);return i?(r=i.groups.mountPoint.trim(),r=r.endsWith("/")?r:`${r}/`,r):e}})(),x=async()=>g?(async()=>`${await h()}c/Windows/System32/WindowsPowerShell/v1.0/powershell.exe`)():`${t.env.SYSTEMROOT||t.env.windir||String.raw`C:\Windows`}\\System32\\WindowsPowerShell\\v1.0\\powershell.exe`;function y(e,r,o){const t=o=>Object.defineProperty(e,r,{value:o,enumerable:!0,writable:!0});return Object.defineProperty(e,r,{configurable:!0,enumerable:!0,get(){const e=o();return t(e),e},set(e){t(e)}}),e}const v=(0,s.promisify)(c.execFile),b=(0,s.promisify)(c.execFile);async function S(e){return async function(e,{humanReadableOutput:r=!0}={}){if("darwin"!==t.platform)throw new Error("macOS only");const o=r?[]:["-ss"],{stdout:n}=await b("osascript",["-e",e,o]);return n.trim()}(`tell application "Finder" to set app_path to application file id "${e}" as string\ntell application "System Events" to get value of property list item "CFBundleName" of property list file (app_path & ":Contents:Info.plist")`)}const E=(0,s.promisify)(c.execFile),P={AppXq0fevzme2pys62n3e0fbqa7peapykr8v:{name:"Edge",id:"com.microsoft.edge.old"},MSEdgeDHTML:{name:"Edge",id:"com.microsoft.edge"},MSEdgeHTM:{name:"Edge",id:"com.microsoft.edge"},"IE.HTTP":{name:"Internet Explorer",id:"com.microsoft.ie"},FirefoxURL:{name:"Firefox",id:"org.mozilla.firefox"},ChromeHTML:{name:"Chrome",id:"com.google.chrome"},BraveHTML:{name:"Brave",id:"com.brave.Browser"},BraveBHTML:{name:"Brave Beta",id:"com.brave.Browser.beta"},BraveSSHTM:{name:"Brave Nightly",id:"com.brave.Browser.nightly"}};class A extends Error{}const B=(0,s.promisify)(c.execFile);const F=(0,s.promisify)(c.execFile),C=i.dirname((0,a.fileURLToPath)("file:///Users/bookerzhao/Projects/cloudbase-turbo-delploy/mcp/node_modules/open/index.js")),L=i.join(C,"xdg-open"),{platform:T,arch:M}=t,H=async(e,r)=>{let o;for(const t of e)try{return await r(t)}catch(e){o=e}throw o},U=async e=>{if(e={wait:!1,background:!1,newInstance:!1,allowNonzeroExitCode:!1,...e},Array.isArray(e.app))return H(e.app,r=>U({...e,app:r}));let r,{name:o,arguments:i=[]}=e.app??{};if(i=[...i],Array.isArray(o))return H(o,r=>U({...e,app:{name:r,arguments:i}}));if("browser"===o||"browserPrivate"===o){const r={"com.google.chrome":"chrome","google-chrome.desktop":"chrome","com.brave.Browser":"brave","org.mozilla.firefox":"firefox","firefox.desktop":"firefox","com.microsoft.msedge":"edge","com.microsoft.edge":"edge","com.microsoft.edgemac":"edge","microsoft-edge.desktop":"edge"},a={chrome:"--incognito",brave:"--incognito",firefox:"--private-window",edge:"--inPrivate"},s=g?await async function(){const e=await x(),r=String.raw`(Get-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\Shell\Associations\UrlAssociations\http\UserChoice").ProgId`,o=n.Buffer.from(r,"utf16le").toString("base64"),{stdout:t}=await F(e,["-NoProfile","-NonInteractive","-ExecutionPolicy","Bypass","-EncodedCommand",o],{encoding:"utf8"}),i=t.trim(),a={ChromeHTML:"com.google.chrome",BraveHTML:"com.brave.Browser",MSEdgeHTM:"com.microsoft.edge",FirefoxURL:"org.mozilla.firefox"};return a[i]?{id:a[i]}:{}}():await async function(){if("darwin"===t.platform){const e=await async function(){if("darwin"!==t.platform)throw new Error("macOS only");const{stdout:e}=await v("defaults",["read","com.apple.LaunchServices/com.apple.launchservices.secure","LSHandlers"]),r=/LSHandlerRoleAll = "(?!-)(?<id>[^"]+?)";\s+?LSHandlerURLScheme = (?:http|https);/.exec(e);return r?.groups.id??"com.apple.Safari"}();return{name:await S(e),id:e}}if("linux"===t.platform){const{stdout:e}=await B("xdg-mime",["query","default","x-scheme-handler/http"]),r=e.trim();return{name:r.replace(/.desktop$/,"").replace("-"," ").toLowerCase().replaceAll(/(?:^|\s|-)\S/g,e=>e.toUpperCase()),id:r}}if("win32"===t.platform)return async function(e=E){const{stdout:r}=await e("reg",["QUERY"," HKEY_CURRENT_USER\\Software\\Microsoft\\Windows\\Shell\\Associations\\UrlAssociations\\http\\UserChoice","/v","ProgId"]),o=/ProgId\s*REG_SZ\s*(?<id>\S+)/.exec(r);if(!o)throw new A(`Cannot find Windows browser in stdout: ${JSON.stringify(r)}`);const{id:t}=o.groups,n=P[t];if(!n)throw new A(`Unknown browser ID: ${t}`);return n}();throw new Error("Only macOS, Linux, and Windows are supported")}();if(s.id in r){const t=r[s.id];return"browserPrivate"===o&&i.push(a[t]),U({...e,app:{name:k[t],arguments:i}})}throw new Error(`${s.name} is not supported as a default browser`)}const a=[],s={};if("darwin"===T)r="open",e.wait&&a.push("--wait-apps"),e.background&&a.push("--background"),e.newInstance&&a.push("--new"),o&&a.push("-a",o);else if("win32"===T||g&&!u()&&!o){r=await x(),a.push("-NoProfile","-NonInteractive","-ExecutionPolicy","Bypass","-EncodedCommand"),g||(s.windowsVerbatimArguments=!0);const t=["Start"];e.wait&&t.push("-Wait"),o?(t.push(`"\`"${o}\`""`),e.target&&i.push(e.target)):e.target&&t.push(`"${e.target}"`),i.length>0&&(i=i.map(e=>`"\`"${e}\`""`),t.push("-ArgumentList",i.join(","))),e.target=n.Buffer.from(t.join(" "),"utf16le").toString("base64")}else{if(o)r=o;else{const e=!C||"/"===C;let o=!1;try{await l.access(L,l.constants.X_OK),o=!0}catch{}r=t.versions.electron??("android"===T||e||!o)?"xdg-open":L}i.length>0&&a.push(...i),e.wait||(s.stdio="ignore",s.detached=!0)}"darwin"===T&&i.length>0&&a.push("--args",...i),e.target&&a.push(e.target);const m=c.spawn(r,a,s);return e.wait?new Promise((r,o)=>{m.once("error",o),m.once("close",t=>{!e.allowNonzeroExitCode&&t>0?o(new Error(`Exited with code ${t}`)):r(m)})}):(m.unref(),m)},$=(e,r)=>{if("string"!=typeof e&&!Array.isArray(e))throw new TypeError("Expected a valid `name`");const{arguments:o=[]}=r??{};if(null!=o&&!Array.isArray(o))throw new TypeError("Expected `appArguments` as Array type");return U({...r,app:{name:e,arguments:o}})};function _(e){if("string"==typeof e||Array.isArray(e))return e;const{[M]:r}=e;if(!r)throw new Error(`${M} is not supported`);return r}function I({[T]:e},{wsl:r}){if(r&&g)return _(r);if(!e)throw new Error(`${T} is not supported`);return _(e)}const k={};y(k,"chrome",()=>I({darwin:"google chrome",win32:"chrome",linux:["google-chrome","google-chrome-stable","chromium"]},{wsl:{ia32:"/mnt/c/Program Files (x86)/Google/Chrome/Application/chrome.exe",x64:["/mnt/c/Program Files/Google/Chrome/Application/chrome.exe","/mnt/c/Program Files (x86)/Google/Chrome/Application/chrome.exe"]}})),y(k,"brave",()=>I({darwin:"brave browser",win32:"brave",linux:["brave-browser","brave"]},{wsl:{ia32:"/mnt/c/Program Files (x86)/BraveSoftware/Brave-Browser/Application/brave.exe",x64:["/mnt/c/Program Files/BraveSoftware/Brave-Browser/Application/brave.exe","/mnt/c/Program Files (x86)/BraveSoftware/Brave-Browser/Application/brave.exe"]}})),y(k,"firefox",()=>I({darwin:"firefox",win32:String.raw`C:\Program Files\Mozilla Firefox\firefox.exe`,linux:"firefox"},{wsl:"/mnt/c/Program Files/Mozilla Firefox/firefox.exe"})),y(k,"edge",()=>I({darwin:"microsoft edge",win32:"msedge",linux:["microsoft-edge","microsoft-edge-dev"]},{wsl:"/mnt/c/Program Files (x86)/Microsoft/Edge/Application/msedge.exe"})),y(k,"browser",()=>"browser"),y(k,"browserPrivate",()=>"browserPrivate");const O=(e,r)=>{if("string"!=typeof e)throw new TypeError("Expected a `target`");return U({...r,target:e})}}};
|
package/dist/440.index.cjs
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";exports.id=440,exports.ids=[440],exports.modules={83440:(e,r,o)=>{o.r(r),o.d(r,{apps:()=>k,default:()=>O,openApp:()=>$});var t=o(81329),n=o(6258),i=o(26743),a=o(42413),s=o(3776),c=o(60636),l=o(94658),m=o(81258),p=o(89971);let d,f;function u(){return void 0===f&&(f=(()=>{try{return p.statSync("/run/.containerenv"),!0}catch{return!1}})()||(void 0===d&&(d=function(){try{return p.statSync("/.dockerenv"),!0}catch{return!1}}()||function(){try{return p.readFileSync("/proc/self/cgroup","utf8").includes("docker")}catch{return!1}}()),d)),f}const w=()=>{if("linux"!==t.platform)return!1;if(m.release().toLowerCase().includes("microsoft"))return!u();try{return!!p.readFileSync("/proc/version","utf8").toLowerCase().includes("microsoft")&&!u()}catch{return!1}},g=t.env.__IS_WSL_TEST__?w:w(),h=(()=>{const e="/mnt/";let r;return async function(){if(r)return r;const o="/etc/wsl.conf";let t=!1;try{await l.access(o,l.constants.F_OK),t=!0}catch{}if(!t)return e;const n=await l.readFile(o,{encoding:"utf8"}),i=/(?<!#.*)root\s*=\s*(?<mountPoint>.*)/g.exec(n);return i?(r=i.groups.mountPoint.trim(),r=r.endsWith("/")?r:`${r}/`,r):e}})(),x=async()=>g?(async()=>`${await h()}c/Windows/System32/WindowsPowerShell/v1.0/powershell.exe`)():`${t.env.SYSTEMROOT||t.env.windir||String.raw`C:\Windows`}\\System32\\WindowsPowerShell\\v1.0\\powershell.exe`;function y(e,r,o){const t=o=>Object.defineProperty(e,r,{value:o,enumerable:!0,writable:!0});return Object.defineProperty(e,r,{configurable:!0,enumerable:!0,get(){const e=o();return t(e),e},set(e){t(e)}}),e}const v=(0,s.promisify)(c.execFile),b=(0,s.promisify)(c.execFile);async function S(e){return async function(e,{humanReadableOutput:r=!0}={}){if("darwin"!==t.platform)throw new Error("macOS only");const o=r?[]:["-ss"],{stdout:n}=await b("osascript",["-e",e,o]);return n.trim()}(`tell application "Finder" to set app_path to application file id "${e}" as string\ntell application "System Events" to get value of property list item "CFBundleName" of property list file (app_path & ":Contents:Info.plist")`)}const E=(0,s.promisify)(c.execFile),P={AppXq0fevzme2pys62n3e0fbqa7peapykr8v:{name:"Edge",id:"com.microsoft.edge.old"},MSEdgeDHTML:{name:"Edge",id:"com.microsoft.edge"},MSEdgeHTM:{name:"Edge",id:"com.microsoft.edge"},"IE.HTTP":{name:"Internet Explorer",id:"com.microsoft.ie"},FirefoxURL:{name:"Firefox",id:"org.mozilla.firefox"},ChromeHTML:{name:"Chrome",id:"com.google.chrome"},BraveHTML:{name:"Brave",id:"com.brave.Browser"},BraveBHTML:{name:"Brave Beta",id:"com.brave.Browser.beta"},BraveSSHTM:{name:"Brave Nightly",id:"com.brave.Browser.nightly"}};class A extends Error{}const B=(0,s.promisify)(c.execFile);const F=(0,s.promisify)(c.execFile),C=i.dirname((0,a.fileURLToPath)("file:///Users/bookerzhao/Projects/cloudbase-turbo-delploy/mcp/node_modules/open/index.js")),L=i.join(C,"xdg-open"),{platform:T,arch:M}=t,H=async(e,r)=>{let o;for(const t of e)try{return await r(t)}catch(e){o=e}throw o},U=async e=>{if(e={wait:!1,background:!1,newInstance:!1,allowNonzeroExitCode:!1,...e},Array.isArray(e.app))return H(e.app,r=>U({...e,app:r}));let r,{name:o,arguments:i=[]}=e.app??{};if(i=[...i],Array.isArray(o))return H(o,r=>U({...e,app:{name:r,arguments:i}}));if("browser"===o||"browserPrivate"===o){const r={"com.google.chrome":"chrome","google-chrome.desktop":"chrome","com.brave.Browser":"brave","org.mozilla.firefox":"firefox","firefox.desktop":"firefox","com.microsoft.msedge":"edge","com.microsoft.edge":"edge","com.microsoft.edgemac":"edge","microsoft-edge.desktop":"edge"},a={chrome:"--incognito",brave:"--incognito",firefox:"--private-window",edge:"--inPrivate"},s=g?await async function(){const e=await x(),r=String.raw`(Get-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\Shell\Associations\UrlAssociations\http\UserChoice").ProgId`,o=n.Buffer.from(r,"utf16le").toString("base64"),{stdout:t}=await F(e,["-NoProfile","-NonInteractive","-ExecutionPolicy","Bypass","-EncodedCommand",o],{encoding:"utf8"}),i=t.trim(),a={ChromeHTML:"com.google.chrome",BraveHTML:"com.brave.Browser",MSEdgeHTM:"com.microsoft.edge",FirefoxURL:"org.mozilla.firefox"};return a[i]?{id:a[i]}:{}}():await async function(){if("darwin"===t.platform){const e=await async function(){if("darwin"!==t.platform)throw new Error("macOS only");const{stdout:e}=await v("defaults",["read","com.apple.LaunchServices/com.apple.launchservices.secure","LSHandlers"]),r=/LSHandlerRoleAll = "(?!-)(?<id>[^"]+?)";\s+?LSHandlerURLScheme = (?:http|https);/.exec(e);return r?.groups.id??"com.apple.Safari"}();return{name:await S(e),id:e}}if("linux"===t.platform){const{stdout:e}=await B("xdg-mime",["query","default","x-scheme-handler/http"]),r=e.trim();return{name:r.replace(/.desktop$/,"").replace("-"," ").toLowerCase().replaceAll(/(?:^|\s|-)\S/g,e=>e.toUpperCase()),id:r}}if("win32"===t.platform)return async function(e=E){const{stdout:r}=await e("reg",["QUERY"," HKEY_CURRENT_USER\\Software\\Microsoft\\Windows\\Shell\\Associations\\UrlAssociations\\http\\UserChoice","/v","ProgId"]),o=/ProgId\s*REG_SZ\s*(?<id>\S+)/.exec(r);if(!o)throw new A(`Cannot find Windows browser in stdout: ${JSON.stringify(r)}`);const{id:t}=o.groups,n=P[t];if(!n)throw new A(`Unknown browser ID: ${t}`);return n}();throw new Error("Only macOS, Linux, and Windows are supported")}();if(s.id in r){const t=r[s.id];return"browserPrivate"===o&&i.push(a[t]),U({...e,app:{name:k[t],arguments:i}})}throw new Error(`${s.name} is not supported as a default browser`)}const a=[],s={};if("darwin"===T)r="open",e.wait&&a.push("--wait-apps"),e.background&&a.push("--background"),e.newInstance&&a.push("--new"),o&&a.push("-a",o);else if("win32"===T||g&&!u()&&!o){r=await x(),a.push("-NoProfile","-NonInteractive","-ExecutionPolicy","Bypass","-EncodedCommand"),g||(s.windowsVerbatimArguments=!0);const t=["Start"];e.wait&&t.push("-Wait"),o?(t.push(`"\`"${o}\`""`),e.target&&i.push(e.target)):e.target&&t.push(`"${e.target}"`),i.length>0&&(i=i.map(e=>`"\`"${e}\`""`),t.push("-ArgumentList",i.join(","))),e.target=n.Buffer.from(t.join(" "),"utf16le").toString("base64")}else{if(o)r=o;else{const e=!C||"/"===C;let o=!1;try{await l.access(L,l.constants.X_OK),o=!0}catch{}r=t.versions.electron??("android"===T||e||!o)?"xdg-open":L}i.length>0&&a.push(...i),e.wait||(s.stdio="ignore",s.detached=!0)}"darwin"===T&&i.length>0&&a.push("--args",...i),e.target&&a.push(e.target);const m=c.spawn(r,a,s);return e.wait?new Promise((r,o)=>{m.once("error",o),m.once("close",t=>{!e.allowNonzeroExitCode&&t>0?o(new Error(`Exited with code ${t}`)):r(m)})}):(m.unref(),m)},$=(e,r)=>{if("string"!=typeof e&&!Array.isArray(e))throw new TypeError("Expected a valid `name`");const{arguments:o=[]}=r??{};if(null!=o&&!Array.isArray(o))throw new TypeError("Expected `appArguments` as Array type");return U({...r,app:{name:e,arguments:o}})};function _(e){if("string"==typeof e||Array.isArray(e))return e;const{[M]:r}=e;if(!r)throw new Error(`${M} is not supported`);return r}function I({[T]:e},{wsl:r}){if(r&&g)return _(r);if(!e)throw new Error(`${T} is not supported`);return _(e)}const k={};y(k,"chrome",()=>I({darwin:"google chrome",win32:"chrome",linux:["google-chrome","google-chrome-stable","chromium"]},{wsl:{ia32:"/mnt/c/Program Files (x86)/Google/Chrome/Application/chrome.exe",x64:["/mnt/c/Program Files/Google/Chrome/Application/chrome.exe","/mnt/c/Program Files (x86)/Google/Chrome/Application/chrome.exe"]}})),y(k,"brave",()=>I({darwin:"brave browser",win32:"brave",linux:["brave-browser","brave"]},{wsl:{ia32:"/mnt/c/Program Files (x86)/BraveSoftware/Brave-Browser/Application/brave.exe",x64:["/mnt/c/Program Files/BraveSoftware/Brave-Browser/Application/brave.exe","/mnt/c/Program Files (x86)/BraveSoftware/Brave-Browser/Application/brave.exe"]}})),y(k,"firefox",()=>I({darwin:"firefox",win32:String.raw`C:\Program Files\Mozilla Firefox\firefox.exe`,linux:"firefox"},{wsl:"/mnt/c/Program Files/Mozilla Firefox/firefox.exe"})),y(k,"edge",()=>I({darwin:"microsoft edge",win32:"msedge",linux:["microsoft-edge","microsoft-edge-dev"]},{wsl:"/mnt/c/Program Files (x86)/Microsoft/Edge/Application/msedge.exe"})),y(k,"browser",()=>"browser"),y(k,"browserPrivate",()=>"browserPrivate");const O=(e,r)=>{if("string"!=typeof e)throw new TypeError("Expected a `target`");return U({...r,target:e})}}};
|