Skip to content

Commit c16cc5b

Browse files
Revert "feat: improve copy files from build_files folder (#927)"
This reverts commit 7d3a62f.
1 parent a0fc966 commit c16cc5b

1 file changed

Lines changed: 6 additions & 10 deletions

File tree

daemon/git.ts

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ const SOURCE_PATH = Deno.env.get("SOURCE_ASSET_PATH");
1818
const DEFAULT_TRACKING_BRANCH = Deno.env.get("DECO_TRACKING_BRANCH") ?? "main";
1919
const REPO_URL = Deno.env.get("DECO_REPO_URL");
2020
const GITHUB_APP_KEY = Deno.env.get("GITHUB_APP_KEY");
21-
const BUILD_FILES_DIR = Deno.env.get("BUILD_FILES_DIR");
2221
const ADMIN_DOMAIN = "https://admin.deco.cx";
2322

2423
export const lockerGitAPI = createLocker();
@@ -531,16 +530,13 @@ export const ensureGit = async ({ site }: Pick<Options, "site">) => {
531530
.submoduleInit()
532531
.submoduleUpdate(["--depth", "1"]);
533532

534-
// Copy build files if BUILD_FILES_DIR is specified
535-
if (BUILD_FILES_DIR) {
536-
const copyBuildFiles = new Deno.Command("cp", {
537-
args: ["-r", BUILD_FILES_DIR + "/.", "."],
538-
});
533+
const copyBuildFiles = new Deno.Command("cp", {
534+
args: ["-r", Deno.env.get("HOME") + "/build-files/.npmrc", "."],
535+
});
539536

540-
const copy = await copyBuildFiles.output();
541-
console.log("stdout", new TextDecoder().decode(copy.stdout));
542-
console.log("stderr", new TextDecoder().decode(copy.stderr));
543-
}
537+
const copy = await copyBuildFiles.output();
538+
console.log("stdout", new TextDecoder().decode(copy.stdout));
539+
console.log("stderr", new TextDecoder().decode(copy.stderr));
544540
};
545541

546542
await assertNoIndexLock();

0 commit comments

Comments
 (0)