@h-rig/cli 0.0.6-alpha.15 → 0.0.6-alpha.150

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 (49) hide show
  1. package/README.md +6 -28
  2. package/bin/rig.js +16 -0
  3. package/package.json +14 -27
  4. package/dist/bin/build-rig-binaries.js +0 -107
  5. package/dist/bin/rig.js +0 -10076
  6. package/dist/src/commands/_authority-runs.js +0 -111
  7. package/dist/src/commands/_connection-state.js +0 -123
  8. package/dist/src/commands/_doctor-checks.js +0 -506
  9. package/dist/src/commands/_operator-surface.js +0 -157
  10. package/dist/src/commands/_operator-view.js +0 -449
  11. package/dist/src/commands/_parsers.js +0 -107
  12. package/dist/src/commands/_paths.js +0 -50
  13. package/dist/src/commands/_pi-install.js +0 -184
  14. package/dist/src/commands/_policy.js +0 -79
  15. package/dist/src/commands/_preflight.js +0 -482
  16. package/dist/src/commands/_probes.js +0 -13
  17. package/dist/src/commands/_run-driver-helpers.js +0 -289
  18. package/dist/src/commands/_server-client.js +0 -426
  19. package/dist/src/commands/_snapshot-upload.js +0 -318
  20. package/dist/src/commands/_task-picker.js +0 -56
  21. package/dist/src/commands/agent.js +0 -499
  22. package/dist/src/commands/browser.js +0 -890
  23. package/dist/src/commands/connect.js +0 -180
  24. package/dist/src/commands/dist.js +0 -402
  25. package/dist/src/commands/doctor.js +0 -516
  26. package/dist/src/commands/github.js +0 -281
  27. package/dist/src/commands/inbox.js +0 -160
  28. package/dist/src/commands/init.js +0 -1511
  29. package/dist/src/commands/inspect.js +0 -174
  30. package/dist/src/commands/inspector.js +0 -256
  31. package/dist/src/commands/plugin.js +0 -167
  32. package/dist/src/commands/profile-and-review.js +0 -178
  33. package/dist/src/commands/queue.js +0 -198
  34. package/dist/src/commands/remote.js +0 -507
  35. package/dist/src/commands/repo-git-harness.js +0 -221
  36. package/dist/src/commands/run.js +0 -893
  37. package/dist/src/commands/server.js +0 -373
  38. package/dist/src/commands/setup.js +0 -686
  39. package/dist/src/commands/task-report-bug.js +0 -1083
  40. package/dist/src/commands/task-run-driver.js +0 -2442
  41. package/dist/src/commands/task.js +0 -1476
  42. package/dist/src/commands/test.js +0 -39
  43. package/dist/src/commands/workspace.js +0 -123
  44. package/dist/src/commands.js +0 -9755
  45. package/dist/src/index.js +0 -10094
  46. package/dist/src/launcher.js +0 -133
  47. package/dist/src/report-bug.js +0 -260
  48. package/dist/src/runner.js +0 -273
  49. package/dist/src/withMutedConsole.js +0 -42
@@ -1,42 +0,0 @@
1
- // @bun
2
- // packages/cli/src/withMutedConsole.ts
3
- function isPromise(value) {
4
- if (typeof value !== "object" && typeof value !== "function") {
5
- return false;
6
- }
7
- return value !== null && typeof value.then === "function";
8
- }
9
- function withMutedConsole(mute, fn) {
10
- if (!mute) {
11
- return fn();
12
- }
13
- const originalLog = console.log;
14
- const originalWarn = console.warn;
15
- const originalInfo = console.info;
16
- const restore = () => {
17
- console.log = originalLog;
18
- console.warn = originalWarn;
19
- console.info = originalInfo;
20
- };
21
- console.log = () => {};
22
- console.warn = () => {};
23
- console.info = () => {};
24
- try {
25
- const result = fn();
26
- if (isPromise(result)) {
27
- return result.finally(restore);
28
- }
29
- restore();
30
- return result;
31
- } catch (error) {
32
- restore();
33
- throw error;
34
- } finally {
35
- if (console.log === originalLog) {
36
- restore();
37
- }
38
- }
39
- }
40
- export {
41
- withMutedConsole
42
- };