Skip to content

CI: install git

CI: install git #12

Workflow file for this run

name: Compile and release
on:
push
jobs:
build:
runs-on: panda-arc
steps:
- name: Install git
run: sudo apt-get -qq update -y && sudo apt-get -qq install git -y
- uses: actions/checkout@v4 # Clones to $GITHUB_WORKSPACE. NOTE: this requires git > 2.18 (not on ubuntu 18.04 by default) to get .git directory and submodules
with:
fetch-depth: 0
submodules: 'true'
#- name: Install git and docker
# run: |
# apt update -y && apt install -y git curl
# #curl -fsSL https://get.docker.com -o install-docker.sh
# #sh install-docker.sh
#- name: Checkout code
# uses: actions/checkout@v4
# with:
# submodules: 'true'
#- name: Build
# run: |
# docker build -t kernel_builder .
# docker run --rm -v $PWD:/app kernel_builder /app/build.sh
# tar czvf kernels-latest.tar.gz binaries
- name: Build
uses: docker/build-push-action@v5
with:
context: .
load: true
tags: pandare/kernel_builder:latest
- name: Test
run: docker run --rm -v $PWD:/app pandare/kernel_builder /app/build.sh
- name: Save package
uses: actions/upload-artifact@v3
with:
name: kernels-latest.tar.gz
path: kernels-latest.tar.gz
- name: Create release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: release_${{ github.sha }}
release_name: Release ${{ github.ref }}
body: |
Release @${{ github.ref }}
draft: true
prerelease: false
- name: Upload release asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./kernels-latest.tar.gz
asset_name: kernels-latest.tar.gz
asset_content_type: application/gzip
- name: Publish release
uses: StuYarrow/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
id: ${{ steps.create_release.outputs.id }}