Skip to content

Commit c685fff

Browse files
committed
Only free up space for qt
1 parent bd2c84e commit c685fff

4 files changed

Lines changed: 9 additions & 12 deletions

File tree

.github/actions/cleanup/action.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,9 @@ runs:
55
- name: Free up space
66
shell: bash
77
run: |
8+
df -h
9+
echo
10+
echo Freeing up space
811
rm -rf .git/
912
docker system prune --force
1013
docker rmi $(docker image ls -aq) || true
@@ -22,3 +25,5 @@ runs:
2225
sudo rm -rf /opt/microsoft /opt/google
2326
sudo rm -rf /opt/az
2427
sudo rm -rf /usr/local/share/powershell
28+
echo
29+
df -h

.github/workflows/build.yml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,6 @@ jobs:
2222
password: ${{ secrets.GITHUB_TOKEN }}
2323
- name: Set up Docker Buildx
2424
uses: docker/setup-buildx-action@v3
25-
- name: Free up space
26-
uses: ./.github/actions/cleanup
2725
- name: Build and push toolchain
2826
run: ./scripts/build -p -g -s toolchain
2927
stage2:
@@ -42,8 +40,6 @@ jobs:
4240
password: ${{ secrets.GITHUB_TOKEN }}
4341
- name: Set up Docker Buildx
4442
uses: docker/setup-buildx-action@v3
45-
- name: Free up space
46-
uses: ./.github/actions/cleanup
4743
- name: Build and push toolchain
4844
run: ./scripts/build -p -g -s base
4945
stage3:
@@ -66,6 +62,7 @@ jobs:
6662
- name: Set up Docker Buildx
6763
uses: docker/setup-buildx-action@v3
6864
- name: Free up space
65+
if: ${{ matrix.target == 'qt' }}
6966
uses: ./.github/actions/cleanup
7067
- name: Build and push toolchain
7168
run: ./scripts/build -p -g -s ${{ matrix.target }}

.github/workflows/pr.yml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,6 @@ jobs:
2323
password: ${{ secrets.GITHUB_TOKEN }}
2424
- name: Set up Docker Buildx
2525
uses: docker/setup-buildx-action@v3
26-
- name: Free up space
27-
uses: ./.github/actions/cleanup
2826
- name: Build and push toolchain
2927
run: ./scripts/build -g -s toolchain
3028
- name: Export the container
@@ -74,8 +72,7 @@ jobs:
7472
tar xf ${{ needs.stage1.outputs.UUID }}-toolchain.tar.gz
7573
rm ${{ needs.stage1.outputs.UUID }}-toolchain.tar.gz
7674
popd
77-
- name: Free up space
78-
uses: ./.github/actions/cleanup
75+
uses: ./.github/actions/cleanup
7976
- name: Build and push toolchain
8077
run: ./scripts/build -g -s base -c ghcr.io/toltec-dev/toolchain=oci-layout://${{ runner.temp }}
8178
- name: Export the container
@@ -118,6 +115,7 @@ jobs:
118115
rm ${{ needs.stage2.outputs.UUID }}-base.tar.gz
119116
popd
120117
- name: Free up space
118+
if: ${{ matrix.target == 'qt' }}
121119
uses: ./.github/actions/cleanup
122120
- name: Build and push toolchain
123121
run: ./scripts/build -g -s ${{ matrix.target }} -c ghcr.io/toltec-dev/base=oci-layout://${{ runner.temp }}

.github/workflows/release.yml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,6 @@ jobs:
2222
echo "version=$VERSION" >> "$GITHUB_ENV"
2323
- name: Set up Docker Buildx
2424
uses: docker/setup-buildx-action@v3
25-
- name: Free up space
26-
uses: ./.github/actions/cleanup
2725
- name: Build and push toolchain
2826
run: ./scripts/build -p -g -s toolchain -v ${{ env.version }}
2927
stage2:
@@ -45,8 +43,6 @@ jobs:
4543
echo "version=$VERSION" >> "$GITHUB_ENV"
4644
- name: Set up Docker Buildx
4745
uses: docker/setup-buildx-action@v3
48-
- name: Free up space
49-
uses: ./.github/actions/cleanup
5046
- name: Build and push toolchain
5147
run: ./scripts/build -p -g -s base -v ${{ env.version }}
5248
stage3:
@@ -70,6 +66,7 @@ jobs:
7066
VERSION="$(echo "${{ github.ref }}" | cut -d / -f 3)"
7167
echo "version=$VERSION" >> "$GITHUB_ENV"
7268
- name: Free up space
69+
if: ${{ matrix.target == 'qt' }}
7370
uses: ./.github/actions/cleanup
7471
- name: Set up Docker Buildx
7572
uses: docker/setup-buildx-action@v3

0 commit comments

Comments
 (0)