Skip to content
Myr

ci: check docs for all crates

Before adoption: this commit came in with the history the project adopted, so no landing records it.

This also replaces '--all' in Cargo commands with '--workspace'. The former has apparently been deprecated. We also fix a couple warnings that this new step detected. Closes #1848

authored by Marco Ieni · committed by Andrew Gallant · parent 26a29c7 · Browse files · 3 files+24 added−7 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

3 files+24 added−7 removed

  • other:+24 added−7 removed

3 files+24 added−7 removed

modified:.github/workflows/ci.yml+21 added-4 removed
116 unmodified lines
117 echo "cargo command is: ${{ env.CARGO }}"118 echo "target flag is: ${{ env.TARGET_FLAGS }}"119120 - name: Build ripgrep and all crates121 run: ${{ env.CARGO }} build --verbose --all ${{ env.TARGET_FLAGS }}121 run: ${{ env.CARGO }} build --verbose --workspace ${{ env.TARGET_FLAGS }}122123 - name: Build ripgrep with PCRE2124 run: ${{ env.CARGO }} build --verbose --all --features pcre2 ${{ env.TARGET_FLAGS }}124 run: ${{ env.CARGO }} build --verbose --workspace --features pcre2 ${{ env.TARGET_FLAGS }}125126 # This is useful for debugging problems when the expected build artifacts127 # (like shell completions and man pages) aren't generated.128 - name: Show build.rs stderr
9 unmodified lines
138 set -x139140 - name: Run tests with PCRE2 (sans cross)141 if: matrix.target == ''142 run: ${{ env.CARGO }} test --verbose --all --features pcre2 ${{ env.TARGET_FLAGS }}142 run: ${{ env.CARGO }} test --verbose --workspace --features pcre2 ${{ env.TARGET_FLAGS }}143144 - name: Run tests without PCRE2 (with cross)145 # These tests should actually work, but they almost double the runtime.146 # Every integration test spins up qemu to run 'rg', and when PCRE2 is147 # enabled, every integration test is run twice: one with the default148 # regex engine and once with PCRE2.149 if: matrix.target != ''150 run: ${{ env.CARGO }} test --verbose --all ${{ env.TARGET_FLAGS }}150 run: ${{ env.CARGO }} test --verbose --workspace ${{ env.TARGET_FLAGS }}151152 - name: Test for existence of build artifacts (Windows)153 if: matrix.os == 'windows-2019'154 shell: bash
38 unmodified lines
193 components: rustfmt194 - name: Check formatting195 run: |196 cargo fmt --all -- --check197198 docs:199 name: Docs200 runs-on: ubuntu-20.04201 steps:202 - name: Checkout repository203 uses: actions/checkout@v2204 - name: Install Rust205 uses: actions-rs/toolchain@v1206 with:207 toolchain: stable208 profile: minimal209 override: true210 - name: Check documentation211 env:212 RUSTDOCFLAGS: -D warnings213 run: cargo doc --no-deps --document-private-items --workspace
modified:crates/ignore/src/default_types.rs+1 added-1 removed
2 unmodified lines
3/// limited to reasonably popular open formats. For other cases, you can add4/// types to each invocation of ripgrep with the '--type-add' flag.5///6/// If you would like to add or improve this list, please file a PR:7/// https://github.com/BurntSushi/ripgrep7/// <https://github.com/BurntSushi/ripgrep>.8///9/// Please try to keep this list sorted lexicographically and wrapped to 7910/// columns (inclusive).11#[rustfmt::skip]
247 unmodified lines
modified:crates/regex/src/matcher.rs+2 added-2 removed
17 unmodified lines
18/// matching and the ability to set a line terminator which may enable certain19/// types of optimizations.20///21/// The syntax supported is documented as part of the regex crate:22/// https://docs.rs/regex/*/regex/#syntax22/// <https://docs.rs/regex/#syntax>.23#[derive(Clone, Debug)]24pub struct RegexMatcherBuilder {25 config: Config,26}
13 unmodified lines
40 /// Build a new matcher using the current configuration for the provided41 /// pattern.42 ///43 /// The syntax supported is documented as part of the regex crate:44 /// https://docs.rs/regex/*/regex/#syntax44 /// <https://docs.rs/regex/#syntax>.45 pub fn build(&self, pattern: &str) -> Result<RegexMatcher, Error> {46 let chir = self.config.hir(pattern)?;47 let fast_line_regex = chir.fast_line_regex()?;48 let non_matching_bytes = chir.non_matching_bytes();
1018 unmodified lines