Skip to content

Commit

Permalink
Merge pull request #29 from antirotor/master
Browse files Browse the repository at this point in the history
sync master to develop
  • Loading branch information
antirotor authored Feb 20, 2024
2 parents 8d55e26 + ca67b27 commit 70c9e4c
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 19 deletions.
26 changes: 14 additions & 12 deletions .github/workflows/pythonpublish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,22 +5,24 @@ on:
types: [created]

jobs:
deploy:
pypi-publish:
name: Publish to PyPI
runs-on: ubuntu-latest
environment:
name: release
url: https://pypi.org/project/${{ github.repository }}
permissions:
id-token: write
steps:
- uses: actions/checkout@v1
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v1
uses: actions/setup-python@v5
with:
python-version: '3.x'
- name: Install dependencies
python-version: '3.9'
- name: Install dependencies and build
run: |
python -m pip install --upgrade pip
pip install setuptools wheel twine
- name: Build and publish
env:
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
run: |
pip install setuptools wheel
python setup.py sdist bdist_wheel
twine upload dist/*
- name: Build and publish
uses: pypa/gh-action-pypi-publish@release/v1
3 changes: 2 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
[tool.poetry]
name = "speedcopy"
version = "2.1.5"
description = ""
description = "Replacement or alternative for python copyfile() utilizing server side copy on network shares for faster copying."
authors = ["Ondrej Samohel <[email protected]>"]
license = "MIT License"

[tool.poetry.dependencies]
python = ">=2.7"
Expand Down
13 changes: 7 additions & 6 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,6 @@
import os
import sys

if sys.version_info < (3, 4):
import importlib as imp
else:
import imp

from io import open


Expand All @@ -17,7 +12,13 @@
long_description = f.read()

version_file = os.path.abspath("speedcopy/version.py")
version_mod = imp.load_source("version", version_file)

if sys.version_info > (3, 4):
from importlib.machinery import SourceFileLoader
version_mod = SourceFileLoader("version", version_file).load_module()
else:
import imp
version_mod = imp.load_source("version", version_file)
version = version_mod.version

classifiers = [
Expand Down

0 comments on commit 70c9e4c

Please sign in to comment.