gitmate-cli
Version:
An AI-powered Git assistant that helps you with Git commands using natural language
16 lines (15 loc) • 455 B
JavaScript
class Animation {
animation;
showAnimation() {
const frames = ["⠋", "⠙", "⠹", "⠸", "⠼", "⠴", "⠦", "⠧", "⠇", "⠏"];
let i = 0;
this.animation = setInterval(() => {
process.stdout.write(`\r${frames[i]} Processing your git command...`);
i = (i + 1) % frames.length;
}, 80);
}
stopAnimation() {
clearInterval(this.animation);
}
}
export default Animation;