@messari/cli
Version:
Messari Crypto CLI (mcrypto) is a tool for getting cryptocurrency market data, news, and more!
24 lines (23 loc) • 920 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
// // Set nconfig env variables in config file
// export const initializeNconf = () => {
// nconf.argv().env().file({ file: "./config.json" });
// nconf.defaults({
// "apiKey": null
// });
// nconf.save((error: Error) => {
// fs.readFile('./config.json', (_, data) => void console.dir(JSON.parse(data.toString())));
// if (error) console.error(error);
// });
// }
// export const setApiConfiguration = (apiKey: string) => {
// nconf.argv().env().file({ file: "./config.json" });
// // Store API key locally for subsequent commands/api calls
// nconf.set("apiKey", apiKey);
// nconf.save((error: Error) => {
// fs.readFile('./config.json', (_, data) => void console.dir(JSON.parse(data.toString())));
// if (error) console.error(error);
// });
// }
// export const apiKey: string = nconf.get('apiKey');