Skip to content

Commit

Permalink
Release v0.3.3 (#108)
Browse files Browse the repository at this point in the history
* chores: removed travis
* chores: addded `release-draft` pipeline
* chores: release pipeline
* docs: remove python 3.5 mentions & deps
* release: version bump to 0.3.3
  • Loading branch information
butuzov committed May 30, 2021
1 parent 728f0f7 commit 831cb5c
Show file tree
Hide file tree
Showing 12 changed files with 83 additions and 98 deletions.
26 changes: 26 additions & 0 deletions .github/release-drafter.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name-template: 'v$NEXT_MINOR_VERSION'
tag-template: 'v$NEXT_MINOR_VERSION'
categories:
- title: 'Breaking Changes'
labels:
- 'breaking'
- title: 'Enhancements'
labels:
- 'enhancement'
- title: 'Database Changes'
labels:
- 'database'
- title: 'Bug Fixes'
labels:
- 'bug'
- title: 'Documentation and code quality'
labels:
- 'docs'
exclude-labels:
- 'tests'
- 'build(deps)'
change-template: '- $TITLE @$AUTHOR (#$NUMBER)'
template: |
## Changes
$CHANGES
14 changes: 14 additions & 0 deletions .github/workflows/release-draft.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
name: Release Drafter

on:
push:
branches:
- master

jobs:
update_release_draft:
runs-on: ubuntu-latest
steps:
- uses: release-drafter/release-drafter@v5
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
32 changes: 32 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Release new Version

on:
push:
tags:
- v*

jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.9'

# Python Package
- name: Install dependencies
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
run: |
python -m pip install --upgrade pip
pip install setuptools wheel -q
python setup.py sdist
- name: Publish a Python distribution to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
with:
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}
75 changes: 0 additions & 75 deletions .travis.yml

This file was deleted.

10 changes: 4 additions & 6 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,6 @@ help: dep-gawk



ghp:
@go get -u github.com/butuzov/ghp

# ~~~ Install ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Expand Down Expand Up @@ -225,10 +223,10 @@ deploy-prod: deploy build-prod ## PyPi Deploy (pypi.org)

pre-depeloy-check: venv clean deps ## Install Development Version
$(PYTHON) -m pip uninstall deadlinks -y
DEADLINKS_BRANCH=$(BRANCH) \
DEADLINKS_COMMIT=$(COMMIT) \
DEADLINKS_TAGGED=$(TAGGED) \
$(PYTHON) setup.py develop -q 2>&1 1> /dev/null
DEADLINKS_BRANCH=$(BRANCH) \
DEADLINKS_COMMIT=$(COMMIT) \
DEADLINKS_TAGGED=$(TAGGED) \
$(PYTHON) setup.py develop -q 2>&1 1> /dev/null

# ~~~ Docker ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Expand Down
6 changes: 1 addition & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,14 +43,10 @@ brew install butuzov/deadlinks/deadlinks
# activate virtual environment to keep your local site-packages clean.
python3 -m venv .venv
source .venv/bin/activate

# if you using Python 3.5 on the mac, install new version of pip
curl https://bootstrap.pypa.io/get-pip.py | python3.5
# if you using other version, just upgrade pip
pip install --upgrade pip

# in case if you developing within forked repository
cd /home/user/deadlinks-fork
cd /home/path/to/deadlinks
pip install -r requirements.txt
pip install -e .
```
Expand Down
2 changes: 1 addition & 1 deletion deadlinks/__version__.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
"""

# package meta data
__app_version__ = "0.3.2"
__app_version__ = "0.3.3"
__app_package__ = "deadlinks"
__app_license__ = "Apache License 2.0"
__app_website__ = "https://github.com/butuzov/deadlinks"
Expand Down
9 changes: 3 additions & 6 deletions deadlinks/link.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,15 +38,12 @@ class Link(URL):
Real reason why this exists, it's impossible situation on using class as
type definition, in one (two) of the methods.
In Python 3.5 its OK to use quoted class name.
In Python 3.6 we can import annotations from __future__
In Python 3.6 its OK to use quoted class name.
In Python 3.7 we can import annotations from __future__
What we can't do is to try catch, python version handling or
`__future__ import` as this is compile time operation. Therefore,
lets use Link.
TODO: 2020-09-13 get rid of python 3.5
https://devguide.python.org/#status-of-python-branches
"""
"""

def is_external(self, url: Union[URL, str]) -> bool:
""" Check if url is external to Link object. """
Expand Down
1 change: 0 additions & 1 deletion make_brew_formula.py
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,6 @@ def release(releases, pkg_cmp, pkg_ver):
'requirements': require("install") + require("brew"),
}

# python3.5 patch excuded as brew's python 3.7
options['requirements'] = list(
filter(lambda x: "python_full_version" not in x, options['requirements']))

Expand Down
1 change: 0 additions & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ requests>=2.22.0
click>=7.0
urllib3>=1.25.6
six==1.16.0
PyOpenSSL==19.1.0; python_full_version < '3.6.0'


# ^^^ KEEP THIS SECTION LAST --- ALWAYS ^^^
4 changes: 2 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ def readme() -> str:
deadlinks=deadlinks.__main__:main
''',
zip_safe=False,
python_requires='>=3.5',
python_requires='>=3.6',
url=data['app_website'],
license=data['app_license'],
platforms=['MacOS', 'Posix', 'Unix'],
Expand Down Expand Up @@ -159,10 +159,10 @@ def readme() -> str:

# Python version
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",

# License
"License :: OSI Approved :: Apache Software License",
Expand Down
1 change: 0 additions & 1 deletion tests/tests_cli_defaults_internal.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ def test_internal_200(tmpdir, runner):
assert "http://internal" in result['output']


# @pytest.mark.skipif(sys.version_info < (3, 6), reason="requires python3.6 or higher")
def test_internal_404(tmpdir, runner):

if not runner.supports('fs'):
Expand Down

0 comments on commit 831cb5c

Please sign in to comment.