mirror of
https://github.com/sotam0316/docker-py-revanced.git
synced 2026-04-25 11:58:37 +09:00
Merge pull request #49 from nikhilbadyal/reuse-workflow
👷 Reuse workflows
This commit is contained in:
@@ -67,16 +67,20 @@ jobs:
|
|||||||
sleep 10
|
sleep 10
|
||||||
|
|
||||||
virustotal-scan:
|
virustotal-scan:
|
||||||
if: ${{ inputs.SKIP_VIRUSTOTAL_SCAN }}
|
|
||||||
needs: [ upload-to-github ]
|
needs: [ upload-to-github ]
|
||||||
uses: ./.github/workflows/virus-total-scan.yml
|
uses: nikhilbadyal/ghactions/.github/workflows/virustotal-scan.yml@main
|
||||||
|
with:
|
||||||
|
FILES: |
|
||||||
|
.apk$
|
||||||
|
request_rate: 4
|
||||||
|
if: ${{ inputs.SKIP_VIRUSTOTAL_SCAN }}
|
||||||
secrets:
|
secrets:
|
||||||
VT_API_KEY: ${{ secrets.VT_API_KEY }}
|
VT_API_KEY: ${{ secrets.VT_API_KEY }}
|
||||||
GH_TOKEN: ${{ secrets.GH_TOKEN }}
|
GH_TOKEN: ${{ secrets.GH_TOKEN }}
|
||||||
|
|
||||||
upload-to-telegram:
|
upload-to-telegram:
|
||||||
needs: [ build-apk ]
|
needs: [ build-apk ]
|
||||||
uses: ./.github/workflows/telegram-uploader.yml
|
uses: nikhilbadyal/ghactions/.github/workflows/telegram-uploader.yml@main
|
||||||
secrets:
|
secrets:
|
||||||
TELEGRAM_API_ID: ${{ secrets.TELEGRAM_API_ID }}
|
TELEGRAM_API_ID: ${{ secrets.TELEGRAM_API_ID }}
|
||||||
TELEGRAM_API_HASH: ${{ secrets.TELEGRAM_API_HASH }}
|
TELEGRAM_API_HASH: ${{ secrets.TELEGRAM_API_HASH }}
|
||||||
@@ -85,6 +89,7 @@ jobs:
|
|||||||
STICKER_ID: ${{ secrets.STICKER_ID }}
|
STICKER_ID: ${{ secrets.STICKER_ID }}
|
||||||
CHANGELOG_GITHUB_REPOSITORY: ${{ secrets.CHANGELOG_GITHUB_REPOSITORY }}
|
CHANGELOG_GITHUB_REPOSITORY: ${{ secrets.CHANGELOG_GITHUB_REPOSITORY }}
|
||||||
|
|
||||||
|
|
||||||
cleanup:
|
cleanup:
|
||||||
name: GitHub Cleanup
|
name: GitHub Cleanup
|
||||||
if: ${{ inputs.CLEANUP }}
|
if: ${{ inputs.CLEANUP }}
|
||||||
|
|||||||
@@ -18,3 +18,9 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
|
||||||
RELEASE_PATTERN: '[\s\S]*'
|
RELEASE_PATTERN: '[\s\S]*'
|
||||||
|
|
||||||
|
- name: Delete Workflow Runs
|
||||||
|
uses: nikhilbadyal/ghactions/.github/workflows/github-workflow-cleaner.yml@main
|
||||||
|
with:
|
||||||
|
GH_TOKEN: ${{ secrets.GH_TOKEN }}
|
||||||
|
GITHUB_REPOSITORY: ${{ github.repository }}
|
||||||
|
|||||||
@@ -1,29 +0,0 @@
|
|||||||
name: Linter
|
|
||||||
|
|
||||||
env:
|
|
||||||
DOCKER_BUILDKIT: 1
|
|
||||||
COMPOSE_DOCKER_CLI_BUILD: 1
|
|
||||||
|
|
||||||
on:
|
|
||||||
workflow_call:
|
|
||||||
workflow_dispatch:
|
|
||||||
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
linter:
|
|
||||||
timeout-minutes: 5
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout
|
|
||||||
uses: actions/checkout@v3.1.0
|
|
||||||
|
|
||||||
- name: Setup Python
|
|
||||||
uses: actions/setup-python@v4.3.0
|
|
||||||
with:
|
|
||||||
python-version: "3.10"
|
|
||||||
cache: pip
|
|
||||||
cache-dependency-path: |
|
|
||||||
requirements.txt
|
|
||||||
|
|
||||||
- name: Run pre-commit
|
|
||||||
uses: pre-commit/action@v3.0.0
|
|
||||||
@@ -9,7 +9,9 @@ on:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
linter-pr-check:
|
linter-pr-check:
|
||||||
uses: ./.github/workflows/linter.yml
|
uses: nikhilbadyal/ghactions/.github/workflows/python-linter.yml@main
|
||||||
|
with:
|
||||||
|
PYTHON_VERSION: '3.10'
|
||||||
build-apk-pr-check:
|
build-apk-pr-check:
|
||||||
uses: ./.github/workflows/build-artifact.yml
|
uses: ./.github/workflows/build-artifact.yml
|
||||||
secrets:
|
secrets:
|
||||||
|
|||||||
@@ -10,30 +10,9 @@ permissions:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
auto-update:
|
auto-update:
|
||||||
timeout-minutes: 5
|
uses: nikhilbadyal/ghactions/.github/workflows/python-precommit-updater.yml@main
|
||||||
if: github.repository == 'nikhilbadyal/docker-py-revanced'
|
if: github.repository == 'nikhilbadyal/docker-py-revanced'
|
||||||
runs-on: ubuntu-latest
|
secrets:
|
||||||
steps:
|
GH_TOKEN: ${{ secrets.GH_TOKEN }}
|
||||||
- name: Checkout
|
with:
|
||||||
uses: actions/checkout@v3.1.0
|
PYTHON_VERSION: '3.10'
|
||||||
|
|
||||||
- name: Setup Python
|
|
||||||
uses: actions/setup-python@v4.3.0
|
|
||||||
with:
|
|
||||||
python-version: '3.x'
|
|
||||||
|
|
||||||
- name: Install pre-commit
|
|
||||||
run: pip install pre-commit
|
|
||||||
|
|
||||||
- name: Updated Hooks
|
|
||||||
run: pre-commit autoupdate
|
|
||||||
|
|
||||||
- name: Create Pull Request
|
|
||||||
uses: peter-evans/create-pull-request@v4.1.3
|
|
||||||
with:
|
|
||||||
token: ${{ secrets.GH_TOKEN }}
|
|
||||||
branch: update/pre-commit-autoupdate
|
|
||||||
title: ⬆️Update pre-commit hooks
|
|
||||||
commit-message: ⬆️updated pre-commit hooks
|
|
||||||
body: ✨Update versions of tools in pre-commit configs to latest version
|
|
||||||
labels: pre-commit✨
|
|
||||||
|
|||||||
@@ -31,7 +31,7 @@ on:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
tg-upload:
|
tg-upload:
|
||||||
uses: ./.github/workflows/telegram-uploader.yml
|
uses: nikhilbadyal/ghactions/.github/workflows/telegram-uploader.yml@main
|
||||||
secrets:
|
secrets:
|
||||||
TELEGRAM_API_ID: ${{ inputs.API_ID }}
|
TELEGRAM_API_ID: ${{ inputs.API_ID }}
|
||||||
TELEGRAM_API_HASH: ${{ inputs.API_HASH }}
|
TELEGRAM_API_HASH: ${{ inputs.API_HASH }}
|
||||||
|
|||||||
@@ -1,37 +0,0 @@
|
|||||||
name: Telegram Upload
|
|
||||||
|
|
||||||
on:
|
|
||||||
workflow_dispatch:
|
|
||||||
workflow_call:
|
|
||||||
secrets:
|
|
||||||
TELEGRAM_API_ID:
|
|
||||||
required: true
|
|
||||||
TELEGRAM_API_HASH:
|
|
||||||
required: true
|
|
||||||
TELEGRAM_BOT_TOKEN:
|
|
||||||
required: true
|
|
||||||
TELEGRAM_CHAT_ID:
|
|
||||||
required: true
|
|
||||||
STICKER_ID:
|
|
||||||
required: true
|
|
||||||
CHANGELOG_GITHUB_REPOSITORY:
|
|
||||||
required: false
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
tg-upload:
|
|
||||||
name: Telegram Upload
|
|
||||||
timeout-minutes: 5
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Upload to Telegram
|
|
||||||
if: ${{ env.HAVE_TELEGRAM_API_ID == 'true' }}
|
|
||||||
uses: nikhilbadyal/ghaction-telegram-uploader@main
|
|
||||||
with:
|
|
||||||
API_ID: ${{ secrets.TELEGRAM_API_ID }}
|
|
||||||
API_HASH: ${{ secrets.TELEGRAM_API_HASH }}
|
|
||||||
BOT_TOKEN: ${{ secrets.TELEGRAM_BOT_TOKEN }}
|
|
||||||
CHAT_ID: ${{ secrets.TELEGRAM_CHAT_ID }}
|
|
||||||
STICKER_ID: ${{ secrets.STICKER_ID }}
|
|
||||||
CHANGELOG_GITHUB_REPOSITORY: ${{ secrets.CHANGELOG_GITHUB_REPOSITORY }}
|
|
||||||
env:
|
|
||||||
HAVE_TELEGRAM_API_ID: ${{ secrets.TELEGRAM_API_ID != '' }}
|
|
||||||
@@ -41,9 +41,7 @@ def main() -> None:
|
|||||||
output = "-custom-icon-" if was_og_build else ""
|
output = "-custom-icon-" if was_og_build else ""
|
||||||
app = "youtube"
|
app = "youtube"
|
||||||
_, version, is_experimental = patcher.get_app_configs(app)
|
_, version, is_experimental = patcher.get_app_configs(app)
|
||||||
logger.info(parser.get_all_patches())
|
|
||||||
parser.invert_patch(branding_patch)
|
parser.invert_patch(branding_patch)
|
||||||
logger.info(parser.get_all_patches())
|
|
||||||
parser.patch_app(
|
parser.patch_app(
|
||||||
app=app,
|
app=app,
|
||||||
version=version,
|
version=version,
|
||||||
|
|||||||
Reference in New Issue
Block a user