2022-02-07 12:32:43 +01:00
|
|
|
name: Package updates
|
|
|
|
|
|
|
|
on:
|
|
|
|
schedule:
|
2022-03-26 08:12:40 +01:00
|
|
|
- cron: "0 */6 * * *"
|
2022-02-07 12:32:43 +01:00
|
|
|
workflow_dispatch:
|
2022-03-26 08:12:40 +01:00
|
|
|
inputs:
|
|
|
|
packages:
|
|
|
|
description: "A space-seperated list of packages to update. Defaults to all packages"
|
|
|
|
default: "@all"
|
|
|
|
required: false
|
2022-02-07 12:32:43 +01:00
|
|
|
|
|
|
|
jobs:
|
|
|
|
update-packages:
|
|
|
|
if: github.repository == 'termux/termux-packages'
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2022-03-26 08:12:40 +01:00
|
|
|
- name: Clone repository
|
|
|
|
uses: actions/checkout@v2
|
|
|
|
with:
|
|
|
|
fetch-depth: 0
|
|
|
|
token: ${{ secrets.GH_API_KEY }}
|
|
|
|
- name: Process package updates
|
|
|
|
env:
|
|
|
|
GITHUB_TOKEN: ${{ secrets.GH_API_KEY }}
|
|
|
|
BUILD_PACKAGES: "true"
|
|
|
|
GIT_COMMIT_PACKAGES: "true"
|
|
|
|
GIT_PUSH_PACKAGES: "true"
|
|
|
|
run: |
|
|
|
|
git config --global user.name "Termux Github Actions"
|
2022-03-28 20:15:07 +02:00
|
|
|
git config --global user.email "contact@termux.org"
|
2022-03-26 08:12:40 +01:00
|
|
|
|
|
|
|
if [ "${{ github.event_name }}" == "workflow_dispatch" ]; then
|
|
|
|
./scripts/bin/update-packages ${{ github.event.inputs.packages }}
|
|
|
|
else
|
|
|
|
./scripts/bin/update-packages "@all"
|
|
|
|
fi
|