git: cleanup tag

This commit is contained in:
Joao Moreno
2017-08-10 15:44:10 +02:00
parent 0bd753f8a1
commit 37de7e182f
5 changed files with 7 additions and 19 deletions

View File

@@ -677,13 +677,13 @@ export class Repository {
}
}
async tag(name: string, message: string, lightweight: boolean): Promise<void> {
async tag(name: string, message?: string): Promise<void> {
let args = ['tag'];
if (lightweight) {
args.push(name);
if (message) {
args = [...args, '-a', name, '-m', message];
} else {
args = args.concat(['-a', name, '-m', message]);
args = [...args, name];
}
await this.run(args);