diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 2c4e0ee95..5374bd792 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -387,6 +387,15 @@ check commits: - job: 'build-stable' artifacts: false +typos: + extends: .img-stable + stage: "lint" + script: + - typos + needs: + - job: 'build-stable' + artifacts: false + clippy: extends: .img-stable stage: 'extras' diff --git a/ci/images_template.yml b/ci/images_template.yml index c746d8069..b241dfeff 100644 --- a/ci/images_template.yml +++ b/ci/images_template.yml @@ -1,4 +1,4 @@ variables: - GST_RS_IMG_TAG: '2023-04-06.0' - GST_RS_STABLE: '1.68.2' - GST_RS_MSRV: '1.66.0' + GST_RS_IMG_TAG: "2023-04-76.0" + GST_RS_STABLE: "1.68.2" + GST_RS_MSRV: "1.66.0" diff --git a/ci/install-rust.sh b/ci/install-rust.sh index b2747ed90..a4e772ed6 100755 --- a/ci/install-rust.sh +++ b/ci/install-rust.sh @@ -28,6 +28,7 @@ if [ "$RUST_IMAGE_FULL" = "1" ]; then cargo install --force cargo-deny cargo install --force cargo-outdated + cargo install --force typos-cli # Coverage tools rustup component add llvm-tools-preview diff --git a/typos.toml b/typos.toml new file mode 100644 index 000000000..f9951ccd4 --- /dev/null +++ b/typos.toml @@ -0,0 +1,31 @@ +[default.extend-words] +gir = "gir" +numer = "numer" # numerator +inout = "inout" +seeked = "seeked" +BA = "BA" # sdp_message.rs +UE = "UE" # rtsp-server-record.rs + +[default] +extend-ignore-identifiers-re = [ + "GST_MTS_TABLE_ID_14496_OBJET_DESCRIPTOR", + # gst_rtsp_media_factory_is_stop_on_disonnect + ".*is_stop_on_disonnect", + "ser_de", # gstreamer/CHANGELOG.md +] + +[files] +extend-exclude = [ + # don't check dot and gir files + "*.gir", + "*.dot", + # don't check submodules + "gir/*", + "gir-files/*", + "gst-gir-files/*", + # versions.txt are generated and contain git hash objects + "versions.txt", + # can't fix typos in generated code as the typo is likely in the C API + "*/src/auto/*.rs", + "*/sys/src/lib.rs", +]