SmsForwarder/.github/workflows/Nightly_Build.yml

45 lines
1.3 KiB
YAML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

name: Nightly Build
# 触发器
on:
schedule:
- cron: '30 15 * * *' #每天在国际标准时间14点(北京时间+8即 23:30)
workflow_dispatch:
inputs:
root_sol:
description: "Nightly Build Title"
required: true
default: "SmsForwarder"
jobs:
build:
runs-on: ubuntu-latest
# if: github.event.repository.owner.id == github.event.sender.id
# 设置jdk环境为11
steps:
- uses: actions/checkout@v2
- name: set up JDK 11
uses: actions/setup-java@v1
with:
java-version: 11
# ref: dev
# 获取打包秘钥
- name: Checkout Android Keystore
uses: actions/checkout@v2
with:
repository: pppscn/keystore
token: ${{ secrets.TOKEN }} # 连接仓库的token,需要单独配置
path: keystore # 仓库的根目录名
# 打包release
- name: Build with Gradle
run: bash ./gradlew assembleRelease
# 存档打包的文件
- name: Archive production artifacts
uses: actions/upload-artifact@v3
with:
name: SmsForwarder Nightly Build
path: app/build/outputs/apk/release/*.apk
if-no-files-found: error