mirror of
https://github.com/rd-stuffs/msm-4.14.git
synced 2025-02-20 11:45:48 +08:00
Change-Id: I1f919344669f84a9d29ac5c88e3a30996ad05d52 Signed-off-by: Richard Raya <rdxzv.dev@gmail.com>
52 lines
1.3 KiB
YAML
52 lines
1.3 KiB
YAML
name: Build Kernel
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@main
|
|
|
|
- name: Setup timezone
|
|
uses: szenius/set-timezone@master
|
|
with:
|
|
timezoneLinux: "America/Sao_Paulo"
|
|
|
|
- name: Setup the environment
|
|
run: sudo apt-get install elfutils libarchive-tools -y
|
|
|
|
- name: Run build script
|
|
run: |
|
|
source build.sh
|
|
echo "ZIPNAME=${ZIPNAME}" >> $GITHUB_ENV
|
|
|
|
- name: Setup build date
|
|
run: echo "BUILD_DATE=$(date '+%H:%M %d/%m/%Y')" >> $GITHUB_ENV
|
|
|
|
- name: Git variables
|
|
run: |
|
|
HEAD="$(git rev-parse HEAD)"
|
|
HEAD_COMMIT="https://github.com/rd-stuffs/msm-4.14/commit/$HEAD"
|
|
echo "HEAD_COMMIT=${HEAD_COMMIT}" >> $GITHUB_ENV
|
|
|
|
- name: Upload build artifact
|
|
uses: actions/upload-artifact@main
|
|
with:
|
|
name: my-artifact
|
|
path: ${{ env.ZIPNAME }}
|
|
|
|
- name: Upload to Telegram
|
|
uses: appleboy/telegram-action@master
|
|
with:
|
|
to: ${{ secrets.TELEGRAM_CHAT_ID }}
|
|
token: ${{ secrets.TELEGRAM_BOT_TOKEN }}
|
|
document: ${{ env.ZIPNAME }}
|
|
message: |
|
|
${{ env.BUILD_DATE }}
|
|
|
|
${{ env.HEAD_COMMIT }}
|