Skip to content

Commit 5ab271e

Browse files
chore: Update rust to 1.94 (#214)
1 parent 448cf3d commit 5ab271e

File tree

4 files changed

+56
-16
lines changed

4 files changed

+56
-16
lines changed

.github/workflows/release.yaml

Lines changed: 45 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@ name: Prebuild
22

33
on:
44
push:
5-
branches: [main, feat/prebuild]
5+
branches: [main]
6+
pull_request:
67

78
jobs:
89
build:
@@ -61,9 +62,6 @@ jobs:
6162

6263
- name: Install Rust
6364
run: |
64-
# https://github.com/rust-cross/cargo-zigbuild/issues/327
65-
rustup toolchain install nightly-2025-02-19
66-
rustup default nightly-2025-02-19
6765
rustup target add ${{ matrix.target }}
6866
6967
- name: Build for Linux
@@ -96,6 +94,7 @@ jobs:
9694
name: Release
9795
needs: build
9896
runs-on: ubuntu-latest
97+
if: github.event_name == 'push'
9998
permissions:
10099
contents: write
101100
steps:
@@ -132,4 +131,45 @@ jobs:
132131
prerelease: true
133132
generate_release_notes: false
134133
body: |
135-
Nightly release from commit: ${{ github.sha }}
134+
Nightly release from commit: ${{ github.sha }}
135+
136+
comment-on-pr:
137+
name: Comment on PR
138+
needs: build
139+
runs-on: ubuntu-latest
140+
if: github.event_name == 'pull_request'
141+
permissions:
142+
pull-requests: write
143+
steps:
144+
- name: Get short SHA
145+
id: vars
146+
run: echo "short_sha=${GITHUB_SHA::7}" >> $GITHUB_OUTPUT
147+
148+
- name: Find existing comment
149+
uses: peter-evans/find-comment@v3
150+
id: find-comment
151+
with:
152+
issue-number: ${{ github.event.pull_request.number }}
153+
comment-author: "github-actions[bot]"
154+
body-includes: "<!-- fff-nvim-build-comment -->"
155+
156+
- name: Create or update PR comment
157+
uses: peter-evans/create-or-update-comment@v4
158+
with:
159+
comment-id: ${{ steps.find-comment.outputs.comment-id }}
160+
issue-number: ${{ github.event.pull_request.number }}
161+
edit-mode: replace
162+
body: |
163+
<!-- fff-nvim-build-comment -->
164+
## 🔨 Build Artifacts for your PR
165+
166+
You can test the prebuilt binaries if you use lazy.nvim right now.
167+
168+
```lua
169+
{
170+
"dmtrKovalenko/fff.nvim",
171+
tag = "${{ steps.vars.outputs.short_sha }}",
172+
}
173+
```
174+
---
175+
*Built from ${{ github.sha }}*

flake.lock

Lines changed: 9 additions & 9 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lua/fff/rust/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ pub fn fuzzy_search_files(
157157
Option<usize>,
158158
),
159159
) -> LuaResult<LuaValue> {
160-
let Some(ref mut picker) = *FILE_PICKER.write().map_err(|_| Error::AcquireItemLock)? else {
160+
let Some(ref picker) = *FILE_PICKER.read().map_err(|_| Error::AcquireItemLock)? else {
161161
return Err(Error::FilePickerMissing)?;
162162
};
163163

rust-toolchain.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[toolchain]
2-
channel = "nightly-2025-09-01"
2+
channel = "nightly-2026-01-08"
33
components = [
44
"clippy-preview",
55
"rustfmt-preview",

0 commit comments

Comments
 (0)