Skip to content

Commit

Permalink
GH actions free up disk space (#18)
Browse files Browse the repository at this point in the history
* gh actions free up disk space

* cleanup free disk space commands

* cleanup free disk space commands
  • Loading branch information
1b5d authored Nov 13, 2023
1 parent c785a2c commit c247d50
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions .github/workflows/publish-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,19 @@ jobs:
steps:
- name: Free disk space
run: |
echo "Listing 100 largest packages"
dpkg-query -Wf '${Installed-Size}\t${Package}\n' | sort -n | tail -n 100
df -h
echo "Removing large packages"
sudo apt-get remove -y '^dotnet-.*'
sudo apt-get remove -y '^llvm-.*'
sudo apt-get remove -y 'php.*'
sudo apt-get remove -y azure-cli google-cloud-cli google-chrome-stable firefox powershell mono-devel
sudo apt-get clean
df -h
echo "Removing large directories"
rm -rf /usr/share/dotnet/
df -h
sudo apt-get autoremove -y >/dev/null 2>&1
sudo apt-get autoclean -y >/dev/null 2>&1
docker rmi $(docker image ls -aq) >/dev/null 2>&1
Expand Down

0 comments on commit c247d50

Please sign in to comment.