create-cloudflare 0.0.0-9f7e547e → 0.0.0-a21acf82
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.js +16 -17
- package/package.json +2 -2
package/dist/cli.js
CHANGED
|
@@ -57864,7 +57864,7 @@ var Yargs = YargsFactory(esm_default);
|
|
|
57864
57864
|
var yargs_default = Yargs;
|
|
57865
57865
|
|
|
57866
57866
|
// package.json
|
|
57867
|
-
var version = "0.0.0-
|
|
57867
|
+
var version = "0.0.0-a21acf82";
|
|
57868
57868
|
var devDependencies = {
|
|
57869
57869
|
"@babel/parser": "^7.21.3",
|
|
57870
57870
|
"@babel/types": "^7.21.4",
|
|
@@ -58504,7 +58504,7 @@ async function openInBrowser(url) {
|
|
|
58504
58504
|
}
|
|
58505
58505
|
var C3_DEFAULTS = {
|
|
58506
58506
|
projectName: new import_haikunator.default().haikunate({ tokenHex: true }),
|
|
58507
|
-
type: "
|
|
58507
|
+
type: "webFramework",
|
|
58508
58508
|
framework: "angular",
|
|
58509
58509
|
autoUpdate: true,
|
|
58510
58510
|
deploy: true,
|
|
@@ -59871,10 +59871,12 @@ var detectPackageManager = () => {
|
|
|
59871
59871
|
case "pnpm":
|
|
59872
59872
|
name2 = "pnpm";
|
|
59873
59873
|
version3 = devDependencies["pnpm"].replace("^", "");
|
|
59874
|
+
process.env.npm_config_user_agent = "pnpm";
|
|
59874
59875
|
break;
|
|
59875
59876
|
case "yarn":
|
|
59876
59877
|
name2 = "yarn";
|
|
59877
59878
|
version3 = devDependencies["yarn"].replace("^", "");
|
|
59879
|
+
process.env.npm_config_user_agent = "yarn";
|
|
59878
59880
|
break;
|
|
59879
59881
|
case "bun":
|
|
59880
59882
|
name2 = "bun";
|
|
@@ -59883,6 +59885,7 @@ var detectPackageManager = () => {
|
|
|
59883
59885
|
case "npm":
|
|
59884
59886
|
name2 = "npm";
|
|
59885
59887
|
version3 = "0.0.0";
|
|
59888
|
+
process.env.npm_config_user_agent = "npm";
|
|
59886
59889
|
break;
|
|
59887
59890
|
}
|
|
59888
59891
|
}
|
|
@@ -60384,7 +60387,7 @@ var config2 = {
|
|
|
60384
60387
|
"--no-install",
|
|
60385
60388
|
"--no-git",
|
|
60386
60389
|
"--template",
|
|
60387
|
-
"
|
|
60390
|
+
"blog",
|
|
60388
60391
|
"--typescript",
|
|
60389
60392
|
"strict"
|
|
60390
60393
|
]
|
|
@@ -60660,7 +60663,7 @@ var package_default = {
|
|
|
60660
60663
|
"create-qwik": "1.2.12",
|
|
60661
60664
|
"create-react-app": "5.0.1",
|
|
60662
60665
|
"create-remix": "2.0.0",
|
|
60663
|
-
"create-solid": "0.
|
|
60666
|
+
"create-solid": "0.3.6",
|
|
60664
60667
|
"create-svelte": "5.0.6",
|
|
60665
60668
|
"create-vue": "3.7.5",
|
|
60666
60669
|
gatsby: "5.12.4",
|
|
@@ -60745,13 +60748,10 @@ var config10 = {
|
|
|
60745
60748
|
"pages:deploy": `${npm8} run build && wrangler pages deploy ./public`
|
|
60746
60749
|
},
|
|
60747
60750
|
devCommand: "dev",
|
|
60748
|
-
testFlags: ["--typescript", "--no-install"]
|
|
60751
|
+
testFlags: ["--typescript", "--no-install", "--no-git-init"]
|
|
60749
60752
|
};
|
|
60750
60753
|
var remix_default = config10;
|
|
60751
60754
|
|
|
60752
|
-
// src/frameworks/solid/index.ts
|
|
60753
|
-
var import_fs8 = require("fs");
|
|
60754
|
-
|
|
60755
60755
|
// src/frameworks/solid/templates.ts
|
|
60756
60756
|
var viteConfig = `
|
|
60757
60757
|
import solid from "solid-start/vite";
|
|
@@ -60766,13 +60766,12 @@ export default defineConfig({
|
|
|
60766
60766
|
// src/frameworks/solid/index.ts
|
|
60767
60767
|
var { npm: npm9, dlx: dlx11 } = detectPackageManager();
|
|
60768
60768
|
var generate11 = async (ctx) => {
|
|
60769
|
-
(0, import_fs8.mkdirSync)(ctx.project.path);
|
|
60770
|
-
process.chdir(ctx.project.path);
|
|
60771
60769
|
const cli = getFrameworkCli(ctx);
|
|
60772
|
-
await runFrameworkGenerator(ctx, `${dlx11} ${cli}`);
|
|
60770
|
+
await runFrameworkGenerator(ctx, `${dlx11} ${cli} ${ctx.project.name}`);
|
|
60773
60771
|
logRaw("");
|
|
60774
60772
|
};
|
|
60775
|
-
var configure7 = async () => {
|
|
60773
|
+
var configure7 = async (ctx) => {
|
|
60774
|
+
process.chdir(ctx.project.path);
|
|
60776
60775
|
const pkg = "solid-start-cloudflare-pages";
|
|
60777
60776
|
await installPackages([pkg], {
|
|
60778
60777
|
dev: true,
|
|
@@ -60782,7 +60781,7 @@ var configure7 = async () => {
|
|
|
60782
60781
|
const viteConfigPath = usesTypescript() ? `./vite.config.ts` : `./vite.config.js`;
|
|
60783
60782
|
writeFile2(viteConfigPath, viteConfig);
|
|
60784
60783
|
updateStatus(
|
|
60785
|
-
`Adding the Cloudflare Pages adapter to ${blue(
|
|
60784
|
+
`Adding the Cloudflare Pages adapter to ${blue(viteConfigPath)}`
|
|
60786
60785
|
);
|
|
60787
60786
|
};
|
|
60788
60787
|
var config11 = {
|
|
@@ -60947,7 +60946,7 @@ var debug = (msg) => {
|
|
|
60947
60946
|
};
|
|
60948
60947
|
|
|
60949
60948
|
// src/common.ts
|
|
60950
|
-
var
|
|
60949
|
+
var import_fs8 = require("fs");
|
|
60951
60950
|
var import_path7 = require("path");
|
|
60952
60951
|
var import_process2 = require("process");
|
|
60953
60952
|
|
|
@@ -61049,8 +61048,8 @@ var version2 = "3.10.1";
|
|
|
61049
61048
|
var { name, npm: npm12 } = detectPackageManager();
|
|
61050
61049
|
var validateProjectDirectory = (relativePath) => {
|
|
61051
61050
|
const path3 = (0, import_path7.resolve)(relativePath);
|
|
61052
|
-
const existsAlready = (0,
|
|
61053
|
-
const isEmpty = existsAlready && (0,
|
|
61051
|
+
const existsAlready = (0, import_fs8.existsSync)(path3);
|
|
61052
|
+
const isEmpty = existsAlready && (0, import_fs8.readdirSync)(path3).length === 0;
|
|
61054
61053
|
if (existsAlready && !isEmpty) {
|
|
61055
61054
|
return `Directory \`${relativePath}\` already exists and is not empty. Please choose a new name.`;
|
|
61056
61055
|
}
|
|
@@ -61063,7 +61062,7 @@ var setupProjectDirectory = (args) => {
|
|
|
61063
61062
|
}
|
|
61064
61063
|
const directory = (0, import_path7.dirname)(path3);
|
|
61065
61064
|
const pathBasename = (0, import_path7.basename)(path3);
|
|
61066
|
-
(0,
|
|
61065
|
+
(0, import_fs8.mkdirSync)(directory, { recursive: true });
|
|
61067
61066
|
(0, import_process2.chdir)(directory);
|
|
61068
61067
|
return { name: pathBasename, path: path3 };
|
|
61069
61068
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "create-cloudflare",
|
|
3
|
-
"version": "0.0.0-
|
|
3
|
+
"version": "0.0.0-a21acf82",
|
|
4
4
|
"description": "A CLI for creating and deploying new applications to Cloudflare.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"cloudflare",
|
|
@@ -65,7 +65,7 @@
|
|
|
65
65
|
"wrangler": "3.10.1"
|
|
66
66
|
},
|
|
67
67
|
"engines": {
|
|
68
|
-
"node": ">=
|
|
68
|
+
"node": ">=18.14.1"
|
|
69
69
|
},
|
|
70
70
|
"scripts": {
|
|
71
71
|
"build": "node -r esbuild-register scripts/build.ts",
|