Skip to content

Commit

Permalink
workflow changes
Browse files Browse the repository at this point in the history
  • Loading branch information
itsnebulalol committed Aug 31, 2022
1 parent d41a750 commit 5ffe86c
Show file tree
Hide file tree
Showing 6 changed files with 53 additions and 61 deletions.
16 changes: 14 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
name: Build package and produce artifact

on:
release:
types: [published]

push:
paths-ignore:
- 'README.md'
Expand Down Expand Up @@ -42,7 +45,7 @@ jobs:
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.9'
python-version: '3.10'

- name: Install dependencies
run: |
Expand All @@ -53,7 +56,16 @@ jobs:
run: |
make build
- uses: actions/upload-artifact@v3
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: Permasigner
path: dist/*

- name: Publish to PyPi
if: startsWith(github.ref, 'refs/tags/')
env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.PYPI_TOKEN }}
run: |
twine upload dist/*
36 changes: 21 additions & 15 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
@@ -1,20 +1,26 @@
name: Build and publish Docker image

on:
push:
paths-ignore:
- 'README.md'
- 'book.json'
- '.gitignore'
- '.pep8'
- 'Dockerfile.development'
- '.devcontainer/**'
- '.vscode/**'
- '.github/**'
- '!.github/workflows/docker.yml'
- 'docs/**'
branches:
- "main"
#push:
# paths-ignore:
# - 'README.md'
# - 'book.json'
# - '.gitignore'
# - '.pep8'
# - 'Dockerfile.development'
# - '.devcontainer/**'
# - '.vscode/**'
# - '.github/**'
# - '!.github/workflows/docker.yml'
# - 'docs/**'
# branches:
# - "main"

workflow_run:
workflows: ["Test script"]
branches: [main]
types:
- completed

jobs:
docker:
Expand All @@ -39,6 +45,6 @@ jobs:
uses: docker/build-push-action@v3
with:
context: .
platforms: linux/amd64,linux/arm64
platforms: linux/amd64, linux/arm64
push: true
tags: itsnebulalol/permasigner:latest
10 changes: 6 additions & 4 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,16 +19,18 @@ on:
workflow_dispatch:

jobs:
autopep8:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Checkout
uses: actions/checkout@v3

- name: autopep8
- name: Lint with autopep8
uses: peter-evans/autopep8@v1
with:
args: --recursive --in-place --global-config ".pep8" .

- uses: stefanzweifel/git-auto-commit-action@v4
- name: Commit changes
uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: Lint script with autopep8
32 changes: 0 additions & 32 deletions .github/workflows/publish.yml

This file was deleted.

7 changes: 4 additions & 3 deletions .github/workflows/run.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@ jobs:
uses: actions/checkout@v3

# Setup which version of Python to use
- name: Set up Python 3.9
- name: Set up Python 3.10
uses: actions/setup-python@v4
with:
python-version: 3.9
python-version: "3.10"

# Install dependencies
- name: Install dependencies
Expand All @@ -33,7 +33,8 @@ jobs:
run: python3 main.py -u ${{ github.event.inputs.ipa }} -d

# Upload test artifact
- uses: actions/upload-artifact@v3
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: App.deb
path: output/*
13 changes: 8 additions & 5 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ jobs:
strategy:
matrix:
# Run with all these versions of Python
python-version: [3.7, 3.8, 3.9]
python-version: [3.8, 3.9, "3.10"]

steps:
# Checkout the latest code from the repo
Expand Down Expand Up @@ -67,7 +67,8 @@ jobs:
run: python main.py -u https://github.com/Odyssey-Team/Taurine/releases/download/1.1.6/Taurine-1.1.6.ipa -d

# Upload test artifact
- uses: actions/upload-artifact@v3
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: TaurineTest-linux-Python${{ matrix.python-version }}.deb
path: output/**
Expand Down Expand Up @@ -117,7 +118,8 @@ jobs:
run: python3 -m permasigner -u https://github.com/Odyssey-Team/Taurine/releases/download/1.1.6/Taurine-1.1.6.ipa -o ${GITHUB_WORKSPACE}/output/ -d

# Upload test artifact
- uses: actions/upload-artifact@v3
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: TaurineTest-${{ matrix.os }}-Python${{ matrix.python-version }}.deb
path: output/**
Expand All @@ -131,7 +133,7 @@ jobs:
os: [windows-latest]

# Run with all these versions of Python
python-version: [3.7, 3.8, 3.9]
python-version: [3.8, 3.9, "3.10"]

steps:
# Checkout the latest code from the repo
Expand Down Expand Up @@ -159,7 +161,8 @@ jobs:
run: python -m permasigner -u https://github.com/Odyssey-Team/Taurine/releases/download/1.1.6/Taurine-1.1.6.ipa -o ${GITHUB_WORKSPACE}/output/ -d

# Upload test artifact
- uses: actions/upload-artifact@v3
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: TaurineTest-${{ matrix.os }}-Python${{ matrix.python-version }}.deb
path: \output\**
Expand Down

0 comments on commit 5ffe86c

Please sign in to comment.