chore: use env variables in esbuilds
This commit is contained in:
parent
32e44f77a9
commit
93bbe615ba
2 changed files with 14 additions and 4 deletions
|
|
@ -1,11 +1,16 @@
|
||||||
const path = require("path");
|
const path = require("path");
|
||||||
const fs = require("fs");
|
const fs = require("fs");
|
||||||
const chalk = require("chalk");
|
const chalk = require("chalk");
|
||||||
|
let bench_path;
|
||||||
|
if (process.env.FRAPPE_BENCH_ROOT) {
|
||||||
|
bench_path = process.env.FRAPPE_BENCH_ROOT;
|
||||||
|
} else {
|
||||||
|
const frappe_path = path.resolve(__dirname, "..");
|
||||||
|
bench_path = path.resolve(frappe_path, "..", "..");
|
||||||
|
}
|
||||||
|
|
||||||
const frappe_path = path.resolve(__dirname, "..");
|
|
||||||
const bench_path = path.resolve(frappe_path, "..", "..");
|
|
||||||
const sites_path = path.resolve(bench_path, "sites");
|
|
||||||
const apps_path = path.resolve(bench_path, "apps");
|
const apps_path = path.resolve(bench_path, "apps");
|
||||||
|
const sites_path = path.resolve(bench_path, "sites");
|
||||||
const assets_path = path.resolve(sites_path, "assets");
|
const assets_path = path.resolve(sites_path, "assets");
|
||||||
const app_list = get_apps_list();
|
const app_list = get_apps_list();
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,12 @@
|
||||||
const fs = require("fs");
|
const fs = require("fs");
|
||||||
const path = require("path");
|
const path = require("path");
|
||||||
const redis = require("@redis/client");
|
const redis = require("@redis/client");
|
||||||
const bench_path = path.resolve(__dirname, "..", "..");
|
let bench_path;
|
||||||
|
if (process.env.FRAPPE_BENCH_ROOT) {
|
||||||
|
bench_path = process.env.FRAPPE_BENCH_ROOT;
|
||||||
|
} else {
|
||||||
|
bench_path = path.resolve(__dirname, "..", "..");
|
||||||
|
}
|
||||||
|
|
||||||
const dns = require("dns");
|
const dns = require("dns");
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue