Skip to content

Commit

Permalink
Drop Python 2.6 support, stop using pip-accel
Browse files Browse the repository at this point in the history
  • Loading branch information
xolox committed Feb 9, 2020
1 parent d568cfd commit 6576bae
Show file tree
Hide file tree
Showing 7 changed files with 26 additions and 40 deletions.
1 change: 0 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
sudo: required
language: python
python:
- "2.6"
- "2.7"
- "3.4"
- "3.5"
Expand Down
37 changes: 20 additions & 17 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Makefile for the `linux-utils' package.
#
# Author: Peter Odding <peter@peterodding.com>
# Last Change: May 18, 2018
# Last Change: February 9, 2020
# URL: https://linux-utils.readthedocs.io

PACKAGE_NAME = linux-utils
Expand Down Expand Up @@ -31,42 +31,45 @@ install:
@test -d "$(VIRTUAL_ENV)" || mkdir -p "$(VIRTUAL_ENV)"
@test -x "$(VIRTUAL_ENV)/bin/python" || virtualenv --quiet "$(VIRTUAL_ENV)"
@test -x "$(VIRTUAL_ENV)/bin/pip" || easy_install pip
@test -x "$(VIRTUAL_ENV)/bin/pip-accel" || pip install --quiet pip-accel
@pip-accel install --quiet --requirement=requirements.txt
@pip install --quiet --requirement=requirements.txt
@pip uninstall --yes $(PACKAGE_NAME) &>/dev/null || true
@pip install --quiet --no-deps --ignore-installed .

reset:
$(MAKE) clean
rm -Rf "$(VIRTUAL_ENV)"
$(MAKE) install
@$(MAKE) clean
@rm -Rf "$(VIRTUAL_ENV)"
@$(MAKE) install

check: install
@scripts/check-code-style.sh
@pip install --quiet --upgrade --requirement=requirements-checks.txt
@flake8

test: install
@pip-accel install --quiet --requirement=requirements-tests.txt
@pip install --quiet --requirement=requirements-tests.txt
@py.test --cov
@coverage html
@coverage report --fail-under=90 &>/dev/null

tox: install
@pip-accel install --quiet tox && tox
@pip install --quiet tox
@tox

readme: install
@pip-accel install --quiet cogapp && cog.py -r README.rst
@pip install --quiet cogapp
@cog.py -r README.rst

docs: readme
@pip-accel install --quiet sphinx
@pip install --quiet sphinx
@cd docs && sphinx-build -nb html -d build/doctrees . build/html

publish: install
git push origin && git push --tags origin
$(MAKE) clean
pip-accel install --quiet twine wheel
python setup.py sdist bdist_wheel
twine upload dist/*
$(MAKE) clean
@git push origin
@git push --tags origin
@$(MAKE) clean
@pip install --quiet twine wheel
@python setup.py sdist bdist_wheel
@twine upload dist/*
@$(MAKE) clean

clean:
@rm -Rf *.egg .cache .coverage .tox build dist docs/build htmlcov
Expand Down
4 changes: 2 additions & 2 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ following functionality is currently implemented:
- A basic Python API for cryptsetup_ and a Python implementation of
cryptdisks_start_ and cryptdisks_stop_ (with a command line interface).

The package is currently tested on cPython 2.6, 2.7, 3.4, 3.5, 3.6 and PyPy
(2.7) on Ubuntu Linux (using `Travis CI`_).
The package is currently tested on cPython 2.7, 3.4, 3.5, 3.6 and PyPy (2.7) on
Ubuntu Linux (using `Travis CI`_).

.. contents::
:local:
Expand Down
14 changes: 0 additions & 14 deletions scripts/check-code-style.sh

This file was deleted.

5 changes: 2 additions & 3 deletions scripts/install-on-travis.sh
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
#!/bin/bash -e

# Install the required Python packages.
pip install pip-accel
pip-accel install --requirement=requirements-travis.txt
pip install --requirement=requirements-travis.txt

# Install the project itself, making sure that potential character encoding
# and/or decoding errors in the setup script are caught as soon as possible.
LC_ALL=C pip-accel install .
LC_ALL=C pip install .

# Let apt-get, dpkg and related tools know that we want the following
# commands to be 100% automated (no interactive prompts).
Expand Down
3 changes: 1 addition & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# Setup script for the `linux-utils' package.
#
# Author: Peter Odding <peter@peterodding.com>
# Last Change: May 18, 2018
# Last Change: February 9, 2020
# URL: https://linux-utils.readthedocs.io

"""
Expand Down Expand Up @@ -81,7 +81,6 @@ def get_absolute_path(*args):
'Operating System :: POSIX :: Linux',
'Programming Language :: Python',
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.4',
Expand Down
2 changes: 1 addition & 1 deletion tox.ini
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[tox]
envlist = py26, py27, py34, py35, py36, pypy
envlist = py27, py34, py35, py36, pypy

[testenv]
deps = -rrequirements-tests.txt
Expand Down

0 comments on commit 6576bae

Please sign in to comment.