From ba8ab67b82c5c7df61d53624d7795df0d6cad093 Mon Sep 17 00:00:00 2001 From: Brandon Roberts Date: Tue, 25 Apr 2017 19:33:52 -0500 Subject: [PATCH] fix(build): Fixed deployment of latest master as commit --- build/tasks.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/build/tasks.ts b/build/tasks.ts index 188a06102e..eccf85c260 100644 --- a/build/tasks.ts +++ b/build/tasks.ts @@ -217,7 +217,11 @@ export async function publishToRepo(config: Config) { await process.chdir(`${REPO_DIR}`); await util.git([`init`]); await util.git([`remote add origin ${REPO_URL}`]); + await util.git(['fetch origin master --depth=1']); + await util.git(['checkout origin/master']); + await util.git(['checkout -b master']); await process.chdir('../../'); + await util.cmd('rm -rf', [`${REPO_DIR}/*`]); await util.cmd('cp', [`-R ${SOURCE_DIR}/* ${REPO_DIR}/`]); await process.chdir(`${REPO_DIR}`); await util.git([`config user.name "${COMMITTER_USER_NAME}"`]);