mirror of
https://github.com/uniwhale-io/DefiLlama-yield-server.git
synced 2026-01-12 17:12:21 +08:00
* migration * remove balancer pools from exclusion list * bug fix serverless * remove timestamp from median, update for tests * update get distinct id controller * update distinctID controller, remove dep * move confirm into scripts * testing url * remove Pg suffix from lambda names * change to existing api host * add comments * revert service name, bucketsg * put pack fantom rpc * update package.lock
23 lines
451 B
JavaScript
23 lines
451 B
JavaScript
const readline = require('readline');
|
|
|
|
module.exports.confirm = (query) => {
|
|
const rl = readline.createInterface({
|
|
input: process.stdin,
|
|
output: process.stdout,
|
|
terminal: false,
|
|
});
|
|
|
|
return new Promise((resolve) =>
|
|
rl.question(query, (ans) => {
|
|
if (ans !== 'yes') {
|
|
rl.close();
|
|
console.log('Exiting');
|
|
process.exit(1);
|
|
} else {
|
|
rl.close();
|
|
resolve(ans);
|
|
}
|
|
})
|
|
);
|
|
};
|