@stacksjs/buddy 0.58.73 → 0.59.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (57) hide show
  1. package/dist/chunk-d2428b387d843985.js +2016 -0
  2. package/dist/cli.d.ts +1 -0
  3. package/dist/cli.js +23 -9
  4. package/dist/commands/build.d.ts +2 -0
  5. package/dist/commands/changelog.d.ts +2 -0
  6. package/dist/commands/clean.d.ts +2 -0
  7. package/dist/commands/cloud.d.ts +2 -0
  8. package/dist/commands/commit.d.ts +2 -0
  9. package/dist/commands/configure.d.ts +2 -0
  10. package/dist/commands/create.d.ts +2 -0
  11. package/dist/commands/deploy.d.ts +2 -0
  12. package/dist/commands/dev.d.ts +3 -0
  13. package/dist/commands/dns.d.ts +2 -0
  14. package/dist/commands/domains.d.ts +2 -0
  15. package/dist/commands/fresh.d.ts +2 -0
  16. package/dist/commands/generate.d.ts +2 -0
  17. package/dist/commands/http.d.ts +2 -0
  18. package/dist/commands/index.d.ts +31 -0
  19. package/dist/commands/install.d.ts +2 -0
  20. package/dist/commands/key.d.ts +2 -0
  21. package/dist/commands/lint.d.ts +2 -0
  22. package/dist/commands/list.d.ts +2 -0
  23. package/dist/commands/make.d.ts +2 -0
  24. package/dist/commands/migrate.d.ts +2 -0
  25. package/dist/commands/ports.d.ts +2 -0
  26. package/dist/commands/prepublish.d.ts +2 -0
  27. package/dist/commands/projects.d.ts +2 -0
  28. package/dist/commands/release.d.ts +2 -0
  29. package/dist/commands/seed.d.ts +2 -0
  30. package/dist/commands/setup.d.ts +4 -0
  31. package/dist/commands/test.d.ts +2 -0
  32. package/dist/commands/tinker.d.ts +2 -0
  33. package/dist/commands/types.d.ts +2 -0
  34. package/dist/commands/upgrade.d.ts +2 -0
  35. package/dist/commands/version.d.ts +2 -0
  36. package/dist/index.d.ts +1 -0
  37. package/dist/index.js +2 -5
  38. package/dist/stacks +0 -0
  39. package/package.json +1 -3
  40. package/src/cli.ts +18 -13
  41. package/src/commands/add.ts +1 -1
  42. package/src/commands/commit.ts +1 -1
  43. package/src/commands/deploy.ts +1 -1
  44. package/src/commands/dev.ts +1 -3
  45. package/src/commands/index.ts +0 -1
  46. package/src/commands/key.ts +1 -1
  47. package/src/commands/list.ts +1 -1
  48. package/src/commands/make.ts +28 -2
  49. package/src/commands/ports.ts +135 -28
  50. package/src/commands/prepublish.ts +1 -1
  51. package/src/commands/projects.ts +2 -3
  52. package/src/commands/setup.ts +1 -0
  53. package/src/commands/types.ts +1 -1
  54. package/dist/chunk-1a569f35f66ae151.js +0 -10945
  55. package/dist/chunk-bf054cfbc9cf2201.js +0 -993
  56. package/src/commands/check.ts +0 -45
  57. /package/dist/{chunk-0455e53fab4244b1.js → chunk-970e033f764e29fc.js} +0 -0
@@ -1,45 +0,0 @@
1
- import process from 'node:process'
2
- import type { CLI, CheckOptions } from '@stacksjs/types'
3
- import { ExitCode } from '@stacksjs/types'
4
- import { Action } from '@stacksjs/enums'
5
- import { runAction } from '@stacksjs/actions'
6
- import { log } from 'stacks/logging'
7
- import { intro, outro } from 'stacks/cli'
8
-
9
- export function check(buddy: CLI) {
10
- const descriptions = {
11
- command: 'Let buddy check your project for potential issues and misconfigurations',
12
- ports: 'Check if the ports are available',
13
- project: 'Target a specific project',
14
- verbose: 'Enable verbose output',
15
- }
16
-
17
- buddy
18
- .command('check [type]', descriptions.command)
19
- .option('--ports', descriptions.ports)
20
- .option('-p, --project', descriptions.project, { default: false })
21
- .option('--verbose', descriptions.verbose, { default: false })
22
- .action(async (type: string | undefined, options: CheckOptions) => {
23
- log.debug('Running `buddy check [type]` ...', options)
24
-
25
- const perf = await intro('buddy check [type]')
26
-
27
- switch (type) {
28
- case 'ports':
29
- await runAction(Action.CheckPorts)
30
- return
31
- }
32
-
33
- if (options.ports)
34
- await runAction(Action.CheckPorts, options)
35
-
36
- // await runAction(Action.Prepublish, options)
37
- await outro('Exited', { startTime: perf, useSeconds: true })
38
- process.exit(ExitCode.Success)
39
- })
40
-
41
- buddy.on('check:*', () => {
42
- console.error('Invalid command: %s\nSee --help for a list of available commands.', buddy.args.join(' '))
43
- process.exit(1)
44
- })
45
- }