create-clivly 0.7.2 → 0.7.4

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.
Files changed (2) hide show
  1. package/README.md +64 -48
  2. package/package.json +2 -2
package/README.md CHANGED
@@ -1,10 +1,22 @@
1
1
  # create-clivly
2
2
 
3
- Scaffold Clivly into an existing app. `create-clivly` is the `create-*` entry
4
- point for `clivly init`: it runs the same initializer, with the same flags,
5
- against a version-pinned `clivly` runtime.
3
+ Scaffold [Clivly](https://clivly.com) — an embeddable CRM — into your **existing**
4
+ app. This is the `create-*` entry point for `clivly init`: it runs exactly what
5
+ `clivly init` runs, with the same flags, against a version-pinned `clivly`
6
+ runtime.
6
7
 
7
- ## Install / run
8
+ > `create-clivly` does **not** create a new application. It scaffolds Clivly
9
+ > into a project you already have.
10
+
11
+ ## Prerequisites
12
+
13
+ | Requirement | Version / note |
14
+ | --- | --- |
15
+ | Node.js | **≥ 22** |
16
+ | An existing app | Next.js, TanStack Start, SvelteKit, Remix or Nuxt for route scaffolding |
17
+ | Drizzle ORM | Required to generate a config. Prisma/Kysely projects hand-write a `fetchPage` source instead |
18
+
19
+ ## Installation
8
20
 
9
21
  ```bash
10
22
  npm create clivly
@@ -12,74 +24,78 @@ npm create clivly
12
24
  npx create-clivly
13
25
  # or
14
26
  pnpm create clivly
27
+ # or
28
+ yarn create clivly
29
+ # or
30
+ bun create clivly
15
31
  ```
16
32
 
17
- Stable releases publish on npm's `latest` tag. Use `@next` only when you are
18
- deliberately validating a prerelease build.
33
+ Published on npm's `latest` tag. Use `@next` only when you are deliberately
34
+ validating a prerelease build.
19
35
 
20
- ## What it does
36
+ ## What it writes
21
37
 
22
- `create-clivly` currently:
38
+ | File | Owned by Clivly |
39
+ | --- | --- |
40
+ | `clivly.config.ts` | No — yours to edit |
41
+ | The tick route for your framework | Yes — `--force` to overwrite |
42
+ | The auth-verify route for your framework | Yes — `--force` to overwrite |
23
43
 
24
- - writes `clivly.config.ts`
25
- - scaffolds the supported Clivly route files for your framework
26
- - appends `.env` placeholders when they are missing
27
- - optionally runs the pairing step unless you pass `--no-login`
44
+ Plus `CLIVLY_SECRET_KEY`, `CLIVLY_SYNC_TRIGGER_URL` and
45
+ `CLIVLY_SYNC_TRIGGER_SECRET` placeholders in your framework's env file
46
+ (`.env.local` on Next.js, `.dev.vars` on Cloudflare Workers, `.env` elsewhere),
47
+ and — unless `--no-login` — it pairs this machine with your workspace.
28
48
 
29
- It does **not** mutate your existing Drizzle schema.
49
+ It creates **no database tables** and does **not** modify your ORM schema.
50
+ Clivly Cloud holds the CRM records; your own tables are only ever read.
30
51
 
31
52
  If you run it from a workspace root, it looks for a supported Drizzle app in
32
- that repo and scaffolds there. If it finds more than one candidate, it stops
33
- and shows you the directories instead of guessing.
53
+ that repo and scaffolds there. If it finds more than one, it stops and shows you
54
+ the candidate directories instead of guessing.
34
55
 
35
56
  ## Flags
36
57
 
37
- These are forwarded directly to `clivly init`:
58
+ Forwarded straight to `clivly init` — this is the full set.
38
59
 
39
60
  | Flag | Effect |
40
61
  | --- | --- |
41
- | `--dry-run` | Print the plan and diff without writing files |
42
- | `--diff` | Show the full diff for each file it would write |
43
- | `--force` | Overwrite existing files and `.env` values |
44
- | `--yes` | Accept detected defaults instead of prompting |
45
- | `--schema <path\|package>` | Point at your Drizzle schema explicitly |
46
- | `--db-import <specifier>` | Set the import specifier the scaffold uses for your Drizzle client |
47
- | `--auth-import <specifier>` | Set the import specifier for your auth adapter |
62
+ | `--dry-run` | Print the plan without writing anything |
63
+ | `--diff` | Show a diff for files that already exist |
64
+ | `--force` | Overwrite the files Clivly owns, and env values that already have a real value |
65
+ | `--yes` | Skip prompts |
48
66
  | `--no-login` | Skip the browser pairing step |
49
- | `--no-browser` | Print the approval URL instead of opening it |
50
-
51
- Any flag that `clivly init` accepts also works here.
52
-
53
- ## Relationship to `clivly`
54
-
55
- - `create-clivly` is the one-time scaffolder.
56
- - `clivly` is the package you use afterwards for the runtime SDK and CLI.
67
+ | `--no-browser` | Pair, but print the approval URL instead of opening it |
68
+ | `--schema <path\|package>` | Point at your Drizzle schema explicitly |
69
+ | `--db-import <specifier>` | Where the Drizzle instance lives, when it is not beside the schema. Accepts `@acme/database#database` |
70
+ | `--auth-import <specifier>` | Where your better-auth instance lives. Same `#exportName` form |
71
+ | `--contact-table <name>` | Use this table as the contact entity, skipping the heuristics |
72
+ | `--company-table <name>` | Same for companies |
57
73
 
58
- Example runtime imports:
74
+ Full explanations of each flag, plus monorepo behaviour and what happens when no
75
+ contact entity can be found, are in the
76
+ [`clivly` CLI README](https://github.com/amani-joseph/clivly.com/blob/master/packages/cli/README.md#clivly-init).
59
77
 
60
- ```ts
61
- import { createClivlySDK } from "clivly/sdk";
62
- ```
63
-
64
- Example follow-up CLI commands:
78
+ ## Verify
65
79
 
66
80
  ```bash
67
81
  npx clivly status
68
- npx clivly dev
69
- npx clivly login
70
82
  ```
71
83
 
72
- `create-clivly` pins the `clivly` version it installs so the scaffolder and
73
- runtime stay aligned.
84
+ ## Relationship to `clivly`
85
+
86
+ - **`create-clivly`** — the scaffolder you run once to set a project up.
87
+ - **`clivly`** — the runtime you import
88
+ (`import { createClivlySDK } from "clivly/sdk"`) and the CLI you run afterwards
89
+ (`clivly status`, `clivly dev`, `clivly login`, `clivly add widget`).
90
+
91
+ `create-clivly` pins the `clivly` version it installs, so the scaffolder and the
92
+ runtime never drift.
74
93
 
75
- ## More docs
94
+ ## Related documentation
76
95
 
77
- - Cloud onboarding guide:
78
- [Connecting to Clivly Cloud](https://github.com/amani-joseph/clivly.com/blob/master/docs/guides/connecting-to-clivly-cloud.md)
79
- - CLI reference:
80
- [packages/cli/README.md](https://github.com/amani-joseph/clivly.com/blob/master/packages/cli/README.md)
81
- - Release notes:
82
- [CHANGELOG.md](https://github.com/amani-joseph/clivly.com/blob/master/CHANGELOG.md)
96
+ - **[Connecting to Clivly Cloud](https://github.com/amani-joseph/clivly.com/blob/master/docs/guides/connecting-to-clivly-cloud.md)** — the canonical end-to-end guide
97
+ - [`clivly` CLI README](https://github.com/amani-joseph/clivly.com/blob/master/packages/cli/README.md)
98
+ - [`@clivly/sdk` README](https://github.com/amani-joseph/clivly.com/blob/master/packages/sdk/README.md)
83
99
 
84
100
  ## License
85
101
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-clivly",
3
- "version": "0.7.2",
3
+ "version": "0.7.4",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "description": "Scaffold Clivly into your app — the create-* entry point for `clivly init`.",
@@ -34,7 +34,7 @@
34
34
  }
35
35
  },
36
36
  "dependencies": {
37
- "clivly": "0.7.2"
37
+ "clivly": "0.7.4"
38
38
  },
39
39
  "author": "Joseph Amani",
40
40
  "engines": {