Skip to content

feat: log command errors if cmd-run fails for any reason#126

Merged
reubenmiller merged 1 commit intothin-edge:mainfrom
reubenmiller:feat-log-command-errors
Jan 12, 2026
Merged

feat: log command errors if cmd-run fails for any reason#126
reubenmiller merged 1 commit intothin-edge:mainfrom
reubenmiller:feat-log-command-errors

Conversation

@reubenmiller
Copy link
Copy Markdown
Contributor

@reubenmiller reubenmiller commented Jan 12, 2026

Improve visibility of invalid command which use the cmd-run remark plugin to generate the code block.

This functionality was already existing it was just previously turned off because the tedge binary was not installed by default on the build server resulting in a flood of errors.

Resolves #110

Example warning

Failed to run command {
  meta: { command: 'tedge-write2 --help', title: 'tedge-write --help' },
  file: '/Users/reubenmiller/dev/projects/thin-edge.io/code/tedge-docs/versioned_docs/version-1.7.1/references/tedge-write.md',
  error: 'Error: Command failed: docker run --rm ghcr.io/thin-edge/tedge:latest tedge-write2 --help'
}

Logging the errors will improve the visibility of invalid commands
@reubenmiller reubenmiller merged commit 6b0ef6d into thin-edge:main Jan 12, 2026
@reubenmiller reubenmiller deleted the feat-log-command-errors branch January 12, 2026 19:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Have thin-edge binaries present in the environment where docs are built for production/warn if command block doesn't have a fallback value

1 participant