Skip to content

Commit fbe039a

Browse files
committed
chore: Update nightly-build.yml workflow to fix glibc related build error
1 parent 0745b24 commit fbe039a

File tree

1 file changed

+110
-110
lines changed

1 file changed

+110
-110
lines changed

.github/workflows/nightly-build.yml

Lines changed: 110 additions & 110 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@ name: Nightly Build
1010
on:
1111
push:
1212
branches:
13-
- nightly # Just for test purpose only with the nightly repo
13+
- nightly # Just for test purpose only with the nightly repo
1414
# This schedule will run only from the default branch
1515
schedule:
16-
- cron: '15 0 * * *' # run at 00:15 AM UTC
16+
- cron: "15 0 * * *" # run at 00:15 AM UTC
1717

1818
defaults:
1919
run:
@@ -27,7 +27,7 @@ jobs:
2727
# if: github.repository == 'nushell/nightly'
2828
steps:
2929
- name: Checkout
30-
uses: actions/[email protected].6
30+
uses: actions/[email protected].7
3131
if: github.repository == 'nushell/nightly'
3232
with:
3333
ref: main
@@ -71,117 +71,117 @@ jobs:
7171
fail-fast: false
7272
matrix:
7373
target:
74-
- aarch64-apple-darwin
75-
- x86_64-apple-darwin
76-
- x86_64-pc-windows-msvc
77-
- aarch64-pc-windows-msvc
78-
- x86_64-unknown-linux-gnu
79-
- x86_64-unknown-linux-musl
80-
- aarch64-unknown-linux-gnu
81-
- armv7-unknown-linux-gnueabihf
82-
- riscv64gc-unknown-linux-gnu
83-
extra: ['bin']
74+
- aarch64-apple-darwin
75+
- x86_64-apple-darwin
76+
- x86_64-pc-windows-msvc
77+
- aarch64-pc-windows-msvc
78+
- x86_64-unknown-linux-gnu
79+
- x86_64-unknown-linux-musl
80+
- aarch64-unknown-linux-gnu
81+
- armv7-unknown-linux-gnueabihf
82+
- riscv64gc-unknown-linux-gnu
83+
extra: ["bin"]
8484
include:
85-
- target: aarch64-apple-darwin
86-
os: macos-latest
87-
target_rustflags: ''
88-
- target: x86_64-apple-darwin
89-
os: macos-latest
90-
target_rustflags: ''
91-
- target: x86_64-pc-windows-msvc
92-
extra: 'bin'
93-
os: windows-latest
94-
target_rustflags: ''
95-
- target: x86_64-pc-windows-msvc
96-
extra: msi
97-
os: windows-latest
98-
target_rustflags: ''
99-
- target: aarch64-pc-windows-msvc
100-
extra: 'bin'
101-
os: windows-latest
102-
target_rustflags: ''
103-
- target: aarch64-pc-windows-msvc
104-
extra: msi
105-
os: windows-latest
106-
target_rustflags: ''
107-
- target: x86_64-unknown-linux-gnu
108-
os: ubuntu-20.04
109-
target_rustflags: ''
110-
- target: x86_64-unknown-linux-musl
111-
os: ubuntu-20.04
112-
target_rustflags: ''
113-
- target: aarch64-unknown-linux-gnu
114-
os: ubuntu-20.04
115-
target_rustflags: ''
116-
- target: armv7-unknown-linux-gnueabihf
117-
os: ubuntu-20.04
118-
target_rustflags: ''
119-
- target: riscv64gc-unknown-linux-gnu
120-
os: ubuntu-latest
121-
target_rustflags: ''
85+
- target: aarch64-apple-darwin
86+
os: macos-latest
87+
target_rustflags: ""
88+
- target: x86_64-apple-darwin
89+
os: macos-latest
90+
target_rustflags: ""
91+
- target: x86_64-pc-windows-msvc
92+
extra: "bin"
93+
os: windows-latest
94+
target_rustflags: ""
95+
- target: x86_64-pc-windows-msvc
96+
extra: msi
97+
os: windows-latest
98+
target_rustflags: ""
99+
- target: aarch64-pc-windows-msvc
100+
extra: "bin"
101+
os: windows-latest
102+
target_rustflags: ""
103+
- target: aarch64-pc-windows-msvc
104+
extra: msi
105+
os: windows-latest
106+
target_rustflags: ""
107+
- target: x86_64-unknown-linux-gnu
108+
os: ubuntu-22.04
109+
target_rustflags: ""
110+
- target: x86_64-unknown-linux-musl
111+
os: ubuntu-22.04
112+
target_rustflags: ""
113+
- target: aarch64-unknown-linux-gnu
114+
os: ubuntu-22.04
115+
target_rustflags: ""
116+
- target: armv7-unknown-linux-gnueabihf
117+
os: ubuntu-22.04
118+
target_rustflags: ""
119+
- target: riscv64gc-unknown-linux-gnu
120+
os: ubuntu-latest
121+
target_rustflags: ""
122122

123123
runs-on: ${{matrix.os}}
124124

125125
steps:
126-
- uses: actions/[email protected].6
127-
with:
128-
ref: main
129-
fetch-depth: 0
130-
131-
- name: Update Rust Toolchain Target
132-
run: |
133-
echo "targets = ['${{matrix.target}}']" >> rust-toolchain.toml
134-
135-
- name: Setup Rust toolchain and cache
136-
uses: actions-rust-lang/setup-rust-toolchain@v1.8.0
137-
# WARN: Keep the rustflags to prevent from the winget submission error: `CAQuietExec: Error 0xc0000135`
138-
with:
139-
rustflags: ''
140-
141-
- name: Setup Nushell
142-
uses: hustcer/[email protected]
143-
with:
144-
version: 0.93.0
145-
146-
- name: Release Nu Binary
147-
id: nu
148-
run: nu .github/workflows/release-pkg.nu
149-
env:
150-
OS: ${{ matrix.os }}
151-
REF: ${{ github.ref }}
152-
TARGET: ${{ matrix.target }}
153-
_EXTRA_: ${{ matrix.extra }}
154-
TARGET_RUSTFLAGS: ${{ matrix.target_rustflags }}
155-
156-
- name: Create an Issue for Release Failure
157-
if: ${{ failure() }}
158-
uses: JasonEtco/[email protected]
159-
env:
160-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
161-
with:
162-
update_existing: true
163-
search_existing: open
164-
filename: .github/AUTO_ISSUE_TEMPLATE/nightly-build-fail.md
165-
166-
- name: Set Outputs of Short SHA
167-
id: vars
168-
run: |
169-
echo "date=$(date -u +'%Y-%m-%d')" >> $GITHUB_OUTPUT
170-
sha_short=$(git rev-parse --short HEAD)
171-
echo "sha_short=${sha_short:0:7}" >> $GITHUB_OUTPUT
172-
173-
# REF: https://github.com/marketplace/actions/gh-release
174-
# Create a release only in nushell/nightly repo
175-
- name: Publish Archive
176-
uses: softprops/[email protected]
177-
if: ${{ startsWith(github.repository, 'nushell/nightly') }}
178-
with:
179-
prerelease: true
180-
files: ${{ steps.nu.outputs.archive }}
181-
tag_name: nightly-${{ steps.vars.outputs.sha_short }}
182-
name: Nu-nightly-${{ steps.vars.outputs.date }}-${{ steps.vars.outputs.sha_short }}
183-
env:
184-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
126+
- uses: actions/[email protected].7
127+
with:
128+
ref: main
129+
fetch-depth: 0
130+
131+
- name: Update Rust Toolchain Target
132+
run: |
133+
echo "targets = ['${{matrix.target}}']" >> rust-toolchain.toml
134+
135+
- name: Setup Rust toolchain and cache
136+
uses: actions-rust-lang/setup-rust-toolchain@v1.9.0
137+
# WARN: Keep the rustflags to prevent from the winget submission error: `CAQuietExec: Error 0xc0000135`
138+
with:
139+
rustflags: ""
140+
141+
- name: Setup Nushell
142+
uses: hustcer/[email protected]
143+
with:
144+
version: 0.93.0
145+
146+
- name: Release Nu Binary
147+
id: nu
148+
run: nu .github/workflows/release-pkg.nu
149+
env:
150+
OS: ${{ matrix.os }}
151+
REF: ${{ github.ref }}
152+
TARGET: ${{ matrix.target }}
153+
_EXTRA_: ${{ matrix.extra }}
154+
TARGET_RUSTFLAGS: ${{ matrix.target_rustflags }}
155+
156+
- name: Create an Issue for Release Failure
157+
if: ${{ failure() }}
158+
uses: JasonEtco/[email protected]
159+
env:
160+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
161+
with:
162+
update_existing: true
163+
search_existing: open
164+
filename: .github/AUTO_ISSUE_TEMPLATE/nightly-build-fail.md
165+
166+
- name: Set Outputs of Short SHA
167+
id: vars
168+
run: |
169+
echo "date=$(date -u +'%Y-%m-%d')" >> $GITHUB_OUTPUT
170+
sha_short=$(git rev-parse --short HEAD)
171+
echo "sha_short=${sha_short:0:7}" >> $GITHUB_OUTPUT
172+
173+
# REF: https://github.com/marketplace/actions/gh-release
174+
# Create a release only in nushell/nightly repo
175+
- name: Publish Archive
176+
uses: softprops/[email protected]
177+
if: ${{ startsWith(github.repository, 'nushell/nightly') }}
178+
with:
179+
prerelease: true
180+
files: ${{ steps.nu.outputs.archive }}
181+
tag_name: nightly-${{ steps.vars.outputs.sha_short }}
182+
name: Nu-nightly-${{ steps.vars.outputs.date }}-${{ steps.vars.outputs.sha_short }}
183+
env:
184+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
185185

186186
cleanup:
187187
name: Cleanup
@@ -193,7 +193,7 @@ jobs:
193193
- name: Waiting for Release
194194
run: sleep 1800
195195

196-
- uses: actions/[email protected].6
196+
- uses: actions/[email protected].7
197197
with:
198198
ref: main
199199

0 commit comments

Comments
 (0)