Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
ntkme committed Jun 13, 2024
1 parent d9436a7 commit 73da5b5
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 123 deletions.
117 changes: 0 additions & 117 deletions .github/workflows/build.yml

This file was deleted.

32 changes: 26 additions & 6 deletions .github/workflows/schedule.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,21 +33,41 @@ jobs:
- name: Checkout
uses: actions/checkout@v4

- name: Install Dependencies
run: |
TARGET=aosp_cf_x86_64_phone
ID=$(curl -fsSL https://ci.android.com/builds/branches/aosp-main/status.json | yq '.targets[] | select(.name == "$TARGET-trunk_staging-userdebug") | .last_known_good_build')
ARTIFACT_URL=$(node <<EOF
$(curl -fsSL "https://ci.android.com/builds/submitted/$ID/$TARGET-trunk_staging-userdebug/latest/cvd-host_package.zip" | grep 'var JSVariables = ')
console.log(JSVariables['artifactUrl'])
EOF
)
curl -fsSLo cvd-host_package.tar.gz "$ARTIFACT_URL"
tar -xzf cvd-host_package.tar.gz
- name: Download Image
run: |
ID=$(curl -fsSL https://ci.android.com/builds/branches/aosp-main/status.json | yq '.targets[] | select(.name == "${{ matrix.type }}-trunk_staging-userdebug") | .last_known_good_build')
TARGET=${{ matrix.type }}
ID=$(curl -fsSL https://ci.android.com/builds/branches/aosp-main/status.json | yq '.targets[] | select(.name == "$TARGET-trunk_staging-userdebug") | .last_known_good_build')
ARTIFACT_URL=$(node <<EOF
$(curl -fsSL "https://ci.android.com/builds/submitted/$ID/${{ matrix.type }}-trunk_staging-userdebug/latest/${{ matrix.type }}-img-$ID.zip" | grep 'var JSVariables = ')
$(curl -fsSL "https://ci.android.com/builds/submitted/$ID/$TARGET-trunk_staging-userdebug/latest/$TARGET-img-$ID.zip" | grep 'var JSVariables = ')
console.log(JSVariables['artifactUrl'])
EOF
)
curl -fsSLo ${{ matrix.type }}.zip "$ARTIFACT_URL"
set -x
curl -fsSLo $TARGET.zip "$ARTIFACT_URL"
- name: Mount Image
run: |
unzip ${{ matrix.type }}.zip super.img
mkdir sysroot
sudo mount -o loop,ro super.img sysroot
if unzip ${{ matrix.type }}.zip system.img; then
mkdir sysroot
sudo mount -o loop,ro super/system.img sysroot
else
unzip ${{ matrix.type }}.zip super.img
./bin/lpunpack super.img
mkdir sysroot
sudo mount -o loop,ro system_a.img sysroot
fi
- name: List Contents
run: |
Expand Down

0 comments on commit 73da5b5

Please sign in to comment.