MCPcopy Create free account
hub / github.com/dmno-dev/bumpy / makeRelease

Function makeRelease

packages/bumpy/test/helpers.ts:54–74  ·  view source on GitHub ↗
(
  name: string,
  newVersion: string,
  opts: Partial<
    Pick<PlannedRelease, 'type' | 'oldVersion' | 'bumpFiles' | 'isDependencyBump' | 'isCascadeBump' | 'isGroupBump'>
  > & {
    bumpSources?: Array<{ name: string; newVersion: string; bumpType?: BumpType }>;
  } = {},
)

Source from the content-addressed store, hash-verified

52
53/** Create a PlannedRelease for testing */
54export function makeRelease(
55 name: string,
56 newVersion: string,
57 opts: Partial<
58 Pick<PlannedRelease, 'type' | 'oldVersion' | 'bumpFiles' | 'isDependencyBump' | 'isCascadeBump' | 'isGroupBump'>
59 > & {
60 bumpSources?: Array<{ name: string; newVersion: string; bumpType?: BumpType }>;
61 } = {},
62): PlannedRelease {
63 return {
64 name,
65 type: opts.type ?? 'patch',
66 oldVersion: opts.oldVersion ?? '0.0.0',
67 newVersion,
68 bumpFiles: opts.bumpFiles ?? [],
69 isDependencyBump: opts.isDependencyBump ?? false,
70 isCascadeBump: opts.isCascadeBump ?? false,
71 isGroupBump: opts.isGroupBump ?? false,
72 bumpSources: (opts.bumpSources ?? []).map((s) => ({ ...s, bumpType: s.bumpType ?? opts.type ?? 'patch' })),
73 };
74}
75
76/** Create a BumpFile for testing */
77export function makeBumpFile(

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…