@tinacms/cli 0.60.1 → 0.60.2

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/CHANGELOG.md CHANGED
@@ -1,5 +1,12 @@
1
1
  # tinacms-cli
2
2
 
3
+ ## 0.60.2
4
+
5
+ ### Patch Changes
6
+
7
+ - d17de356a: Update CLI to use apiUrl
8
+ - a67b0c1d7: Dont reinstantiate bridge and store
9
+
3
10
  ## 0.60.1
4
11
 
5
12
  ### Patch Changes
package/dist/index.js CHANGED
@@ -85,7 +85,7 @@ var commander = __toModule(require("commander"));
85
85
 
86
86
  // pnp:/home/runner/work/tinacms/tinacms/packages/@tinacms/cli/package.json
87
87
  var name = "@tinacms/cli";
88
- var version = "0.60.1";
88
+ var version = "0.60.2";
89
89
 
90
90
  // pnp:/home/runner/work/tinacms/tinacms/packages/@tinacms/cli/src/utils/theme.ts
91
91
  var import_chalk = __toModule(require("chalk"));
@@ -532,9 +532,7 @@ stack: ${code.stack || "No stack was provided"}`);
532
532
  if (!process.env.CI && !noWatch) {
533
533
  await resetGeneratedFolder();
534
534
  }
535
- const bridge2 = new import_datalayer2.FilesystemBridge(rootPath2);
536
- const store2 = experimentalData ? new import_datalayer2.LevelStore(rootPath2) : new import_datalayer2.FilesystemStore({ rootPath: rootPath2 });
537
- const database2 = await (0, import_graphql7.createDatabase)({ store: store2, bridge: bridge2 });
535
+ const database2 = await (0, import_graphql7.createDatabase)({ store, bridge });
538
536
  await compile(null, null);
539
537
  const schema = await (0, import_graphql7.buildSchema)(rootPath2, database2);
540
538
  await genTypes({ schema }, () => {
@@ -909,17 +907,19 @@ import { TinaEditProvider } from 'tinacms/dist/edit-state'
909
907
  const TinaCMS = dynamic(() => import('tinacms'), { ssr: false })
910
908
  ${extraImports || ""}
911
909
 
910
+ const branch = process.env.NEXT_PUBLIC_EDIT_BRANCH || "main";
911
+ const apiURL =
912
+ process.env.NODE_ENV == "development"
913
+ ? "http://localhost:4001/graphql"
914
+ : \`https://content.tinajs.io/content/\${process.env.NEXT_PUBLIC_TINA_CLIENT_ID}/github/\${branch}\`;
915
+
912
916
  const App = ({ Component, pageProps }) => {
913
917
  return (
914
918
  <>
915
919
  <TinaEditProvider
916
920
  editMode={
917
921
  <TinaCMS
918
- clientId={process.env.NEXT_PUBLIC_TINA_CLIENT_ID}
919
- branch={process.env.NEXT_PUBLIC_EDIT_BRANCH}
920
- isLocalClient={Boolean(
921
- Number(process.env.NEXT_PUBLIC_USE_LOCAL_CLIENT ?? true)
922
- )}
922
+ apiURL={apiURL}
923
923
  {...pageProps}
924
924
  >
925
925
  {(livePageProps) => <Component {...livePageProps} />}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tinacms/cli",
3
- "version": "0.60.1",
3
+ "version": "0.60.2",
4
4
  "main": "dist/index.js",
5
5
  "typings": "dist/index.d.ts",
6
6
  "files": [