Skip to content

Commit

Permalink
clean up errors
Browse files Browse the repository at this point in the history
cherriechang committed Oct 30, 2024
1 parent d02f625 commit 9d5215e
Showing 2 changed files with 4 additions and 9 deletions.
9 changes: 4 additions & 5 deletions packages/config/generateCitation.js
Original file line number Diff line number Diff line change
@@ -16,14 +16,13 @@ export default function generateCitation() {
const rawCff = fs.readFileSync("./CITATION.cff", "utf-8").toString();
const cffData = yaml.parse(rawCff);
if (cffData["preferred-citation"]) {
console.log("Found 'preferred-citation' in CITATION.cff");
preferredCitation = true;
} else {
console.log("No 'preferred-citation' found in CITATION.cff");
}
return yaml.stringify(rawCff);
} catch (error) {
console.log(`Error finding CITATION.cff: ${error.message}`);
console.log(
`No CITATION.cff file found: ${error.message}. If you would like to include a citation, please create a CITATION.cff file in the root of your repository.`
);
return null;
}
})();
@@ -61,7 +60,7 @@ export default function generateCitation() {
});
return citationBibtex;
} catch (error) {
console.log(`Error converting CITATION.cff to bibtex string: ${error.message}`);
console.log(`Error converting CITATION.cff to BibTex string: ${error.message}`);
return null;
}
})();
4 changes: 0 additions & 4 deletions packages/config/rollup.js
Original file line number Diff line number Diff line change
@@ -45,10 +45,6 @@ const makeConfig = ({

/** @type{import("rollup-plugin-esbuild").Options} */
const esBuildPluginOptions = {
// define: {
// __APACITATION_: JSON.stringify(citationData.apa),
// __BIBTEXCITATION__: JSON.stringify(citationData.bibtex),
// },
loaders: { ".json": "json" },
};

0 comments on commit 9d5215e

Please sign in to comment.