From 2d1645957aa266df687e657bb7b996c7821f6e51 Mon Sep 17 00:00:00 2001 From: Dawid Dziurla Date: Thu, 26 Mar 2020 15:48:23 +0100 Subject: [PATCH] main: mount workspace directory and mv instead of cp --- main.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/main.js b/main.js index d34c75a..1907aa0 100644 --- a/main.js +++ b/main.js @@ -43,7 +43,7 @@ async function main() { await exec.exec("docker", [ "create", "--name", container, - "--volume", sourceDirectory + ":" + sourceDirectory, + "--volume", workspaceDirectory + ":" + workspaceDirectory, "--workdir", sourceDirectory, "--tty", image, @@ -66,9 +66,9 @@ async function main() { "tar", "--exclude-vcs", "--exclude", "./debian", - "--transform", `s/^\./${package}-${version}/`, + "--transform", `s/^${sourceDirectory}/${package}-${version}/`, "-cvzf", `${buildDirectory}/${package}_${version}.orig.tar.gz`, - "./" + sourceDirectory ]) core.endGroup() } @@ -105,7 +105,7 @@ async function main() { ]) core.endGroup() - core.startGroup("Copy artifacts") + core.startGroup("Move artifacts") await exec.exec("docker", [ "exec", container, @@ -115,7 +115,7 @@ async function main() { "-name", `${package}_${version}*.*`, "-type", "f", "-print", - "-exec", "cp", "{}", artifactsDirectory, ";" + "-exec", "mv", "{}", artifactsDirectory, ";" ]) core.endGroup() } catch (error) {