create-ponder 0.0.6 → 0.0.8

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/README.md CHANGED
@@ -1 +1,7 @@
1
- # Go to [docs on GitHub](https://github.com/0xOlias/ponder#readme)
1
+ # create-ponder
2
+
3
+ `create-ponder` is a CLI tool for creating projects using the Ponder framework.
4
+
5
+ ## Documentation
6
+
7
+ For full documentation, visit [ponder.sh](https://ponder.sh/getting-started).
package/dist/index.js CHANGED
@@ -213,6 +213,8 @@ module.exports = ponderConfig;`;
213
213
  generated/`
214
214
  );
215
215
  const packageManager = await (0, import_detectPackageManager.detect)();
216
+ const runCommand =
217
+ packageManager === "npm" ? `${packageManager} run` : packageManager;
216
218
  const renderYaml = `
217
219
  # This file was generated by \`create-ponder\`. You can deploy your Ponder app
218
220
  # by signing in to https://render.com, connecting this repository, and clicking Deploy.
@@ -222,9 +224,9 @@ services:
222
224
  name: ponder-app
223
225
  env: node
224
226
  buildCommand: ${packageManager} install
225
- startCommand: ${packageManager} run start
227
+ startCommand: ${runCommand} start
226
228
  envVars:
227
- - key: POSTGRES_URL
229
+ - key: DATABASE_URL
228
230
  fromDatabase:
229
231
  name: ponder-db
230
232
  property: connectionString
@@ -255,7 +257,7 @@ databases:
255
257
  import_picocolors.default.cyan("[create-ponder] ") + `Generating types`
256
258
  );
257
259
  (0, import_node_child_process.execSync)(
258
- `${packageManager} run --silent codegen`,
260
+ `${runCommand} --silent codegen --silent`,
259
261
  {
260
262
  cwd: ponderRootDir,
261
263
  stdio: "inherit",
@@ -264,11 +266,8 @@ databases:
264
266
  console.log(
265
267
  import_picocolors.default.cyan("[create-ponder] ") +
266
268
  import_picocolors.default.green("Done! ") +
267
- `To get started: ${import_picocolors.default.yellow(
268
- `cd ${import_node_path.default.relative(
269
- ".",
270
- ponderRootDir
271
- )} && ${packageManager} run dev`
269
+ `To get started run ${import_picocolors.default.yellow(
270
+ `${runCommand} dev`
272
271
  )}`
273
272
  );
274
273
  };
@@ -77,7 +77,10 @@ const fromEtherscan = async (options) => {
77
77
  ponderRootDir,
78
78
  abiRelativePath
79
79
  );
80
- (0, import_node_fs.writeFileSync)(abiAbsolutePath, abi);
80
+ (0, import_node_fs.writeFileSync)(
81
+ abiAbsolutePath,
82
+ import_prettier.default.format(abi, { parser: "json" })
83
+ );
81
84
  const schemaGraphqlFileContents = `
82
85
  type ExampleEntity @entity {
83
86
  id: ID!
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-ponder",
3
- "version": "0.0.6",
3
+ "version": "0.0.8",
4
4
  "description": "Tool to bootstrap a Ponder project",
5
5
  "license": "MIT",
6
6
  "author": "olias.eth",