Skip to content

Commit

Permalink
Added runtimes to the repo. (#79)
Browse files Browse the repository at this point in the history
* Added runtimes to the repo.

* Changed code to reduce disk usage on github actions.

* Fixed bug in tools/build_data.py.

* Added free space output.

* Testing something.

* Final github action fixes for free space.

* Added hash cache to speed up tools/build_release.py and tools/build_data.py.
  • Loading branch information
kloptops authored Feb 11, 2024
1 parent 56f81b7 commit 4097eae
Show file tree
Hide file tree
Showing 23 changed files with 304 additions and 47 deletions.
21 changes: 21 additions & 0 deletions .github/workflows/pull_request.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@ name: Pull Request Check

on:
pull_request:
paths-ignore:
- '.github/**'
- 'README.md'
- 'tools/**'
branches:
- main

Expand All @@ -19,8 +23,21 @@ jobs:
- uses: hmarr/debug-action@v2
name: "debug: ${{github.event_name}}"

- name: Clean out files part 1
run: |
sudo rm -rf /usr/share/dotnet
sudo rm -rf /opt/ghc
sudo rm -rf "/usr/local/share/boost"
sudo rm -rf "$AGENT_TOOLSDIRECTORY"
- uses: actions/checkout@v4

- name: Clean out files part 2
run: |
rm -rf .git
echo "Free Space"
df -h
- name: env - better defaulting of env vars;
id: env
run: |
Expand Down Expand Up @@ -64,3 +81,7 @@ jobs:
touch .github_check
python3 tools/build_data.py
python3 tools/build_release.py --do-check
- name: Check Free Space
run: |
df -h
29 changes: 12 additions & 17 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,20 @@ jobs:
- uses: hmarr/debug-action@v2
name: "debug: ${{github.event_name}}"

- uses: actions/checkout@v4

- name: Clean out files for more space
- name: Clean out files part 1
run: |
sudo rm -rf /usr/share/dotnet
sudo rm -rf /opt/ghc
sudo rm -rf "/usr/local/share/boost"
sudo rm -rf "$AGENT_TOOLSDIRECTORY"
- uses: actions/checkout@v4

- name: Clean out files part 2
run: |
rm -rf .git
echo "Free Space"
df -h
- name: env - better defaulting of env vars;
id: env
Expand Down Expand Up @@ -64,19 +69,6 @@ jobs:

######################################################################
## Only run these if it is the PortMaster-New repo
- uses: robinraju/[email protected]
if: ${{ steps.env.outputs.RELEASE_REPO }} == "PortMaster-New"
with:
out-file-path: "releases"
repository: "PortsMaster/PortMaster-Runtime"
tag: "runtimes"
fileName: "*.squashfs"

- name: Remove Zulu JDK
if: ${{ steps.env.outputs.RELEASE_REPO }} == "PortMaster-New"
run: |
rm -f releases/zulu*
- uses: robinraju/[email protected]
if: ${{ steps.env.outputs.RELEASE_REPO }} == "PortMaster-New"
with:
Expand All @@ -99,7 +91,6 @@ jobs:
python3 tools/build_data.py
python3 tools/build_release.py "${{steps.date.outputs.date}}"
rm -fv releases/.gitignore
rm -f releases/*.squashfs
- name: "Prepare Release"
uses: ncipollo/release-action@v1
Expand Down Expand Up @@ -128,6 +119,10 @@ jobs:
repo: ${{ steps.env.outputs.RELEASE_REPO }}
owner: ${{ steps.env.outputs.RELEASE_ORG }}

- name: Check Free Space
run: |
df -h
- name: Release Info
id: info
run: |
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,4 @@

# Special file, ignore it. :)
.github_check
.hash_cache
2 changes: 2 additions & 0 deletions runtimes/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Autogenerated by tools/build_data.py
mono-6.12.0.122-aarch64.squashfs
Loading

0 comments on commit 4097eae

Please sign in to comment.