Skip to content

Commit 2e27080

Browse files
authored
Merge pull request #96 from acheronfail/next
0.15.0
2 parents 946b8f5 + fae18d9 commit 2e27080

19 files changed

Lines changed: 608 additions & 785 deletions

.github/workflows/ci.yml

Lines changed: 76 additions & 73 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,60 @@ on:
77
branches:
88
- master
99
jobs:
10+
rustfmt:
11+
name: rustfmt
12+
runs-on: ubuntu-latest
13+
steps:
14+
- name: Checkout repository
15+
uses: actions/checkout@v3
16+
- name: Install Rust
17+
uses: actions-rs/toolchain@v1
18+
with:
19+
toolchain: stable
20+
override: true
21+
profile: minimal
22+
components: rustfmt
23+
- name: Check formatting
24+
run: |
25+
cargo fmt --all -- --check
26+
27+
readme:
28+
name: readme
29+
runs-on: ubuntu-latest
30+
steps:
31+
- name: Checkout repository
32+
uses: actions/checkout@v3
33+
# cache
34+
- uses: actions/cache@v3
35+
with:
36+
path: |
37+
~/.cargo/bin/
38+
~/.cargo/registry/index/
39+
~/.cargo/registry/cache/
40+
~/.cargo/git/db/
41+
~/.cargo/.crates.toml
42+
~/.cargo/.crates2.json
43+
target/
44+
key: ${{ runner.os }}-cargo-readme
45+
- name: Install Rust
46+
uses: actions-rs/toolchain@v1
47+
with:
48+
toolchain: nightly
49+
override: true
50+
profile: minimal
51+
components: rustfmt
52+
- name: Check readme
53+
run: |
54+
ci/install-packages-ubuntu.sh
55+
cargo install just
56+
just setup
57+
just readme
58+
rustup install nightly
59+
just fmt
60+
just check-dirty
61+
1062
test:
63+
needs: ['rustfmt', 'readme']
1164
name: test
1265
env:
1366
# For some builds, we use cross to test on 32-bit and big-endian
@@ -30,21 +83,19 @@ jobs:
3083
- beta
3184
# Our release builds are generated by a nightly compiler to take
3285
# advantage of the latest optimizations/compile time improvements. So
33-
# we test all of them here. (We don't do mips releases, but test on
34-
# mips for big-endian coverage.)
86+
# we test all of them here.
3587
- nightly
3688
- nightly-musl
3789
- nightly-32
38-
- nightly-mips
3990
- nightly-arm
4091
- macos
4192
- win-msvc
4293
- win-gnu
4394
include:
4495
- build: pinned
4596
os: ubuntu-latest
46-
# NOTE: ratatui requires 1.65.0
47-
rust: 1.65.0
97+
# NOTE: ripgrep requires 1.72.0
98+
rust: 1.72.0
4899
- build: stable
49100
os: ubuntu-latest
50101
rust: stable
@@ -56,22 +107,18 @@ jobs:
56107
# NOTE: we pin to a specific version since sometimes things fail to compile on the latest nightly builds
57108
- build: nightly
58109
os: ubuntu-latest
59-
rust: nightly-2023-04-16
110+
rust: nightly-2023-12-04
60111
- build: nightly-musl
61112
os: ubuntu-latest
62-
rust: nightly-2023-04-16
113+
rust: nightly-2023-12-04
63114
target: x86_64-unknown-linux-musl
64115
- build: nightly-32
65116
os: ubuntu-latest
66-
rust: nightly-2023-04-16
117+
rust: nightly-2023-12-04
67118
target: i686-unknown-linux-gnu
68-
- build: nightly-mips
69-
os: ubuntu-latest
70-
rust: nightly-2023-04-16
71-
target: mips64-unknown-linux-gnuabi64
72119
- build: nightly-arm
73120
os: ubuntu-latest
74-
rust: nightly-2023-04-16
121+
rust: nightly-2023-12-04
75122
# For stripping release binaries:
76123
# docker run --rm -v $PWD/target:/target:Z \
77124
# rustembedded/cross:arm-unknown-linux-gnueabihf \
@@ -80,19 +127,32 @@ jobs:
80127
target: arm-unknown-linux-gnueabihf
81128
- build: macos
82129
os: macos-latest
83-
rust: nightly-2023-04-16
130+
rust: nightly-2023-12-04
84131
- build: win-msvc
85132
os: windows-2019
86-
rust: nightly-2023-04-16
133+
rust: nightly-2023-12-04
87134
- build: win-gnu
88135
os: windows-2019
89-
rust: nightly-2023-04-16-x86_64-gnu
136+
rust: nightly-2023-12-04-x86_64-gnu
90137
steps:
91138
- name: Checkout repository
92139
uses: actions/checkout@v3
93140
with:
94141
submodules: recursive
95142

143+
# cache
144+
- uses: actions/cache@v3
145+
with:
146+
path: |
147+
~/.cargo/bin/
148+
~/.cargo/registry/index/
149+
~/.cargo/registry/cache/
150+
~/.cargo/git/db/
151+
~/.cargo/.crates.toml
152+
~/.cargo/.crates2.json
153+
target/
154+
key: ${{ runner.os }}-cargo-${{ matrix.build }}
155+
96156
- name: Install packages (Ubuntu)
97157
if: matrix.os == 'ubuntu-latest'
98158
run: |
@@ -147,60 +207,3 @@ jobs:
147207
- name: Run tests (with cross)
148208
if: matrix.target != ''
149209
run: ${{ env.CARGO }} test --verbose --all ${{ env.TARGET_FLAGS }}
150-
151-
- name: Test for existence of build artifacts (Windows)
152-
if: matrix.os == 'windows-2019'
153-
shell: bash
154-
run: |
155-
outdir="$(ci/cargo-out-dir.sh "${{ env.TARGET_DIR }}")"
156-
ls "$outdir/_rgr.ps1" && file "$outdir/_rgr.ps1"
157-
158-
- name: Test for existence of build artifacts (Unix)
159-
if: matrix.os != 'windows-2019'
160-
shell: bash
161-
run: |
162-
outdir="$(ci/cargo-out-dir.sh "${{ env.TARGET_DIR }}")"
163-
for f in rgr.1 _rgr rgr.bash rgr.fish; do
164-
# We could use file -E here, but it isn't supported on macOS.
165-
ls "$outdir/$f" && file "$outdir/$f"
166-
done
167-
168-
rustfmt:
169-
name: rustfmt
170-
runs-on: ubuntu-latest
171-
steps:
172-
- name: Checkout repository
173-
uses: actions/checkout@v3
174-
- name: Install Rust
175-
uses: actions-rs/toolchain@v1
176-
with:
177-
toolchain: stable
178-
override: true
179-
profile: minimal
180-
components: rustfmt
181-
- name: Check formatting
182-
run: |
183-
cargo fmt --all -- --check
184-
185-
readme:
186-
name: readme
187-
runs-on: ubuntu-latest
188-
steps:
189-
- name: Checkout repository
190-
uses: actions/checkout@v3
191-
- name: Install Rust
192-
uses: actions-rs/toolchain@v1
193-
with:
194-
toolchain: nightly
195-
override: true
196-
profile: minimal
197-
components: rustfmt
198-
- name: Check readme
199-
run: |
200-
ci/install-packages-ubuntu.sh
201-
cargo install just
202-
just setup
203-
just readme
204-
rustup install nightly
205-
just fmt
206-
just check-dirty

.github/workflows/release.yml

Lines changed: 31 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -73,31 +73,31 @@ jobs:
7373
# NOTE: we pin to a specific version since sometimes things fail to compile on the latest nightly builds
7474
- build: linux-gnu
7575
os: ubuntu-latest
76-
rust: nightly-2023-04-16
76+
rust: nightly-2023-12-04
7777
target: x86_64-unknown-linux-gnu
7878
- build: linux-musl
7979
os: ubuntu-latest
80-
rust: nightly-2023-04-16
80+
rust: nightly-2023-12-04
8181
target: x86_64-unknown-linux-musl
8282
- build: linux-arm-gnueabihf
8383
os: ubuntu-latest
84-
rust: nightly-2023-04-16
84+
rust: nightly-2023-12-04
8585
target: arm-unknown-linux-gnueabihf
8686
- build: macos
8787
os: macos-latest
88-
rust: nightly-2023-04-16
88+
rust: nightly-2023-12-04
8989
target: x86_64-apple-darwin
9090
- build: win-msvc
9191
os: windows-2019
92-
rust: nightly-2023-04-16
92+
rust: nightly-2023-12-04
9393
target: x86_64-pc-windows-msvc
9494
- build: win-gnu
9595
os: windows-2019
96-
rust: nightly-2023-04-16-x86_64-gnu
96+
rust: nightly-2023-12-04-x86_64-gnu
9797
target: x86_64-pc-windows-gnu
9898
- build: win32-msvc
9999
os: windows-2019
100-
rust: nightly-2023-04-16
100+
rust: nightly-2023-12-04
101101
target: i686-pc-windows-msvc
102102

103103
steps:
@@ -125,6 +125,25 @@ jobs:
125125
override: true
126126
target: ${{ matrix.target }}
127127

128+
# cache
129+
- uses: actions/cache@v3
130+
with:
131+
path: |
132+
~/.cargo/bin/
133+
~/.cargo/registry/index/
134+
~/.cargo/registry/cache/
135+
~/.cargo/git/db/
136+
~/.cargo/.crates.toml
137+
~/.cargo/.crates2.json
138+
target/
139+
key: ${{ runner.os }}-cargo-${{ matrix.target }}
140+
141+
# We install ripgrep via cargo to get the latest version (we need at least 14)
142+
# since ubuntu is still on 13 (at least it is while this is being written...)
143+
# We need 14 in order to generate completion files.
144+
- name: Install ripgrep
145+
run: cargo install ripgrep
146+
128147
- name: Use Cross
129148
run: |
130149
cargo install cross
@@ -184,6 +203,11 @@ jobs:
184203
staging="repgrep-${{ env.RELEASE_VERSION }}-${{ matrix.target }}"
185204
mkdir -p "$staging"/{complete,doc}
186205
206+
echo 'complete -F _rg rgr' > "${outdir}/rgr.bash"
207+
echo 'compdef $_comps[rg] rgr' > "${outdir}/_rgr"
208+
rg --generate complete-fish | sed 's/-c rg/-c rgr/' > "${outdir}/rgr.fish"
209+
rg --generate complete-powershell | sed "s/'rg'/'rgr'/" > "${outdir}/_rgr.ps1"
210+
187211
cp {LICENSE-*,CHANGELOG.md,README.md} "$staging/doc/"
188212
cp "$outdir"/{_rgr,rgr.bash,rgr.fish,_rgr.ps1} "$staging/complete/"
189213

.hidden

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
is this hidden?

CHANGELOG.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,18 @@
1+
# 0.15.0
2+
3+
- fae13fc don't treat patterns as regexes if --fixed-strings is passed
4+
- fae1e2b refactor argument parsing and remove (broken) stdin things
5+
- fae1696 fix an issue with capturing not working as expected
6+
- fae11c0 ensure we capture -h, -v and --version
7+
- fae1ed5 update how completions are generated since we no longer use clap
8+
- fae1341 support reading RIPGREP_CONFIG_FILE for arguments
9+
- fae1567 update README.md
10+
- fae1d8f update DEVELOPMENT_NOTES.md
11+
- fae1b324 update ci to run fmt and readme checks before tests
12+
- 946b8f5 Merge pull request #95 from herbygillot/docs-macports-install
13+
- fae1b328 update docs with macports instructions
14+
- 1741e0d docs: add MacPorts install instructions
15+
116
# 0.14.3
217

318
- 2b2e896 Merge pull request #93 from a-kenji/chore/move-to-ratatui

0 commit comments

Comments
 (0)