@monoweave/types 0.0.4 → 1.0.0

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
@@ -2,6 +2,15 @@
2
2
 
3
3
  <!-- MONOWEAVE:BELOW -->
4
4
 
5
+ ## [0.0.5](https://github.com/monoweave/monoweave/compare/@monoweave/types@0.0.4...@monoweave/types@0.0.5) "@monoweave/types" (2024-03-01)<a name="0.0.5"></a>
6
+
7
+ ### Bug Fixes
8
+
9
+ * add preset to MonoweaveConfigFile type (#3) ([dc522fe](https://github.com/monoweave/monoweave/commits/dc522fe))
10
+
11
+
12
+
13
+
5
14
  ## [0.0.4](https://github.com/monoweave/monoweave/compare/@monoweave/types@0.0.3...@monoweave/types@0.0.4) "@monoweave/types" (2024-02-29)<a name="0.0.4"></a>
6
15
 
7
16
  ### Bug Fixes
package/lib/types.d.ts CHANGED
@@ -95,12 +95,15 @@ export interface MonoweaveConfiguration {
95
95
  tag: boolean;
96
96
  };
97
97
  /**
98
- * A conventional changelog config package name. This is required for changelog generation.
99
- * This config determines the changelog format, as well as the version strategy determiner.
98
+ * A conventional changelog config package name. This config determines the changelog format,
99
+ * as well as the version strategy determiner.
100
+ *
101
+ * Set explicitly to false to disable conventional changelog mode and enter a "manual" mode
102
+ * that determines versions based on version files.
100
103
  *
101
104
  * @default _Partial internal implementation (not recommended)_
102
105
  */
103
- conventionalChangelogConfig?: string | {
106
+ conventionalChangelogConfig?: false | string | {
104
107
  name: string;
105
108
  [key: string]: unknown;
106
109
  };
@@ -109,12 +112,6 @@ export interface MonoweaveConfiguration {
109
112
  * run, will contain change history useful for external scripts. Set to '-' to write to stdout.
110
113
  */
111
114
  changesetFilename?: string;
112
- /**
113
- * Whether to resume publishing from a changeset. This option can only be set from the command line,
114
- * and cannot be provided via a monoweave.config.js file. This feature is _not_ available yet. If
115
- * you're interested in this feature, please leave comments on the [GitHub Issue](https://github.com/monoweave/monoweave/issues/323).
116
- */
117
- applyChangeset?: boolean;
118
115
  /**
119
116
  * The filename to write changelogs to, assuming a conventional changelog config has been set.
120
117
  * Use '<packageDir>' to reference the cwd of an individual workspace. You should also enable
@@ -284,6 +281,19 @@ export interface VersionStrategyConfiguration {
284
281
  * @default undefined
285
282
  */
286
283
  minimumStrategy?: 'patch' | 'minor' | 'major' | undefined;
284
+ /**
285
+ * If enabled, version strategy determination will be based on committed version files
286
+ * instead of conventional changelog commit message parsing. If a conventional changelog
287
+ * config is provided, it will be used for changelog generation only.
288
+ */
289
+ manualMode?: boolean;
290
+ /**
291
+ * If using monoweave in manual mode (which is activated by setting the conventional changelog config
292
+ * explicitly to false), the version folder can be specified to change the location of deferred version files.
293
+ *
294
+ * @default "./.monoweave"
295
+ */
296
+ versionFolder?: string;
287
297
  }
288
298
  export interface GroupConfiguration {
289
299
  /**
@@ -322,6 +332,7 @@ export type PackageStrategyType = 'major' | 'minor' | 'patch';
322
332
  export type PackageStrategyMap = Map<string, {
323
333
  type: PackageStrategyType;
324
334
  commits: CommitMessage[];
335
+ changelog?: string;
325
336
  }>;
326
337
  export type StrategyDeterminer = (commits: string[]) => Promise<number>;
327
338
  export interface ChangesetRecord {
@@ -334,4 +345,14 @@ export interface ChangesetRecord {
334
345
  }
335
346
  export type ChangesetSchema = Record<string, ChangesetRecord>;
336
347
  export declare function isNodeError<T = NodeJS.ErrnoException>(error: unknown): error is T;
337
- export type MonoweaveConfigFile = RecursivePartial<Omit<MonoweaveConfiguration, 'cwd'>>;
348
+ export type MonoweaveConfigFile = RecursivePartial<Omit<MonoweaveConfiguration, 'cwd'>> & {
349
+ preset?: string;
350
+ };
351
+ /**
352
+ * Represents a deferred version entry, used when conventional changelog
353
+ * mode is disabled.
354
+ */
355
+ export interface DeferredVersionRecord {
356
+ changelog?: string;
357
+ strategies: Record<string, PackageStrategyType | null>;
358
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@monoweave/types",
3
- "version": "0.0.4",
3
+ "version": "1.0.0",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "https://github.com/monoweave/monoweave.git",
@@ -8,7 +8,7 @@
8
8
  },
9
9
  "author": {
10
10
  "name": "noahnu",
11
- "url": "https://monoweave.github.io"
11
+ "url": "https://monoweave.github.io/monoweave/"
12
12
  },
13
13
  "license": "BSD-3",
14
14
  "main": "./lib/types.js",