-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix up maintenance-create-patch.ts, phetsims/chipper#1461
- Loading branch information
Showing
1 changed file
with
18 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,29 @@ | ||
// Copyright 2024, University of Colorado Boulder | ||
|
||
/** | ||
* Reports out on release branch statuses | ||
* Adds a patch to the maintenance process | ||
* @author Jonathan Olson <[email protected]> | ||
* @author Michael Kauzmann (PhET Interactive Simulations) | ||
*/ | ||
|
||
import assert from 'assert'; | ||
import winston from 'winston'; | ||
import Maintenance from '../../common/Maintenance'; | ||
import assertIsValidRepoName from '../../common/assertIsValidRepoName.js'; | ||
import Maintenance from '../../common/Maintenance.js'; | ||
import getOption from './util/getOption'; | ||
|
||
winston.default.transports.console.level = 'error'; | ||
|
||
// TODO: Does this belong in grunt? See https://github.com/phetsims/chipper/issues/1461 | ||
( async () => Maintenance.checkBranchStatus() )(); | ||
( async () => { | ||
|
||
const repo = getOption( 'repo' ); | ||
assertIsValidRepoName( repo ); | ||
|
||
const message = getOption( 'message' ); | ||
|
||
assert( repo, 'Requires specifying a repo that will need to be patched with --repo={{REPO}}' ); | ||
assert( message, 'Requires specifying a message (included with commits) with --message={{MESSAGE}}' ); | ||
|
||
await Maintenance.createPatch( repo, message ); | ||
} )(); |