Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

24 add versioning #27

Merged
merged 11 commits into from
Jan 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 24 additions & 0 deletions .github/workflows/pylint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Pylint

on: [push]

jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9", "3.10", "3.11"]
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
pip install pylint
- name: Run pylint
run: |
pylint **/*.py
25 changes: 25 additions & 0 deletions .github/workflows/run_unittests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Run Unit Tests
on: [push]
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9", "3.10", "3.11"]
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Install exiftool
run: |
sudo apt-get update
sudo apt-get install -y libimage-exiftool-perl
- name: Run tests
run: |
python -m unittest discover unittests
27 changes: 27 additions & 0 deletions .github/workflows/update-version-file.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Update Version JSON

on:
push:
branches:
- master

jobs:
update-version-json:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Get commit code
run: echo "{commit_code}={$(git rev-parse HEAD)}" >> $GITHUB_OUTPUT
id: get_commit_code
- name: Update version.json
run: |
COMMIT_HASH=$(git rev-parse --short=7 HEAD)
sed -i "s/\"version\": \".*\"/\"version\": \"$COMMIT_HASH\"/g" version.json
- name: Commit and push changes
run: |
git config --global user.name "GitHub Actions"
git config --global user.email "[email protected]"
git add version.json
git commit -m "Update version.json with latest commit code"
git push
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
app_data/
saves/
exiftool.exe
TEST*
*.old*


# Byte-compiled / optimized / DLL files
Expand Down
Loading
Loading