fixed bug with spreadsheet import

This commit is contained in:
GotthardG 2024-12-10 16:45:25 +01:00
parent c818cfc477
commit b4aa8ce344

View File

@ -109,8 +109,14 @@ async function fetchAndGenerate() {
}
}
const backendDirectory = path.resolve('/Users/gotthardg/PycharmProjects/heidi-v2/backend/app');
// Define backendDirectory based on ENVIRONMENT variable
const ENVIRONMENT = process.env.ENVIRONMENT || 'dev';
const backendDirectory = ENVIRONMENT === 'test'
? path.resolve('/home/jungfrau/heidi-v2/backend/app')
: path.resolve('/Users/gotthardg/PycharmProjects/heidi-v2/backend/app');
console.log(`👀 Watching for changes in ${backendDirectory}`);
const watcher = chokidar.watch(backendDirectory, { persistent: true, ignored: [SCHEMA_PATH, OUTPUT_DIRECTORY] });
watcher