MCPcopy Create free account
hub / github.com/angular/dev-infra / _commit

Method _commit

ng-dev/utils/testing/virtual-git-client.ts:126–136  ·  view source on GitHub ↗

Handler for the `git commit` command.

(rawArgs: string[])

Source from the content-addressed store, hash-verified

124
125 /** Handler for the `git commit` command. */
126 private _commit(rawArgs: string[]) {
127 const {message, files} = yargs(rawArgs)
128 .command('$0 [files..]', false)
129 .option('message', {string: true, alias: 'm'})
130 .positional('files', {array: true, demandOption: true, type: 'string'})
131 .parseSync();
132 if (!message) {
133 throw Error('No commit message has been specified.');
134 }
135 this.head.newCommits.push({message, files});
136 }
137
138 /** Handler for the `git fetch` command. */
139 private _fetch(rawArgs: string[]) {

Callers 1

runGracefulMethod · 0.95

Calls 1

pushMethod · 0.45

Tested by

no test coverage detected