Skip to content

Commit 4396489

Browse files
committed
Merge branch 'release/sameold-0.4.0'
2 parents b970e93 + a11a0d2 commit 4396489

32 files changed

+2204
-1300
lines changed

.github/workflows/rust_release.yml

Lines changed: 19 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: Release
22

33
on:
44
push:
5-
branches: [ "release/**", "develop" ]
5+
branches: [ "release/**", "develop", "staging/**" ]
66
tags: [ "samedec-*" ]
77

88
permissions:
@@ -60,11 +60,15 @@ jobs:
6060

6161
needs: vendor_sources
6262

63+
# qemu cross-compiling is very slow
64+
timeout-minutes: 60
65+
6366
env:
6467
# See <https://hub.docker.com/_/rust> for list of tags
65-
BUILD_RUST_TAG: 1.67.0
68+
BUILD_RUST_TAG: 1.70.0
6669
BUILD_OS_GNU: slim-buster
6770
BUILD_OS_MUSL: alpine
71+
CARGO_REGISTRIES_CRATES_IO_PROTOCOL: sparse
6872

6973
strategy:
7074
matrix:
@@ -102,19 +106,18 @@ jobs:
102106
enableCrossOsArchive: true
103107
fail-on-cache-miss: true
104108

105-
- name: Workaround for https://github.com/rust-lang/cargo/issues/8719
106-
run: |
107-
sudo mkdir -p /var/lib/docker
108-
sudo mount -t tmpfs -o size=10G none /var/lib/docker
109-
sudo systemctl restart docker
109+
- name: Set swap space
110+
uses: pierotofy/[email protected]
111+
with:
112+
swap-size-gb: 10
110113

111114
- name: Set up QEMU
112-
uses: docker/setup-qemu-action@v2
115+
uses: docker/setup-qemu-action@v3
113116
with:
114117
platforms: all
115118

116119
- name: Set up Docker Buildx
117-
uses: docker/setup-buildx-action@v1
120+
uses: docker/setup-buildx-action@v3
118121

119122
- name: Prepare output directory
120123
run: |
@@ -126,7 +129,7 @@ jobs:
126129
# install/bin/samedec-x86_64-unknown-linux-gnu
127130
# and the like.
128131
- name: Build
129-
uses: docker/build-push-action@v3
132+
uses: docker/build-push-action@v5
130133
with:
131134
context: .
132135
push: false
@@ -227,17 +230,9 @@ jobs:
227230
- name: Run integration tests
228231
shell: bash
229232
run: |
230-
set -e;
231-
"$samedec_exe" --version
232-
for file in $(basename -s .bin sample/*.s16le.bin); do
233-
printf '[%s]\n' "$file";
234-
"$samedec_exe" -r 22050 <"sample/$file.bin" | tee result;
235-
cmp result "sample/$file.txt" || {
236-
echo "FAIL!";
237-
exit 1;
238-
};
239-
echo "PASS";
240-
done
233+
pushd sample &&
234+
./test.sh &&
235+
popd
241236
242237
- name: Copy artifact
243238
shell: bash
@@ -313,17 +308,9 @@ jobs:
313308
314309
- name: Run integration tests
315310
run: |
316-
set -e;
317-
"$samedec_exe" --version
318-
for file in $(basename -s .bin sample/*.s16le.bin); do
319-
printf '[%s]\n' "$file";
320-
"$samedec_exe" -r 22050 <"sample/$file.bin" | tee result;
321-
cmp result "sample/$file.txt" || {
322-
echo "FAIL!";
323-
exit 1;
324-
};
325-
echo "PASS";
326-
done
311+
pushd sample &&
312+
./test.sh &&
313+
popd
327314
328315
- name: Copy artifact
329316
run: |

.github/workflows/rust_test.yml

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -114,21 +114,14 @@ jobs:
114114
enableCrossOsArchive: true
115115
fail-on-cache-miss: true
116116

117-
- name: Build and test samedec
117+
- name: Build and unit-test samedec
118118
shell: bash
119119
run: |
120120
cargo test --frozen -p samedec --verbose
121121
122122
- name: Run integration tests
123123
shell: bash
124124
run: |
125-
set -e;
126-
for file in $(basename -s .bin sample/*.s16le.bin); do
127-
printf '[%s]\n' "$file";
128-
cargo run -p samedec -- -r 22050 <"sample/$file.bin" | tee result;
129-
cmp result "sample/$file.txt" || {
130-
echo "FAIL!";
131-
exit 1;
132-
};
133-
echo "PASS";
134-
done
125+
pushd sample
126+
./test.sh
127+
popd

0 commit comments

Comments
 (0)