From eaa6d228b11daee36432ef042ced87a30553a9e5 Mon Sep 17 00:00:00 2001 From: Sylvestre Ledru Date: Sat, 28 Jun 2025 18:49:15 +0200 Subject: [PATCH] Use mozilla fluent linter (and remove mine) --- .github/fluent_linter_config.yml | 28 ++++++++++++++++++++++++++++ .pre-commit-config.yaml | 8 +++++--- 2 files changed, 33 insertions(+), 3 deletions(-) create mode 100644 .github/fluent_linter_config.yml diff --git a/.github/fluent_linter_config.yml b/.github/fluent_linter_config.yml new file mode 100644 index 000000000..1b33942f7 --- /dev/null +++ b/.github/fluent_linter_config.yml @@ -0,0 +1,28 @@ +--- +ID01: + enabled: true + exclusions: + messages: [] + files: [] +ID02: + enabled: true + min_length: 7 +VC: + disabled: true +# Disable: # TE01: single quote instead of apostrophe for genitive (foo's) +TE01: + enabled: false +# TE03: single quotes ('foo') +TE03: + enabled: false +# TE04: Double-quoted strings should use Unicode " instead of "foo". +TE04: + enabled: false +# Disable: TE05: 3 dots for ellipsis ("...") +TE05: + enabled: false +# Should be fixed +VC01: + disabled: true +ID03: + enabled: true diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 35630fe70..c4c511210 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -19,10 +19,12 @@ repos: args: [ --fix=lf ] - id: trailing-whitespace - - repo: https://github.com/uutils/pre-commit-fluent-hook - rev: v0.0.1 + - repo: https://github.com/mozilla-l10n/moz-fluent-linter + rev: v0.4.8 hooks: - - id: check-fluent + - id: fluent_linter + files: \.ftl$ + args: [--config, .github/fluent_linter_config.yml, src/uu/] - repo: local hooks: