Skip to content
Open
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
22 changes: 7 additions & 15 deletions .github/workflows/ubuntu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:
strategy:
matrix:
os: ["ubuntu-latest"]
python-version: ['3.6', '3.8']
python-version: ['3.8']
ymlfile: ['environment.yml']
include:
- python-version: 3.8
Expand All @@ -18,11 +18,11 @@ jobs:
runs-on: ${{ matrix.os }}

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
with:
submodules: true # does not work with self-hosted testdata
fetch-depth: 0
- uses: conda-incubator/setup-miniconda@v2
- uses: conda-incubator/setup-miniconda@v3
with:
miniconda-version: "latest"
auto-update-conda: true
Expand Down Expand Up @@ -65,24 +65,16 @@ jobs:
shell: bash -l {0}
run: |
git status
pip install setuptools_scm
if [ ${{ matrix.os }} == "windows-latest" ]
then
# build whls on windows
pip install wheel
python setup.py bdist_wheel --dist-dir ./dist
else
# build dist on linux
python setup.py sdist --dist-dir ./dist
fi
pip install build
python -m build
ls ./dist
- name: Upload Artifacts
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v4
with:
name: Artifacts
path: ./dist/*
- name: Publish package
if: ${{ matrix.pypi }}
if: ${{ matrix.pypi && github.repository == 'cpaulik/datedown' }}
uses: pypa/gh-action-pypi-publish@release/v1
with:
password: ${{ secrets.PYPI_API_TOKEN }}
Expand Down
6 changes: 4 additions & 2 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ moment.
Installation
============

Requires Python >= 3.8.

* Install `wget <https://en.wikipedia.org/wiki/Wget>`_ if it is not already on
your system.
* ``pip install datedown``
Expand Down Expand Up @@ -79,5 +81,5 @@ API Documentation for more details about these functions.
Note
====

This project has been set up using PyScaffold 3.3 For details and usage
information on PyScaffold see http://pyscaffold.readthedocs.org/.
This project has been set up using PyScaffold 4.6. For details and usage
information on PyScaffold see https://pyscaffold.org/.
6 changes: 6 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
[build-system]
requires = ["setuptools>=46.1.0", "setuptools_scm[toml]>=5"]
build-backend = "setuptools.build_meta"

[tool.setuptools_scm]
version_scheme = "no-guess-dev"
4 changes: 2 additions & 2 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ include_package_data = True
package_dir =
=src
# DON'T CHANGE THE FOLLOWING LINE! IT WILL BE UPDATED BY PYSCAFFOLD!
setup_requires = pyscaffold>=3.3a0,<4
setup_requires = pyscaffold>=4,<5
# Add here dependencies of your project (semicolon/line-separated), e.g.
# install_requires = numpy; scipy
# The usage of test_requires is discouraged, see `Dependency Management` docs
Expand Down Expand Up @@ -115,5 +115,5 @@ exclude =
[pyscaffold]
# PyScaffold's parameters when the project was created.
# This will be used when updating. Do not change!
version = 3.3
version = 4.6
package = datedown
19 changes: 1 addition & 18 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,22 +1,5 @@
# -*- coding: utf-8 -*-
"""
Setup file for datedown.
Use setup.cfg to configure your project.

This file was generated with PyScaffold 3.3.
PyScaffold helps you to put up the scaffold of your new Python project.
Learn more under: https://pyscaffold.org/
"""
import sys
from pkg_resources import VersionConflict, require
from setuptools import setup

try:
require("setuptools>=38.3")
except VersionConflict:
print("Error: version of setuptools is too old (<38.3)!")
sys.exit(1)


if __name__ == "__main__":
setup(use_pyscaffold=True)
setup(use_scm_version={"version_scheme": "no-guess-dev"})
10 changes: 4 additions & 6 deletions src/datedown/__init__.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
# -*- coding: utf-8 -*-
from pkg_resources import DistributionNotFound, get_distribution
from importlib.metadata import PackageNotFoundError, version

try:
# Change here if project is renamed and does not equal the package name
dist_name = __name__
__version__ = get_distribution(dist_name).version
except DistributionNotFound:
__version__ = version(dist_name)
except PackageNotFoundError:
__version__ = "unknown"
finally:
del get_distribution, DistributionNotFound
del version, PackageNotFoundError