From c2c3ef62ecabf6170ed6f81c50a21b9bbf698b9e Mon Sep 17 00:00:00 2001 From: develar Date: Tue, 31 May 2016 18:56:57 +0200 Subject: [PATCH] fix: log github publisher user and project #425 --- src/builder.ts | 7 ++++--- src/gitHubPublisher.ts | 2 +- test/src/winPackagerTest.ts | 2 +- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/src/builder.ts b/src/builder.ts index 67cb66dc57e..f81b6acba78 100644 --- a/src/builder.ts +++ b/src/builder.ts @@ -4,7 +4,7 @@ import { PublishOptions, Publisher, GitHubPublisher } from "./gitHubPublisher" import { executeFinally } from "./promise" import { Promise as BluebirdPromise } from "bluebird" import { InfoRetriever } from "./repositoryInfo" -import { log } from "./util" +import { log, warn } from "./util" import { Platform, Arch, archFromString } from "./metadata" //noinspection JSUnusedLocalSymbols @@ -17,10 +17,11 @@ export async function createPublisher(packager: Packager, options: BuildOptions, return null } - log("Cannot detect repository by .git/config") - throw new Error("Please specify 'repository' in the dev package.json ('" + packager.devPackageFile + "')") + warn("Cannot detect repository by .git/config") + throw new Error(`Please specify 'repository' in the dev package.json ('${packager.devPackageFile}')`) } else { + log(`Creating Github Publisher — user: ${info.user}, project: ${info.project}, version: ${packager.metadata.version}`) return new GitHubPublisher(info.user, info.project, packager.metadata.version, options.githubToken!, options.publish!) } } diff --git a/src/gitHubPublisher.ts b/src/gitHubPublisher.ts index fb0ef48a094..b630d886334 100644 --- a/src/gitHubPublisher.ts +++ b/src/gitHubPublisher.ts @@ -168,6 +168,6 @@ export class GitHubPublisher implements Publisher { } } - log("WARN: Cannot delete release " + this._releasePromise.value().id) + warn(`Cannot delete release ${this._releasePromise.value().id}`) } } \ No newline at end of file diff --git a/test/src/winPackagerTest.ts b/test/src/winPackagerTest.ts index 87da78146b8..7f8b2379df6 100755 --- a/test/src/winPackagerTest.ts +++ b/test/src/winPackagerTest.ts @@ -13,7 +13,7 @@ import { Arch } from "out" //noinspection JSUnusedLocalSymbols const __awaiter = require("out/awaiter") -test.ifNotCiOsx("win", () => assertPack("test-app-one", signed({ +test.ifDevOrWinCi("win", () => assertPack("test-app-one", signed({ targets: Platform.WINDOWS.createTarget(), }) ))