12 lines
305 B
TypeScript
12 lines
305 B
TypeScript
import { program as app, Command } from '@/program.ts';
|
|
import { getConfig, writeConfig } from '@/module/index.ts';
|
|
|
|
const command = new Command('logout')
|
|
.description('')
|
|
.action(async () => {
|
|
const config = getConfig();
|
|
writeConfig({ ...config, token: '' });
|
|
});
|
|
|
|
app.addCommand(command);
|