Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package rumdl for openSUSE:Factory checked in at 2026-01-23 17:33:43 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/rumdl (Old) and /work/SRC/openSUSE:Factory/.rumdl.new.1928 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "rumdl" Fri Jan 23 17:33:43 2026 rev:23 rq:1328791 version:0.0.224 Changes: -------- --- /work/SRC/openSUSE:Factory/rumdl/rumdl.changes 2026-01-22 15:19:07.622601600 +0100 +++ /work/SRC/openSUSE:Factory/.rumdl.new.1928/rumdl.changes 2026-01-23 17:33:57.964157492 +0100 @@ -1,0 +2,16 @@ +Fri Jan 23 06:35:24 UTC 2026 - Johannes Kastl <[email protected]> + +- Update to version 0.0.224: + * Added + - GitHub Action: fail-on-error and output-file inputs (#324, + #325) + - fail-on-error: Control whether the workflow fails on + violations (default: true) + - output-file: Write lint results to a file for use in + subsequent steps + - LSP: source.fixAll.rumdl code action for fix-on-save + - Enables VS Code's "Fix All on Save" feature for rumdl + - Configure with editor.codeActionsOnSave: { + "source.fixAll.rumdl": "explicit" } + +------------------------------------------------------------------- Old: ---- rumdl-0.0.223.obscpio New: ---- rumdl-0.0.224.obscpio ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ rumdl.spec ++++++ --- /var/tmp/diff_new_pack.p34xTq/_old 2026-01-23 17:33:59.188207937 +0100 +++ /var/tmp/diff_new_pack.p34xTq/_new 2026-01-23 17:33:59.188207937 +0100 @@ -17,7 +17,7 @@ Name: rumdl -Version: 0.0.223 +Version: 0.0.224 Release: 0 Summary: Markdown Linter written in Rust License: MIT ++++++ _service ++++++ --- /var/tmp/diff_new_pack.p34xTq/_old 2026-01-23 17:33:59.268211234 +0100 +++ /var/tmp/diff_new_pack.p34xTq/_new 2026-01-23 17:33:59.280211729 +0100 @@ -3,7 +3,7 @@ <param name="url">https://github.com/rvben/rumdl.git</param> <param name="scm">git</param> <param name="submodules">enable</param> - <param name="revision">v0.0.223</param> + <param name="revision">v0.0.224</param> <param name="match-tag">v*.*.*</param> <param name="versionformat">@PARENT_TAG@</param> <param name="versionrewrite-pattern">v(.*)</param> ++++++ _servicedata ++++++ --- /var/tmp/diff_new_pack.p34xTq/_old 2026-01-23 17:33:59.320213377 +0100 +++ /var/tmp/diff_new_pack.p34xTq/_new 2026-01-23 17:33:59.340214202 +0100 @@ -1,6 +1,6 @@ <servicedata> <service name="tar_scm"> <param name="url">https://github.com/rvben/rumdl.git</param> - <param name="changesrevision">7dfe530feec9ad5cb0b379844680836c523db0e7</param></service></servicedata> + <param name="changesrevision">265158ecf14a4c7ca397550b82fe1a5651acddd2</param></service></servicedata> (No newline at EOF) ++++++ rumdl-0.0.223.obscpio -> rumdl-0.0.224.obscpio ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/rumdl-0.0.223/.github/workflows/test-action.yml new/rumdl-0.0.224/.github/workflows/test-action.yml --- old/rumdl-0.0.223/.github/workflows/test-action.yml 2026-01-21 23:39:56.000000000 +0100 +++ new/rumdl-0.0.224/.github/workflows/test-action.yml 2026-01-22 14:16:21.000000000 +0100 @@ -67,6 +67,117 @@ exit 1 fi + test-informational-mode: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v6 + - name: Run action with fail-on-error=false (should succeed despite violations) + uses: ./ + with: + path: __tests__/fixtures/malformed/ + fail-on-error: "false" + + test-output-file: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v6 + - name: Run action with output-file + uses: ./ + with: + path: __tests__/fixtures/clean/ + output-file: lint-results.txt + - name: Verify output file was created + run: | + if [ ! -f lint-results.txt ]; then + echo "Output file was not created" + exit 1 + fi + echo "Output file contents:" + cat lint-results.txt + + test-output-file-with-violations: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v6 + - name: Run action with output-file on malformed markdown + id: lint-malformed + continue-on-error: true + uses: ./ + with: + path: __tests__/fixtures/malformed/ + output-file: violations.txt + - name: Verify output file contains violations + run: | + if [ ! -f violations.txt ]; then + echo "Output file was not created" + exit 1 + fi + if ! grep -q "MD" violations.txt; then + echo "Output file should contain MD rule violations" + cat violations.txt + exit 1 + fi + echo "Output file contains violations as expected:" + cat violations.txt + + test-output-file-subdirectory: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v6 + - name: Run action with output-file in subdirectory + uses: ./ + with: + path: __tests__/fixtures/clean/ + output-file: results/subdir/lint-output.txt + - name: Verify output file was created in subdirectory + run: | + if [ ! -f results/subdir/lint-output.txt ]; then + echo "Output file was not created in subdirectory" + exit 1 + fi + echo "Output file created in subdirectory successfully" + + test-combined-informational-with-output: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v6 + - name: Run action with both fail-on-error=false and output-file + uses: ./ + with: + path: __tests__/fixtures/malformed/ + fail-on-error: "false" + output-file: informational-results.txt + - name: Verify output file contains violations but action succeeded + run: | + if [ ! -f informational-results.txt ]; then + echo "Output file was not created" + exit 1 + fi + if ! grep -q "MD" informational-results.txt; then + echo "Output file should contain MD rule violations" + exit 1 + fi + echo "Combined mode works: violations captured, action succeeded" + + test-invalid-fail-on-error: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v6 + - name: Run action with invalid fail-on-error value (should fail) + id: should-fail + continue-on-error: true + uses: ./ + with: + path: __tests__/fixtures/clean/ + fail-on-error: "maybe" + - name: Verify action failed with validation error + run: | + if [ "${{ steps.should-fail.outcome }}" == "success" ]; then + echo "Expected failure but got success" + exit 1 + fi + echo "Action correctly rejected invalid fail-on-error value" + all-tests-passed: runs-on: ubuntu-latest needs: @@ -75,6 +186,12 @@ - test-with-config - test-annotations - test-expected-failure + - test-informational-mode + - test-output-file + - test-output-file-with-violations + - test-output-file-subdirectory + - test-combined-informational-with-output + - test-invalid-fail-on-error if: always() steps: - name: All tests passed diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/rumdl-0.0.223/CHANGELOG.md new/rumdl-0.0.224/CHANGELOG.md --- old/rumdl-0.0.223/CHANGELOG.md 2026-01-21 23:39:56.000000000 +0100 +++ new/rumdl-0.0.224/CHANGELOG.md 2026-01-22 14:16:21.000000000 +0100 @@ -7,6 +7,18 @@ ## [Unreleased] +## [0.0.224] - 2026-01-22 + +### Added + +- **GitHub Action: `fail-on-error` and `output-file` inputs** ([#324](https://github.com/rvben/rumdl/issues/324), [#325](https://github.com/rvben/rumdl/issues/325)) + - `fail-on-error`: Control whether the workflow fails on violations (default: `true`) + - `output-file`: Write lint results to a file for use in subsequent steps + +- **LSP: `source.fixAll.rumdl` code action for fix-on-save** + - Enables VS Code's "Fix All on Save" feature for rumdl + - Configure with `editor.codeActionsOnSave: { "source.fixAll.rumdl": "explicit" }` + ## [0.0.223] - 2026-01-21 ### Added diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/rumdl-0.0.223/Cargo.lock new/rumdl-0.0.224/Cargo.lock --- old/rumdl-0.0.223/Cargo.lock 2026-01-21 23:39:56.000000000 +0100 +++ new/rumdl-0.0.224/Cargo.lock 2026-01-22 14:16:21.000000000 +0100 @@ -2050,7 +2050,7 @@ [[package]] name = "rumdl" -version = "0.0.223" +version = "0.0.224" dependencies = [ "anyhow", "assert_cmd", diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/rumdl-0.0.223/Cargo.toml new/rumdl-0.0.224/Cargo.toml --- old/rumdl-0.0.223/Cargo.toml 2026-01-21 23:39:56.000000000 +0100 +++ new/rumdl-0.0.224/Cargo.toml 2026-01-22 14:16:21.000000000 +0100 @@ -1,6 +1,6 @@ [package] name = "rumdl" -version = "0.0.223" +version = "0.0.224" edition = "2024" rust-version = "1.91.0" description = "A fast Markdown linter written in Rust (Ru(st) MarkDown Linter)" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/rumdl-0.0.223/README.md new/rumdl-0.0.224/README.md --- old/rumdl-0.0.223/README.md 2026-01-21 23:39:56.000000000 +0100 +++ new/rumdl-0.0.224/README.md 2026-01-22 14:16:21.000000000 +0100 @@ -5,12 +5,21 @@  [](https://github.com/rvben/rumdl/actions) -[](https://opensource.org/licenses/MIT) [](https://crates.io/crates/rumdl) -[](https://pypi.org/project/rumdl/) [](https://github.com/rvben/rumdl/releases/latest) [](https://github.com/rvben/rumdl/stargazers) [](https://discord.gg/ADTJFSFUyn) [](https://github.com/sponsors/rvben) +[](https://opensource.org/licenses/MIT) +[](https://crates.io/crates/rumdl) +[](https://pypi.org/project/rumdl/) +[](https://github.com/rvben/rumdl/releases/latest) +[](https://github.com/rvben/rumdl/stargazers) +[](https://discord.gg/ADTJFSFUyn) +[](https://github.com/sponsors/rvben) ## A modern Markdown linter and formatter, built for speed with Rust -| [**Docs**](https://github.com/rvben/rumdl/blob/main/docs/RULES.md) | [**Rules**](https://github.com/rvben/rumdl/blob/main/docs/RULES.md) | [**Configuration**](#configuration) | [**vs markdownlint**](https://github.com/rvben/rumdl/blob/main/docs/markdownlint-comparison.md) | +| [**Docs**](https://rumdl.dev) +| [**Rules**](https://rumdl.dev/RULES) +| [**Configuration**](https://rumdl.dev/global-settings) +| [**Markdown Flavors**](https://rumdl.dev/flavors) +| [**vs markdownlint**](https://rumdl.dev/markdownlint-comparison) | </div> @@ -157,7 +166,7 @@ uv tool install rumdl # Or run without installing -uv tool run rumdl check . +uvx rumdl check . ``` ### Using mise diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/rumdl-0.0.223/action.yml new/rumdl-0.0.224/action.yml --- old/rumdl-0.0.223/action.yml 2026-01-21 23:39:56.000000000 +0100 +++ new/rumdl-0.0.224/action.yml 2026-01-22 14:16:21.000000000 +0100 @@ -25,6 +25,14 @@ Possible values: logs (default), annotations required: false default: "logs" + fail-on-error: + description: "Fail the workflow if violations are found (default: true)" + required: false + default: "true" + output-file: + description: "Write results to this file path (optional)" + required: false + default: "" runs: using: "composite" @@ -37,3 +45,5 @@ GHA_RUMDL_PATH: ${{ inputs.path }} GHA_RUMDL_CONFIG: ${{ inputs.config }} GHA_RUMDL_REPORT_TYPE: ${{ inputs.report-type }} + GHA_RUMDL_FAIL_ON_ERROR: ${{ inputs.fail-on-error }} + GHA_RUMDL_OUTPUT_FILE: ${{ inputs.output-file }} diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/rumdl-0.0.223/scripts/rumdl-action.sh new/rumdl-0.0.224/scripts/rumdl-action.sh --- old/rumdl-0.0.223/scripts/rumdl-action.sh 2026-01-21 23:39:56.000000000 +0100 +++ new/rumdl-0.0.224/scripts/rumdl-action.sh 2026-01-22 14:16:21.000000000 +0100 @@ -51,6 +51,21 @@ ;; esac +# Validate fail-on-error input early (fail-fast) +fail_on_error="${GHA_RUMDL_FAIL_ON_ERROR:-true}" +if [ "$fail_on_error" != "true" ] && [ "$fail_on_error" != "false" ]; then + echo "::error::Invalid fail-on-error value: $fail_on_error (must be 'true' or 'false')" + exit 1 +fi + +# Log settings for visibility +if [ "$fail_on_error" = "false" ]; then + echo "Informational mode: violations will not fail the workflow" +fi +if [ -n "${GHA_RUMDL_OUTPUT_FILE:-}" ]; then + echo "Output file: $GHA_RUMDL_OUTPUT_FILE" +fi + # Run rumdl and capture output set +e results=$(rumdl check "$lint_path" "${rumdl_args[@]}" 2>&1) @@ -60,9 +75,31 @@ # Always print output echo "$results" +# Write to output file if requested +if [ -n "${GHA_RUMDL_OUTPUT_FILE:-}" ]; then + output_dir=$(dirname "$GHA_RUMDL_OUTPUT_FILE") + if [ "$output_dir" != "." ] && [ ! -d "$output_dir" ]; then + mkdir -p "$output_dir" + fi + if ! echo "$results" > "$GHA_RUMDL_OUTPUT_FILE"; then + echo "::error::Failed to write results to: $GHA_RUMDL_OUTPUT_FILE" + exit 1 + fi + echo "Results written to: $GHA_RUMDL_OUTPUT_FILE" +fi + # For annotations mode, re-print annotations for GitHub to pick up if [ "$GHA_RUMDL_REPORT_TYPE" = "annotations" ] && [ $exit_code -ne 0 ]; then echo "$results" | grep '::' || true fi -exit $exit_code +# Control exit behavior based on fail-on-error setting +if [ "$fail_on_error" = "true" ]; then + exit $exit_code +else + # Informational mode: always exit 0, but report if violations were found + if [ $exit_code -ne 0 ]; then + echo "::notice::Lint violations found (informational mode, not failing workflow)" + fi + exit 0 +fi diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/rumdl-0.0.223/src/lsp/server.rs new/rumdl-0.0.224/src/lsp/server.rs --- old/rumdl-0.0.223/src/lsp/server.rs 2026-01-21 23:39:56.000000000 +0100 +++ new/rumdl-0.0.224/src/lsp/server.rs 2026-01-22 14:16:21.000000000 +0100 @@ -857,7 +857,7 @@ let fix_all_action = CodeAction { title: format!("Fix all rumdl issues ({total_fixable} fixable)"), - kind: Some(CodeActionKind::QUICKFIX), + kind: Some(CodeActionKind::new("source.fixAll.rumdl")), diagnostics: Some(Vec::new()), edit: Some(WorkspaceEdit { changes: Some( @@ -1134,7 +1134,15 @@ include_text: Some(false), })), })), - code_action_provider: Some(CodeActionProviderCapability::Simple(true)), + code_action_provider: Some(CodeActionProviderCapability::Options(CodeActionOptions { + code_action_kinds: Some(vec![ + CodeActionKind::QUICKFIX, + CodeActionKind::SOURCE_FIX_ALL, + CodeActionKind::new("source.fixAll.rumdl"), + ]), + work_done_progress_options: WorkDoneProgressOptions::default(), + resolve_provider: None, + })), document_formatting_provider: Some(OneOf::Left(true)), document_range_formatting_provider: Some(OneOf::Left(true)), diagnostic_provider: Some(DiagnosticServerCapabilities::Options(DiagnosticOptions { @@ -1694,12 +1702,39 @@ async fn code_action(&self, params: CodeActionParams) -> JsonRpcResult<Option<CodeActionResponse>> { let uri = params.text_document.uri; let range = params.range; + let requested_kinds = params.context.only; if let Some(text) = self.get_document_content(&uri).await { match self.get_code_actions(&uri, &text, range).await { Ok(actions) => { - let response: Vec<CodeActionOrCommand> = - actions.into_iter().map(CodeActionOrCommand::CodeAction).collect(); + // Filter actions by requested kinds (if specified and non-empty) + // LSP spec: "If provided with no kinds, all supported kinds are returned" + // LSP code action kinds are hierarchical: source.fixAll.rumdl matches source.fixAll + let filtered_actions = if let Some(ref kinds) = requested_kinds + && !kinds.is_empty() + { + actions + .into_iter() + .filter(|action| { + action.kind.as_ref().is_some_and(|action_kind| { + let action_kind_str = action_kind.as_str(); + kinds.iter().any(|requested| { + let requested_str = requested.as_str(); + // Match if action kind starts with requested kind + // e.g., "source.fixAll.rumdl" matches "source.fixAll" + action_kind_str.starts_with(requested_str) + }) + }) + }) + .collect() + } else { + actions + }; + + let response: Vec<CodeActionOrCommand> = filtered_actions + .into_iter() + .map(CodeActionOrCommand::CodeAction) + .collect(); Ok(Some(response)) } Err(e) => { @@ -3400,4 +3435,75 @@ let result = RumdlLanguageServer::apply_formatting_options(content.to_string(), &options); assert_eq!(result, "# Heading\n\nParagraph\n- List item\n"); } + + #[test] + fn test_code_action_kind_filtering() { + // Test the hierarchical code action kind matching used in code_action handler + // LSP spec: source.fixAll.rumdl should match requests for source.fixAll + + let matches = |action_kind: &str, requested: &str| -> bool { action_kind.starts_with(requested) }; + + // source.fixAll.rumdl matches source.fixAll (parent kind) + assert!(matches("source.fixAll.rumdl", "source.fixAll")); + + // source.fixAll.rumdl matches source.fixAll.rumdl (exact match) + assert!(matches("source.fixAll.rumdl", "source.fixAll.rumdl")); + + // source.fixAll.rumdl matches source (grandparent kind) + assert!(matches("source.fixAll.rumdl", "source")); + + // quickfix matches quickfix (exact match) + assert!(matches("quickfix", "quickfix")); + + // source.fixAll.rumdl does NOT match quickfix + assert!(!matches("source.fixAll.rumdl", "quickfix")); + + // quickfix does NOT match source.fixAll + assert!(!matches("quickfix", "source.fixAll")); + + // source.fixAll does NOT match source.fixAll.rumdl (child is more specific) + assert!(!matches("source.fixAll", "source.fixAll.rumdl")); + } + + #[test] + fn test_code_action_kind_filter_with_empty_array() { + // LSP spec: "If provided with no kinds, all supported kinds are returned" + // An empty array should be treated the same as None (return all actions) + + let filter_actions = |kinds: Option<Vec<&str>>| -> bool { + // Simulates our filtering logic + if let Some(ref k) = kinds + && !k.is_empty() + { + // Would filter + false + } else { + // Return all + true + } + }; + + // None returns all actions + assert!(filter_actions(None)); + + // Empty array returns all actions (per LSP spec) + assert!(filter_actions(Some(vec![]))); + + // Non-empty array triggers filtering + assert!(!filter_actions(Some(vec!["source.fixAll"]))); + } + + #[test] + fn test_code_action_kind_constants() { + // Verify our custom code action kind string matches LSP conventions + let fix_all_rumdl = CodeActionKind::new("source.fixAll.rumdl"); + assert_eq!(fix_all_rumdl.as_str(), "source.fixAll.rumdl"); + + // Verify it's a sub-kind of SOURCE_FIX_ALL + assert!( + fix_all_rumdl + .as_str() + .starts_with(CodeActionKind::SOURCE_FIX_ALL.as_str()) + ); + } } ++++++ rumdl.obsinfo ++++++ --- /var/tmp/diff_new_pack.p34xTq/_old 2026-01-23 17:34:00.168248326 +0100 +++ /var/tmp/diff_new_pack.p34xTq/_new 2026-01-23 17:34:00.172248491 +0100 @@ -1,5 +1,5 @@ name: rumdl -version: 0.0.223 -mtime: 1769035196 -commit: 7dfe530feec9ad5cb0b379844680836c523db0e7 +version: 0.0.224 +mtime: 1769087781 +commit: 265158ecf14a4c7ca397550b82fe1a5651acddd2 ++++++ vendor.tar.zst ++++++ /work/SRC/openSUSE:Factory/rumdl/vendor.tar.zst /work/SRC/openSUSE:Factory/.rumdl.new.1928/vendor.tar.zst differ: char 12294, line 49
