Remove hello command
This commit is contained in:
parent
2a53b55801
commit
0df9705f97
4 changed files with 0 additions and 64 deletions
|
@ -1,25 +0,0 @@
|
|||
import {Args, Command, Flags} from '@oclif/core'
|
||||
|
||||
export default class Hello extends Command {
|
||||
static description = 'Say hello'
|
||||
|
||||
static examples = [
|
||||
`$ oex hello friend --from oclif
|
||||
hello friend from oclif! (./src/commands/hello/index.ts)
|
||||
`,
|
||||
]
|
||||
|
||||
static flags = {
|
||||
from: Flags.string({char: 'f', description: 'Who is saying hello', required: true}),
|
||||
}
|
||||
|
||||
static args = {
|
||||
person: Args.string({description: 'Person to say hello to', required: true}),
|
||||
}
|
||||
|
||||
async run(): Promise<void> {
|
||||
const {args, flags} = await this.parse(Hello)
|
||||
|
||||
this.log(`hello ${args.person} from ${flags.from}! (./src/commands/hello/index.ts)`)
|
||||
}
|
||||
}
|
|
@ -1,19 +0,0 @@
|
|||
import {Command} from '@oclif/core'
|
||||
|
||||
export default class World extends Command {
|
||||
static description = 'Say hello world'
|
||||
|
||||
static examples = [
|
||||
`<%= config.bin %> <%= command.id %>
|
||||
hello world! (./src/commands/hello/world.ts)
|
||||
`,
|
||||
]
|
||||
|
||||
static flags = {}
|
||||
|
||||
static args = {}
|
||||
|
||||
async run(): Promise<void> {
|
||||
this.log('hello world! (./src/commands/hello/world.ts)')
|
||||
}
|
||||
}
|
|
@ -1,10 +0,0 @@
|
|||
import {expect, test} from '@oclif/test'
|
||||
|
||||
describe('hello', () => {
|
||||
test
|
||||
.stdout()
|
||||
.command(['hello', 'friend', '--from=oclif'])
|
||||
.it('runs hello cmd', ctx => {
|
||||
expect(ctx.stdout).to.contain('hello friend from oclif!')
|
||||
})
|
||||
})
|
|
@ -1,10 +0,0 @@
|
|||
import {expect, test} from '@oclif/test'
|
||||
|
||||
describe('hello world', () => {
|
||||
test
|
||||
.stdout()
|
||||
.command(['hello:world'])
|
||||
.it('runs hello world cmd', ctx => {
|
||||
expect(ctx.stdout).to.contain('hello world!')
|
||||
})
|
||||
})
|
Loading…
Reference in a new issue