lutris/Makefile

104 lines
2 KiB
Makefile
Raw Normal View History

VERSION=`grep "__version__" lutris/__init__.py | cut -d" " -f 3 | sed 's|"\(.*\)"|\1|'`
GITBRANCH ?= master
PIPENV:=pipenv
PYTHON:=$(shell which python3)
PIP:=$(PYTHON) -m pip
PIPENV_LOCK_ARGS:= --deploy --ignore-pipfile
2014-02-08 18:21:00 +00:00
all:
export GITBRANCH=master
debuild
debclean
2013-06-26 10:11:21 +00:00
build:
2018-07-29 22:01:51 +00:00
gbp buildpackage --git-debian-branch=${GITBRANCH}
2013-06-26 12:17:43 +00:00
clean:
debclean
2013-06-29 16:49:29 +00:00
build-source: clean
gbp buildpackage -S --git-debian-branch=${GITBRANCH}
mkdir build
mv ../lutris_${VERSION}* build
release: build-source upload upload-ppa
test:
rm tests/fixtures/pga.db -f
2020-04-24 23:29:24 +00:00
nosetests3
flake8 lutris
2013-06-29 16:49:29 +00:00
cover:
rm tests/fixtures/pga.db -f
rm tests/coverage/ -rf
2020-04-24 23:29:24 +00:00
nosetests3 --with-coverage --cover-package=lutris --cover-html --cover-html-dir=tests/coverage
2017-01-14 19:45:59 +00:00
pgp-renew:
osc signkey --extend home:strycore
osc rebuildpac home:strycore --all
2017-03-24 22:35:51 +00:00
changelog-add:
dch -i
changelog-edit:
dch -e
upload:
scp build/lutris_${VERSION}.tar.xz lutris.net:/srv/releases/
2019-04-04 10:22:52 +00:00
upload-ppa:
dput ppa:lutris-team/lutris build/lutris_${VERSION}*_source.changes
2019-04-04 10:42:30 +00:00
upload-staging:
dput --force ppa:lutris-team/lutris-staging build/lutris_${VERSION}*_source.changes
snap:
snapcraft clean lutris -s pull
snapcraft
dev:
2020-05-08 17:33:04 +00:00
$(PIP) install --user --upgrade pipenv
$(PIPENV) install --dev $(PIPENV_LOCK_ARGS) --python $(PYTHON)
requirements:
# Generate new requirements.txt and requirements-dev.txt based on Pipfile.lock
# These files are needed by Travis CI
$(PIPENV) run pipenv_to_requirements -f
# ============
# Style checks
# ============
style: isort autopep8 ## Format code
isort:
$(PIPENV) run isort -y -rc lutris
autopep8:
$(PIPENV) run autopep8 --in-place --recursive --ignore E402 setup.py lutris
# ===============
# Static analysis
# ===============
check: isort-check flake8 pylint
isort-check:
$(PIPENV) run isort -c -rc lutris
flake8:
$(PIPENV) run flake8 lutris
pylint:
$(PIPENV) run pylint --rcfile=.pylintrc --output-format=colorized lutris
# =============
# Abbreviations
# =============
sc: style check
2020-04-26 16:37:06 +00:00
req: requirements
styles: style
checks: check