@@ -51,8 +51,13 @@ export async function setConfig(key: string, value: string): Promise<void> {
5151 await exec . exec ( 'git' , [ 'config' , key , value ] ) ;
5252}
5353
54- export async function add ( pattern : string ) : Promise < void > {
55- await exec . exec ( 'git' , [ 'add' , '--verbose' , '--all' , pattern ] ) ;
54+ export async function add ( pattern : string , verbose : boolean ) : Promise < void > {
55+ let args : Array < string > = [ 'add' ] ;
56+ if ( verbose ) {
57+ args . push ( '--verbose' ) ;
58+ }
59+ args . push ( '--all' , pattern ) ;
60+ await exec . exec ( 'git' , args ) ;
5661}
5762
5863export async function commit ( allowEmptyCommit : boolean , author : string , message : string ) : Promise < void > {
@@ -69,7 +74,7 @@ export async function commit(allowEmptyCommit: boolean, author: string, message:
6974}
7075
7176export async function showStat ( ) : Promise < string > {
72- return await mexec . exec ( 'git' , [ 'show' , `--stat-count=2000 ` , 'HEAD' ] , true ) . then ( res => {
77+ return await mexec . exec ( 'git' , [ 'show' , `--stat-count=1000 ` , 'HEAD' ] , true ) . then ( res => {
7378 if ( res . stderr != '' && ! res . success ) {
7479 throw new Error ( res . stderr ) ;
7580 }
0 commit comments