Skip to content

Commit

Permalink
fix tsc lint errors
Browse files Browse the repository at this point in the history
  • Loading branch information
rhyek committed Mar 19, 2024
1 parent 1c9afb3 commit af726e3
Showing 1 changed file with 20 additions and 21 deletions.
41 changes: 20 additions & 21 deletions projects/scrape-txs/src/console.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,34 +12,33 @@ const { data: configJson } = await db
.executeTakeFirstOrThrow();
const config = configSchema.parse(configJson);

console.log('x', config.banks.bancoIndustrialGt);
program.option('-m, --month <months...>', 'Month(s) to scrape');

// program.option('-m, --month <months...>', 'Month(s) to scrape');
program.parse();

// program.parse();
const options = program.opts<{
month?: string[];
}>();

// const options = program.opts<{
// month?: string[];
// }>();
const months: Dayjs[] = [];

// const months: Dayjs[] = [];

// if (options.month) {
// months.push(...options.month.map((month) => dayjs(month)));
// } else {
// const today = dayjs(new Date());
// months.unshift(today);
// if (today.date() <= 10) {
// months.unshift(today.subtract(1, 'month'));
// }
// }
if (options.month) {
months.push(...options.month.map((month) => dayjs(month)));
} else {
const today = dayjs(new Date());
months.unshift(today);
if (today.date() <= 10) {
months.unshift(today.subtract(1, 'month'));
}
}

// // // console.log('config', config);

// await bancoIndustrialScrape({
// biConfig: config.banks.bancoIndustrialGt,
// months,
// });
await bancoIndustrialScrape({
biConfig: config.banks.bancoIndustrialGt,
months,
isLambda: false,
});

// // await updateYnab({
// // ynabConfig: config.ynab,
Expand Down

0 comments on commit af726e3

Please sign in to comment.