@owenlamont/ryl 0.4.1 → 0.4.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.
- package/README.md +13 -0
- package/bin/ryl.js +195 -1
- package/package.json +35 -13
- package/.github/CODEOWNERS +0 -1
- package/.github/dependabot.yml +0 -13
- package/.github/workflows/ci.yml +0 -107
- package/.github/workflows/release.yml +0 -613
- package/.github/workflows/update_dependencies.yml +0 -61
- package/.github/workflows/update_linters.yml +0 -56
- package/.pre-commit-config.yaml +0 -87
- package/.yamllint +0 -4
- package/AGENTS.md +0 -200
- package/Cargo.lock +0 -908
- package/Cargo.toml +0 -32
- package/clippy.toml +0 -1
- package/docs/config-presets.md +0 -100
- package/img/benchmark-5x5-5runs.svg +0 -2176
- package/pyproject.toml +0 -42
- package/ruff.toml +0 -107
- package/rumdl.toml +0 -20
- package/rust-toolchain.toml +0 -3
- package/rustfmt.toml +0 -3
- package/scripts/benchmark_perf_vs_yamllint.py +0 -400
- package/scripts/coverage-missing.ps1 +0 -80
- package/scripts/coverage-missing.sh +0 -60
- package/src/bin/discover_config_bin.rs +0 -24
- package/src/cli_support.rs +0 -33
- package/src/conf/mod.rs +0 -85
- package/src/config.rs +0 -2099
- package/src/decoder.rs +0 -326
- package/src/discover.rs +0 -31
- package/src/lib.rs +0 -19
- package/src/lint.rs +0 -558
- package/src/main.rs +0 -535
- package/src/migrate.rs +0 -233
- package/src/rules/anchors.rs +0 -517
- package/src/rules/braces.rs +0 -77
- package/src/rules/brackets.rs +0 -77
- package/src/rules/colons.rs +0 -475
- package/src/rules/commas.rs +0 -372
- package/src/rules/comments.rs +0 -299
- package/src/rules/comments_indentation.rs +0 -243
- package/src/rules/document_end.rs +0 -175
- package/src/rules/document_start.rs +0 -84
- package/src/rules/empty_lines.rs +0 -152
- package/src/rules/empty_values.rs +0 -255
- package/src/rules/float_values.rs +0 -259
- package/src/rules/flow_collection.rs +0 -562
- package/src/rules/hyphens.rs +0 -104
- package/src/rules/indentation.rs +0 -803
- package/src/rules/key_duplicates.rs +0 -218
- package/src/rules/key_ordering.rs +0 -303
- package/src/rules/line_length.rs +0 -326
- package/src/rules/mod.rs +0 -25
- package/src/rules/new_line_at_end_of_file.rs +0 -23
- package/src/rules/new_lines.rs +0 -95
- package/src/rules/octal_values.rs +0 -121
- package/src/rules/quoted_strings.rs +0 -577
- package/src/rules/span_utils.rs +0 -37
- package/src/rules/trailing_spaces.rs +0 -65
- package/src/rules/truthy.rs +0 -420
- package/tests/brackets_carriage_return.rs +0 -114
- package/tests/build_global_cfg_error.rs +0 -23
- package/tests/cli_anchors_rule.rs +0 -143
- package/tests/cli_braces_rule.rs +0 -104
- package/tests/cli_brackets_rule.rs +0 -104
- package/tests/cli_colons_rule.rs +0 -65
- package/tests/cli_commas_rule.rs +0 -104
- package/tests/cli_comments_indentation_rule.rs +0 -61
- package/tests/cli_comments_rule.rs +0 -67
- package/tests/cli_config_data_error.rs +0 -30
- package/tests/cli_config_flags.rs +0 -66
- package/tests/cli_config_migrate.rs +0 -229
- package/tests/cli_document_end_rule.rs +0 -92
- package/tests/cli_document_start_rule.rs +0 -92
- package/tests/cli_empty_lines_rule.rs +0 -87
- package/tests/cli_empty_values_rule.rs +0 -68
- package/tests/cli_env_config.rs +0 -34
- package/tests/cli_exit_and_errors.rs +0 -41
- package/tests/cli_file_encoding.rs +0 -203
- package/tests/cli_float_values_rule.rs +0 -64
- package/tests/cli_format_options.rs +0 -316
- package/tests/cli_global_cfg_relaxed.rs +0 -20
- package/tests/cli_hyphens_rule.rs +0 -104
- package/tests/cli_indentation_rule.rs +0 -65
- package/tests/cli_invalid_project_config.rs +0 -39
- package/tests/cli_key_duplicates_rule.rs +0 -104
- package/tests/cli_key_ordering_rule.rs +0 -59
- package/tests/cli_line_length_rule.rs +0 -85
- package/tests/cli_list_files.rs +0 -29
- package/tests/cli_new_line_rule.rs +0 -141
- package/tests/cli_new_lines_rule.rs +0 -119
- package/tests/cli_octal_values_rule.rs +0 -60
- package/tests/cli_quoted_strings_rule.rs +0 -47
- package/tests/cli_toml_config.rs +0 -119
- package/tests/cli_trailing_spaces_rule.rs +0 -77
- package/tests/cli_truthy_rule.rs +0 -83
- package/tests/cli_yaml_files_negation.rs +0 -45
- package/tests/colons_rule.rs +0 -303
- package/tests/common/compat.rs +0 -114
- package/tests/common/fake_env.rs +0 -93
- package/tests/common/mod.rs +0 -1
- package/tests/conf_builtin.rs +0 -9
- package/tests/config_anchors.rs +0 -84
- package/tests/config_braces.rs +0 -121
- package/tests/config_brackets.rs +0 -127
- package/tests/config_commas.rs +0 -79
- package/tests/config_comments.rs +0 -65
- package/tests/config_comments_indentation.rs +0 -20
- package/tests/config_deep_merge_nonstring_key.rs +0 -24
- package/tests/config_document_end.rs +0 -54
- package/tests/config_document_start.rs +0 -55
- package/tests/config_empty_lines.rs +0 -48
- package/tests/config_empty_values.rs +0 -35
- package/tests/config_env_errors.rs +0 -23
- package/tests/config_env_invalid_inline.rs +0 -15
- package/tests/config_env_missing.rs +0 -63
- package/tests/config_env_shim.rs +0 -301
- package/tests/config_explicit_file_parse_error.rs +0 -55
- package/tests/config_extended_features.rs +0 -225
- package/tests/config_extends_inline.rs +0 -185
- package/tests/config_extends_sequence.rs +0 -18
- package/tests/config_find_project_home_boundary.rs +0 -54
- package/tests/config_find_project_two_files_in_cwd.rs +0 -47
- package/tests/config_float_values.rs +0 -34
- package/tests/config_from_yaml_paths.rs +0 -32
- package/tests/config_hyphens.rs +0 -51
- package/tests/config_ignore_errors.rs +0 -243
- package/tests/config_ignore_overrides.rs +0 -83
- package/tests/config_indentation.rs +0 -65
- package/tests/config_invalid_globs.rs +0 -16
- package/tests/config_invalid_types.rs +0 -19
- package/tests/config_key_duplicates.rs +0 -34
- package/tests/config_key_ordering.rs +0 -70
- package/tests/config_line_length.rs +0 -65
- package/tests/config_locale.rs +0 -111
- package/tests/config_merge.rs +0 -26
- package/tests/config_new_lines.rs +0 -89
- package/tests/config_octal_values.rs +0 -33
- package/tests/config_quoted_strings.rs +0 -195
- package/tests/config_rule_level.rs +0 -147
- package/tests/config_rules_non_string_keys.rs +0 -23
- package/tests/config_scalar_overrides.rs +0 -27
- package/tests/config_to_toml.rs +0 -110
- package/tests/config_toml_coverage.rs +0 -80
- package/tests/config_toml_discovery.rs +0 -304
- package/tests/config_trailing_spaces.rs +0 -152
- package/tests/config_truthy.rs +0 -77
- package/tests/config_yaml_files.rs +0 -62
- package/tests/config_yaml_files_all_non_string.rs +0 -15
- package/tests/config_yaml_files_empty.rs +0 -30
- package/tests/coverage_commas.rs +0 -46
- package/tests/decoder_decode.rs +0 -338
- package/tests/discover_config_bin_all.rs +0 -66
- package/tests/discover_config_bin_env_invalid_yaml.rs +0 -26
- package/tests/discover_config_bin_project_config_parse_error.rs +0 -24
- package/tests/discover_config_bin_user_global_error.rs +0 -26
- package/tests/discover_module.rs +0 -30
- package/tests/discover_per_file_dir.rs +0 -10
- package/tests/discover_per_file_project_config_error.rs +0 -21
- package/tests/float_values.rs +0 -43
- package/tests/lint_multi_errors.rs +0 -32
- package/tests/main_yaml_ok_filtering.rs +0 -30
- package/tests/migrate_module.rs +0 -259
- package/tests/resolve_ctx_empty_parent.rs +0 -16
- package/tests/rule_anchors.rs +0 -442
- package/tests/rule_braces.rs +0 -258
- package/tests/rule_brackets.rs +0 -217
- package/tests/rule_commas.rs +0 -205
- package/tests/rule_comments.rs +0 -197
- package/tests/rule_comments_indentation.rs +0 -127
- package/tests/rule_document_end.rs +0 -118
- package/tests/rule_document_start.rs +0 -60
- package/tests/rule_empty_lines.rs +0 -96
- package/tests/rule_empty_values.rs +0 -102
- package/tests/rule_float_values.rs +0 -109
- package/tests/rule_hyphens.rs +0 -65
- package/tests/rule_indentation.rs +0 -455
- package/tests/rule_key_duplicates.rs +0 -76
- package/tests/rule_key_ordering.rs +0 -207
- package/tests/rule_line_length.rs +0 -200
- package/tests/rule_new_lines.rs +0 -51
- package/tests/rule_octal_values.rs +0 -53
- package/tests/rule_quoted_strings.rs +0 -290
- package/tests/rule_trailing_spaces.rs +0 -41
- package/tests/rule_truthy.rs +0 -236
- package/tests/user_global_invalid_yaml.rs +0 -32
- package/tests/yamllint_compat_anchors.rs +0 -280
- package/tests/yamllint_compat_braces.rs +0 -411
- package/tests/yamllint_compat_brackets.rs +0 -364
- package/tests/yamllint_compat_colons.rs +0 -298
- package/tests/yamllint_compat_colors.rs +0 -80
- package/tests/yamllint_compat_commas.rs +0 -375
- package/tests/yamllint_compat_comments.rs +0 -167
- package/tests/yamllint_compat_comments_indentation.rs +0 -281
- package/tests/yamllint_compat_config.rs +0 -170
- package/tests/yamllint_compat_document_end.rs +0 -243
- package/tests/yamllint_compat_document_start.rs +0 -136
- package/tests/yamllint_compat_empty_lines.rs +0 -117
- package/tests/yamllint_compat_empty_values.rs +0 -179
- package/tests/yamllint_compat_float_values.rs +0 -216
- package/tests/yamllint_compat_hyphens.rs +0 -223
- package/tests/yamllint_compat_indentation.rs +0 -398
- package/tests/yamllint_compat_key_duplicates.rs +0 -139
- package/tests/yamllint_compat_key_ordering.rs +0 -170
- package/tests/yamllint_compat_line_length.rs +0 -375
- package/tests/yamllint_compat_list.rs +0 -127
- package/tests/yamllint_compat_new_line.rs +0 -133
- package/tests/yamllint_compat_newline_types.rs +0 -185
- package/tests/yamllint_compat_octal_values.rs +0 -172
- package/tests/yamllint_compat_quoted_strings.rs +0 -154
- package/tests/yamllint_compat_syntax.rs +0 -200
- package/tests/yamllint_compat_trailing_spaces.rs +0 -162
- package/tests/yamllint_compat_truthy.rs +0 -130
- package/tests/yamllint_compat_yaml_files.rs +0 -81
- package/typos.toml +0 -2
package/Cargo.toml
DELETED
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
[package]
|
|
2
|
-
name = "ryl"
|
|
3
|
-
version = "0.4.1"
|
|
4
|
-
edition = "2024"
|
|
5
|
-
description = "Fast YAML linter inspired by yamllint"
|
|
6
|
-
readme = "README.md"
|
|
7
|
-
license = "MIT"
|
|
8
|
-
repository = "https://github.com/owenlamont/ryl"
|
|
9
|
-
categories = ["command-line-utilities", "development-tools"]
|
|
10
|
-
keywords = ["yaml", "lint", "cli", "rust"]
|
|
11
|
-
|
|
12
|
-
[[bin]]
|
|
13
|
-
name = "ryl"
|
|
14
|
-
path = "src/main.rs"
|
|
15
|
-
|
|
16
|
-
[dependencies]
|
|
17
|
-
clap = { version = "4.6.0", default-features = false, features = ["derive", "std", "help", "usage", "error-context", "suggestions"] }
|
|
18
|
-
ignore = "0.4.25"
|
|
19
|
-
rayon = "1.11.0"
|
|
20
|
-
saphyr-parser = "0.0.6"
|
|
21
|
-
saphyr = "0.0.6"
|
|
22
|
-
dirs-next = "2.0.0"
|
|
23
|
-
regex = "1"
|
|
24
|
-
unicode-normalization = "0.1"
|
|
25
|
-
encoding_rs = "0.8"
|
|
26
|
-
# Keep preserve_order off to avoid pulling in indexmap/hashbrown 0.16 until
|
|
27
|
-
# saphyr updates hashlink and the dependency graph converges again.
|
|
28
|
-
toml = { version = "1.1.2", default-features = false, features = ["display", "parse", "serde"] }
|
|
29
|
-
|
|
30
|
-
[dev-dependencies]
|
|
31
|
-
semver = "1"
|
|
32
|
-
tempfile = "3"
|
package/clippy.toml
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
msrv = "1.93.1"
|
package/docs/config-presets.md
DELETED
|
@@ -1,100 +0,0 @@
|
|
|
1
|
-
# ryl config presets (TOML)
|
|
2
|
-
|
|
3
|
-
These TOML presets mirror the built-in YAML presets in `ryl` (`default`,
|
|
4
|
-
`relaxed`, `empty`) from [src/conf/mod.rs](/home/owen/Code/ryl_repos/ryl/src/conf/mod.rs).
|
|
5
|
-
|
|
6
|
-
## `default` (TOML equivalent)
|
|
7
|
-
|
|
8
|
-
```toml
|
|
9
|
-
yaml-files = ["*.yaml", "*.yml", ".yamllint"]
|
|
10
|
-
|
|
11
|
-
[rules]
|
|
12
|
-
anchors = "enable"
|
|
13
|
-
braces = "enable"
|
|
14
|
-
brackets = "enable"
|
|
15
|
-
colons = "enable"
|
|
16
|
-
commas = "enable"
|
|
17
|
-
document-end = "disable"
|
|
18
|
-
empty-lines = "enable"
|
|
19
|
-
empty-values = "disable"
|
|
20
|
-
float-values = "disable"
|
|
21
|
-
hyphens = "enable"
|
|
22
|
-
indentation = "enable"
|
|
23
|
-
key-duplicates = "enable"
|
|
24
|
-
key-ordering = "disable"
|
|
25
|
-
line-length = "enable"
|
|
26
|
-
new-line-at-end-of-file = "enable"
|
|
27
|
-
new-lines = "enable"
|
|
28
|
-
octal-values = "disable"
|
|
29
|
-
quoted-strings = "disable"
|
|
30
|
-
trailing-spaces = "enable"
|
|
31
|
-
|
|
32
|
-
[rules.comments]
|
|
33
|
-
level = "warning"
|
|
34
|
-
|
|
35
|
-
[rules.comments-indentation]
|
|
36
|
-
level = "warning"
|
|
37
|
-
|
|
38
|
-
[rules.document-start]
|
|
39
|
-
level = "warning"
|
|
40
|
-
|
|
41
|
-
[rules.truthy]
|
|
42
|
-
level = "warning"
|
|
43
|
-
```
|
|
44
|
-
|
|
45
|
-
## `relaxed` (TOML equivalent, fully expanded)
|
|
46
|
-
|
|
47
|
-
```toml
|
|
48
|
-
yaml-files = ["*.yaml", "*.yml", ".yamllint"]
|
|
49
|
-
|
|
50
|
-
[rules]
|
|
51
|
-
anchors = "enable"
|
|
52
|
-
comments = "disable"
|
|
53
|
-
comments-indentation = "disable"
|
|
54
|
-
document-end = "disable"
|
|
55
|
-
document-start = "disable"
|
|
56
|
-
empty-values = "disable"
|
|
57
|
-
float-values = "disable"
|
|
58
|
-
key-duplicates = "enable"
|
|
59
|
-
key-ordering = "disable"
|
|
60
|
-
new-line-at-end-of-file = "enable"
|
|
61
|
-
new-lines = "enable"
|
|
62
|
-
octal-values = "disable"
|
|
63
|
-
quoted-strings = "disable"
|
|
64
|
-
trailing-spaces = "enable"
|
|
65
|
-
truthy = "disable"
|
|
66
|
-
|
|
67
|
-
[rules.braces]
|
|
68
|
-
level = "warning"
|
|
69
|
-
max-spaces-inside = 1
|
|
70
|
-
|
|
71
|
-
[rules.brackets]
|
|
72
|
-
level = "warning"
|
|
73
|
-
max-spaces-inside = 1
|
|
74
|
-
|
|
75
|
-
[rules.colons]
|
|
76
|
-
level = "warning"
|
|
77
|
-
|
|
78
|
-
[rules.commas]
|
|
79
|
-
level = "warning"
|
|
80
|
-
|
|
81
|
-
[rules.empty-lines]
|
|
82
|
-
level = "warning"
|
|
83
|
-
|
|
84
|
-
[rules.hyphens]
|
|
85
|
-
level = "warning"
|
|
86
|
-
|
|
87
|
-
[rules.indentation]
|
|
88
|
-
level = "warning"
|
|
89
|
-
indent-sequences = "consistent"
|
|
90
|
-
|
|
91
|
-
[rules.line-length]
|
|
92
|
-
level = "warning"
|
|
93
|
-
allow-non-breakable-inline-mappings = true
|
|
94
|
-
```
|
|
95
|
-
|
|
96
|
-
## `empty` (TOML equivalent)
|
|
97
|
-
|
|
98
|
-
```toml
|
|
99
|
-
[rules]
|
|
100
|
-
```
|