gutterpress 0.10.4 → 0.10.5-beta.1

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 (38) hide show
  1. package/README.md +7 -3
  2. package/dist/api/index.d.ts +7 -3
  3. package/dist/api/index.js +24 -2
  4. package/dist/{audit-6gsbjcyp.js → audit-9pf96y1w.js} +4 -4
  5. package/dist/{build-8gx7gkgw.js → build-jw9kynts.js} +4 -4
  6. package/dist/{cli-7hay1r0h.js → cli-0t4zfevc.js} +1 -1
  7. package/dist/{cli-zddg7r27.js → cli-5w9y6r2f.js} +928 -74
  8. package/dist/{cli-h617210r.js → cli-nb902265.js} +1 -1
  9. package/dist/{cli-d613m9n5.js → cli-xewqry0j.js} +1 -1
  10. package/dist/cli.js +14 -14
  11. package/dist/{doctor-mrqpw7g3.js → doctor-6vmxh7mz.js} +2 -2
  12. package/dist/{engine-dzrzyyew.js → engine-fwe8djyn.js} +1 -1
  13. package/dist/{engine-pta3yeyt.js → engine-mtyjc4v6.js} +2 -2
  14. package/dist/{index-1z8a090c.js → index-3xv7vwv2.js} +972 -120
  15. package/dist/{index-cm4dywtk.js → index-ja0p4w5f.js} +1 -1
  16. package/dist/{index-p4yq14qw.js → index-k5hcp8wj.js} +1 -1
  17. package/dist/index.js +25 -3
  18. package/dist/lib/markdown/gutterpress-css.d.ts +10 -2
  19. package/dist/lib/open-path.d.ts +27 -0
  20. package/dist/lib/publish/connect-google.d.ts +34 -0
  21. package/dist/lib/publish/connect.d.ts +23 -0
  22. package/dist/lib/publish/google-auth.d.ts +104 -0
  23. package/dist/lib/publish/google-drive.d.ts +88 -0
  24. package/dist/lib/publish/google-errors.d.ts +49 -0
  25. package/dist/lib/publish/providers/gdrive.d.ts +25 -0
  26. package/dist/lib/publish/run-publish.d.ts +14 -1
  27. package/dist/lib/publish/types.d.ts +46 -2
  28. package/dist/lib/remote-auth/token-store.d.ts +1 -1
  29. package/dist/{lint-gmymvnm3.js → lint-kzvbrn3d.js} +4 -4
  30. package/dist/{manifest.schema-084rxtwp.json → manifest.schema-hn6ac0ae.json} +25 -0
  31. package/dist/{new-hw7s7jne.js → new-cyna8tyn.js} +4 -4
  32. package/dist/{plugin-0qtfgjr2.js → plugin-mpc5v8sr.js} +4 -4
  33. package/dist/{preflight-j99dpj5e.js → preflight-fc178as2.js} +4 -4
  34. package/dist/{preview-sc3rcrkh.js → preview-qnbbtyqb.js} +4 -4
  35. package/dist/{publish-xwrwvrh0.js → publish-gmgpyh4n.js} +58 -9
  36. package/dist/schema/manifest.types.d.ts +20 -0
  37. package/dist/{validate-evzfg9m6.js → validate-0t3vjpmk.js} +4 -4
  38. package/package.json +1 -1
package/README.md CHANGED
@@ -216,14 +216,14 @@ gutterpress build [input-dir] [options]
216
216
 
217
217
  ### `gutterpress publish`
218
218
 
219
- Push a built PDF/HTML artifact to a publishing platform (itch.io, DriveThruRPG, Amazon KDP, Azure Static Web Apps, Shopify), headlessly and CI-safely. Credentials live in a 0600 user-config store (never in the project); provider env vars override it for CI.
219
+ Push a built PDF/HTML artifact to a publishing platform (itch.io, DriveThruRPG, Amazon KDP, Azure Static Web Apps, Shopify, Google Drive), headlessly and CI-safely. Credentials live in a 0600 user-config store (never in the project); provider env vars override it for CI. Most providers connect with a pasted API key; Google Drive connects through your browser instead (`--connect` opens the sign-in page — nothing to paste).
220
220
 
221
221
  ```sh
222
222
  gutterpress publish [project] [options]
223
223
 
224
- --provider <id> itch | drivethrurpg | kdp | azure-swa | shopify
224
+ --provider <id> itch | drivethrurpg | kdp | azure-swa | shopify | gdrive
225
225
  --list List providers and connection status
226
- --connect Store an API key for --provider (from --token, the provider's env var, or piped stdin)
226
+ --connect Store an API key for --provider (from --token, the provider's env var, or piped stdin) — or, for gdrive, open the browser to connect
227
227
  --disconnect Forget the stored key for --provider
228
228
  --account <label> Named-credential label for --connect/--disconnect (keep several accounts per provider); omit for the default
229
229
  --token <key> API key for --connect (prefer stdin/env var to keep it out of shell history)
@@ -241,6 +241,10 @@ gutterpress publish --list
241
241
  # Store an API key for itch.io, then publish
242
242
  gutterpress publish --provider itch --connect
243
243
  gutterpress publish --provider itch ./my-book
244
+
245
+ # Google Drive connects via your browser, not a pasted key
246
+ gutterpress publish --provider gdrive --connect
247
+ gutterpress publish --provider gdrive ./my-book
244
248
  ```
245
249
 
246
250
  ### `gutterpress lint`
@@ -49,6 +49,10 @@ export { FileTokenStore, defaultConfigDir, extractUrlCredential, } from "../lib/
49
49
  export type { HostCredential, TokenStore, UrlCredentialExtraction, } from "../lib/remote-auth/token-store.ts";
50
50
  export { GitHubAuthProvider, resolveGitHubClientId, GITHUB_HOST, } from "../lib/remote-auth/github-auth.ts";
51
51
  export type { HostCallbacks, DeviceCodeInfo, GitHubAuthProviderOptions, } from "../lib/remote-auth/github-auth.ts";
52
+ export { GoogleAuthProvider, resolveGoogleClientId, resolveGoogleClientSecret, revokeGoogleCredential, requireGoogleClientCredentials, pkceChallengeFromVerifier, GDRIVE_HOST, GOOGLE_NOT_CONFIGURED_MESSAGE, } from "../lib/publish/google-auth.ts";
53
+ export type { GoogleHostCallbacks, GoogleAuthProviderOptions, } from "../lib/publish/google-auth.ts";
54
+ export { connectGoogleDrive } from "../lib/publish/connect-google.ts";
55
+ export type { ConnectGoogleDriveOptions, ConnectGoogleDriveResult, } from "../lib/publish/connect-google.ts";
52
56
  export { listGitHubRepositories, listGitHubBranches, listRepoBooks, } from "../lib/remote-auth/github-repos.ts";
53
57
  export type { RemoteRepository, RemoteBranch, RepoBook, } from "../lib/remote-auth/github-repos.ts";
54
58
  export { cloneRepository, sanitizeCloneFolderName, } from "../lib/remote-auth/clone.ts";
@@ -62,11 +66,11 @@ export type { ProjectRemoteDiagnosis, DiagnoseProjectRemoteOptions, RemoteProtoc
62
66
  export { syncProject, SYNC_SNAPSHOT_MESSAGE, } from "../lib/remote-auth/sync.ts";
63
67
  export type { SyncOutcome, SyncProjectOptions, KeptBothFile, } from "../lib/remote-auth/sync.ts";
64
68
  export type { SnapshotEntry, InitVersionHistoryOptions, SnapshotOptions, RestoreSnapshotOptions, RestoreVersionOptions, RestoreVersionResult, SourceProvider, } from "../lib/source-provider.ts";
65
- export { runPublish, resolvePublishRequest, } from "../lib/publish/run-publish.ts";
69
+ export { runPublish, resolvePublishRequest, resolvePublishFormat, } from "../lib/publish/run-publish.ts";
66
70
  export type { RunPublishOptions, RunPublishResult, } from "../lib/publish/run-publish.ts";
67
71
  export { listPublishProviders, publishProviderFor, } from "../lib/publish/registry.ts";
68
- export { connectPublishProvider } from "../lib/publish/connect.ts";
69
- export type { ConnectPublishProviderOptions } from "../lib/publish/connect.ts";
72
+ export { connectPublishProvider, disconnectPublishCredential } from "../lib/publish/connect.ts";
73
+ export type { ConnectPublishProviderOptions, DisconnectPublishCredentialOptions, } from "../lib/publish/connect.ts";
70
74
  export { publishConnectionStatus, publishCredentialKey, listPublishAccounts, } from "../lib/publish/types.ts";
71
75
  export type { PublishSavedAccount } from "../lib/publish/types.ts";
72
76
  export { PublishSelectionsStore } from "../lib/publish/selections.ts";
package/dist/api/index.js CHANGED
@@ -9,8 +9,11 @@ import {
9
9
  BUILT_IN_TEMPLATE_IDS,
10
10
  BUILT_IN_THEME_IDS,
11
11
  FileTokenStore,
12
+ GDRIVE_HOST,
12
13
  GITHUB_HOST,
14
+ GOOGLE_NOT_CONFIGURED_MESSAGE,
13
15
  GitHubAuthProvider,
16
+ GoogleAuthProvider,
14
17
  MANIFEST_FILENAMES,
15
18
  PLUGINS_DIR,
16
19
  PRESETS,
@@ -30,10 +33,12 @@ import {
30
33
  autoSyncDelayMs,
31
34
  cloneRepository,
32
35
  connectGenericHost,
36
+ connectGoogleDrive,
33
37
  connectPublishProvider,
34
38
  defaultConfigDir,
35
39
  deleteSnippet,
36
40
  diagnoseProjectRemote,
41
+ disconnectPublishCredential,
37
42
  escapeYamlScalar,
38
43
  extractUrlCredential,
39
44
  extractVariables,
@@ -63,6 +68,7 @@ import {
63
68
  listSnippets,
64
69
  loadManifestWithPath,
65
70
  parseRemoteOrigin,
71
+ pkceChallengeFromVerifier,
66
72
  publishConnectionStatus,
67
73
  publishCredentialKey,
68
74
  publishProviderFor,
@@ -72,12 +78,17 @@ import {
72
78
  readSnippet,
73
79
  readThemeCss,
74
80
  removeProjectTheme,
81
+ requireGoogleClientCredentials,
75
82
  resolveActiveStyles,
76
83
  resolveBuiltInTheme,
77
84
  resolveConfig,
78
85
  resolveGitHubClientId,
86
+ resolveGoogleClientId,
87
+ resolveGoogleClientSecret,
88
+ resolvePublishFormat,
79
89
  resolvePublishRequest,
80
90
  revertTheme,
91
+ revokeGoogleCredential,
81
92
  runBuild,
82
93
  runPublish,
83
94
  sanitizeCloneFolderName,
@@ -95,12 +106,12 @@ import {
95
106
  syncProject,
96
107
  testRemoteAccess,
97
108
  validateProjectPlugins
98
- } from "../index-1z8a090c.js";
109
+ } from "../index-3xv7vwv2.js";
99
110
  import {
100
111
  BuildError,
101
112
  DEFAULT_PRINT_OPTS,
102
113
  readyProbeExpr
103
- } from "../index-p4yq14qw.js";
114
+ } from "../index-k5hcp8wj.js";
104
115
  import {
105
116
  AUTO_SNAPSHOT_MESSAGE,
106
117
  HISTORY_PAGE_LIMIT,
@@ -136,14 +147,19 @@ export {
136
147
  sanitizeCloneFolderName,
137
148
  runPublish,
138
149
  runBuild,
150
+ revokeGoogleCredential,
139
151
  revertTheme,
140
152
  restoreVersionWithBackup,
141
153
  resolvePublishRequest,
154
+ resolvePublishFormat,
142
155
  resolveLogger,
156
+ resolveGoogleClientSecret,
157
+ resolveGoogleClientId,
143
158
  resolveGitHubClientId,
144
159
  resolveConfig,
145
160
  resolveBuiltInTheme,
146
161
  resolveActiveStyles,
162
+ requireGoogleClientCredentials,
147
163
  repoSubPath,
148
164
  repoRootForSource,
149
165
  removeProjectTheme,
@@ -157,6 +173,7 @@ export {
157
173
  publishCredentialKey,
158
174
  publishConnectionStatus,
159
175
  providerFor,
176
+ pkceChallengeFromVerifier,
160
177
  parseRemoteOrigin,
161
178
  loadManifestWithPath,
162
179
  listSnippets,
@@ -188,11 +205,13 @@ export {
188
205
  extractVariables,
189
206
  extractUrlCredential,
190
207
  escapeYamlScalar,
208
+ disconnectPublishCredential,
191
209
  diagnoseProjectRemote,
192
210
  detectProjectSource,
193
211
  deleteSnippet,
194
212
  defaultConfigDir,
195
213
  connectPublishProvider,
214
+ connectGoogleDrive,
196
215
  connectGenericHost,
197
216
  cloneRepository,
198
217
  capabilitiesFor,
@@ -215,8 +234,11 @@ export {
215
234
  PLUGINS_DIR,
216
235
  MANIFEST_FILENAMES,
217
236
  HISTORY_PAGE_LIMIT,
237
+ GoogleAuthProvider,
218
238
  GitHubAuthProvider,
239
+ GOOGLE_NOT_CONFIGURED_MESSAGE,
219
240
  GITHUB_HOST,
241
+ GDRIVE_HOST,
220
242
  FileTokenStore,
221
243
  DEFAULT_PRINT_OPTS,
222
244
  BuildError,
@@ -1,15 +1,15 @@
1
1
  import {
2
2
  executeAndReport
3
- } from "./cli-zddg7r27.js";
3
+ } from "./cli-5w9y6r2f.js";
4
4
  import {
5
5
  log
6
- } from "./cli-h617210r.js";
6
+ } from "./cli-nb902265.js";
7
7
  import {
8
8
  UsageError,
9
9
  rejectExtraPositionals,
10
10
  rejectUnknownFlags
11
- } from "./cli-d613m9n5.js";
12
- import"./cli-7hay1r0h.js";
11
+ } from "./cli-xewqry0j.js";
12
+ import"./cli-0t4zfevc.js";
13
13
  import"./cli-c41yr7he.js";
14
14
  import {
15
15
  EXIT_CODES
@@ -1,10 +1,10 @@
1
1
  import {
2
2
  runBuild,
3
3
  splitOutPath
4
- } from "./cli-zddg7r27.js";
4
+ } from "./cli-5w9y6r2f.js";
5
5
  import {
6
6
  log
7
- } from "./cli-h617210r.js";
7
+ } from "./cli-nb902265.js";
8
8
  import {
9
9
  UsageError,
10
10
  parseEngine,
@@ -12,8 +12,8 @@ import {
12
12
  parsePdfxFlavor,
13
13
  rejectExtraPositionals,
14
14
  rejectUnknownFlags
15
- } from "./cli-d613m9n5.js";
16
- import"./cli-7hay1r0h.js";
15
+ } from "./cli-xewqry0j.js";
16
+ import"./cli-0t4zfevc.js";
17
17
  import"./cli-c41yr7he.js";
18
18
  import {
19
19
  BuildError
@@ -1430,7 +1430,7 @@ import { fileURLToPath } from "node:url";
1430
1430
  var favicon_default = "./favicon-wkbm9cjn.ico";
1431
1431
 
1432
1432
  // src/assets/manifest.schema.json
1433
- var manifest_schema_default = "./manifest.schema-084rxtwp.json";
1433
+ var manifest_schema_default = "./manifest.schema-hn6ac0ae.json";
1434
1434
 
1435
1435
  // src/assets/preview/scripts/preview-interface.js
1436
1436
  var preview_interface_default = "./preview-interface-9rwz21yw.js";