Changed confusing -g flag to -c

This commit is contained in:
Mike Lynch 2025-03-12 22:09:34 +00:00
parent 270bcc9cfa
commit 790f5f1661

View File

@ -112,7 +112,6 @@ async function post_image(image, alt_text, cf) {
body: JSON.stringify({ media_ids: [ media_id ] })
});
const bodyjson2 = await resp2.text();
console.log(bodyjson2);
}
@ -120,9 +119,9 @@ async function main() {
const argv = yargs(hideBin(process.argv))
.usage("Usage: -s SIZE -o output.png -c config.json")
.default('s', 1200)
.default('g', 'config.json').argv;
.default('c', 'config.json').argv;
const cfjson = await promises.readFile(argv.g);
const cfjson = await promises.readFile(argv.c);
const cf = JSON.parse(cfjson);
const fn = argv.o || String(Date.now()) + '.png';
@ -153,4 +152,4 @@ async function main() {
main();
main();