diff --git a/findFailures.js b/findFailures.js index af7b2a3678..657899730c 100644 --- a/findFailures.js +++ b/findFailures.js @@ -1,6 +1,9 @@ require('dotenv').config(); -const { owner, repo, fccBaseUrl, prBaseUrl } = require('./constants'); + +const path = require('path'); const fs = require('fs'); + +const { owner, repo, fccBaseUrl, prBaseUrl } = require('./constants'); const formatDate = require('date-fns/format'); const { saveToFile, openJSONFile } = require('./fileFunctions'); const { octokitConfig, octokitAuth } = require('./octokitConfig'); @@ -26,7 +29,7 @@ const errorsToFind = require('./failuresToFind.json'); console.log(`# of PRs Retrieved: ${openPRs.length}`); console.log(`PR Range: ${firstPR} - ${lastPR}`); const now = formatDate(new Date(), 'YYYY-MM-DDTHHmmss'); - const fileName = `data/openprs_statuses_urls_${firstPR}-${lastPR}_${now}.json`; + const fileName = path.resolve(__dirname, `./work-logs/openprs_statuses_urls_${firstPR}-${lastPR}_${now}.json`); saveToFile(fileName, JSON.stringify(openPRs)); console.log(`Data saved in file: ${fileName}`); diff --git a/labelOpenPrs.js b/labelOpenPrs.js index 12e8f3f50f..9824f3620e 100644 --- a/labelOpenPrs.js +++ b/labelOpenPrs.js @@ -30,7 +30,7 @@ const prPropsToGet = ['number', 'labels', 'user']; console.log(`# of PRs Retrieved: ${openPRs.length}`); console.log(`PR Range: ${firstPR} - ${lastPR}`); const now = formatDate(new Date(), 'YYYY-MM-DDTHHmmss'); - const fileName = path.resolve(__dirname, `./data/openprs_${firstPR}-${lastPR}_${now}.json`); + const fileName = path.resolve(__dirname, `./work-logs/openprs_${firstPR}-${lastPR}_${now}.json`); saveToFile(fileName, JSON.stringify(openPRs)); console.log(`Data saved in file: ${fileName}`); diff --git a/prProcessingLog.js b/prProcessingLog.js index 15e10e1cc3..35e004d5b1 100644 --- a/prProcessingLog.js +++ b/prProcessingLog.js @@ -11,7 +11,7 @@ class PrProcessingLog { this._finish = null; this._prs = {}; //path.resolve(__dirname, '../../../guide'); - this._logfile = path.resolve(__dirname, './data/open-prs-processed.json'); + this._logfile = path.resolve(__dirname, './work-logs/open-prs-processed.json'); } import() {