mirror of
https://github.com/morten-olsen/mini-loader.git
synced 2026-02-08 01:36:26 +01:00
init
This commit is contained in:
21
packages/cli/src/commands/secrets/secrets.remove.ts
Normal file
21
packages/cli/src/commands/secrets/secrets.remove.ts
Normal file
@@ -0,0 +1,21 @@
|
||||
import { Command } from 'commander';
|
||||
import { createClient } from '../../client/client.js';
|
||||
import { step } from '../../utils/step.js';
|
||||
|
||||
const remove = new Command('remove');
|
||||
|
||||
remove
|
||||
.alias('rm')
|
||||
.argument('<id>')
|
||||
.action(async (id) => {
|
||||
const client = await step('Connecting to server', async () => {
|
||||
return createClient();
|
||||
});
|
||||
await step('Removing', async () => {
|
||||
await client.secrets.remove.mutate({
|
||||
id,
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
export { remove };
|
||||
Reference in New Issue
Block a user