Skip to content

Commit

Permalink
Merge pull request #32 from fsfe/tarball-compliant
Browse files Browse the repository at this point in the history
Make the source tarball REUSE-compliant
  • Loading branch information
carmenbianca authored Jul 4, 2019
2 parents 6fb180d + ce00040 commit 9343d9a
Show file tree
Hide file tree
Showing 8 changed files with 40 additions and 9 deletions.
14 changes: 11 additions & 3 deletions .reuse/dep5
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,22 @@ Upstream-Name: reuse
Upstream-Contact: Carmen Bianca Bakker <[email protected]>
Source: https://github.com/fsfe/reuse-tool

Files: .bumpversion.cfg
Files: .bumpversion.cfg setup.cfg
Copyright: 2017-2019 Free Software Foundation Europe e.v.
License: GPL-3.0-or-later

Files: docs/*.rst
Copyright: 2017-2018 Free Software Foundation Europe e.V.
Files: docs/reuse*.rst
Copyright: 2017-2019 Free Software Foundation Europe e.V.
License: CC-BY-SA-4.0

Files: docs/modules.rst
Copyright: 2017-2019 Free Software Foundation Europe e.V.
License: CC-BY-SA-4.0

Files: tests/resources/*
Copyright: 2017-2019 Free Software Foundation Europe e.V.
License: GPL-3.0-or-later

Files: src/fsfe_reuse.egg-info/*
Copyright: 2017-2019 Free Software Foundation Europe e.V.
License: GPL-3.0-or-later
1 change: 1 addition & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ include CHANGELOG.rst
include Makefile
include tox.ini
include requirements.txt
include .reuse/dep5

recursive-include LICENSES *
recursive-include docs *
Expand Down
10 changes: 6 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,6 @@ clean-docs: ## remove docs build artifacts
-$(MAKE) -C docs clean
rm -f docs/reuse*.rst
rm -f docs/modules.rst
rm -f docs/history.md
rm -f docs/readme.md

.PHONY: lint
lint: ## check with pylint
Expand All @@ -59,8 +57,12 @@ black: ## format with black
black .

.PHONY: reuse
reuse: ## check with self
reuse: dist ## check with self
reuse lint
tar -xf dist/fsfe-reuse*.tar.gz -C dist/
# This prevents the linter from using the project root as root.
git init dist/fsfe-reuse*/
cd dist/fsfe-reuse*/; reuse lint

.PHONY: test
test: ## run tests quickly
Expand All @@ -82,7 +84,7 @@ tox: ## run all tests against multiple versions of Python
tox

.PHONY: dist
dist: clean _pre-docs ## builds source and wheel package
dist: clean-build clean-pyc clean-docs _pre-docs ## builds source and wheel package
python setup.py sdist
python setup.py bdist_wheel
ls -l dist
Expand Down
5 changes: 5 additions & 0 deletions docs/authors.rst
Original file line number Diff line number Diff line change
@@ -1 +1,6 @@
..
SPDX-Copyright: 2017-2018 Free Software Foundation Europe e.V.
SPDX-License-Identifier: CC-BY-SA-4.0

.. include:: ../AUTHORS.rst
5 changes: 5 additions & 0 deletions docs/history.rst
Original file line number Diff line number Diff line change
@@ -1 +1,6 @@
..
SPDX-Copyright: 2017-2018 Free Software Foundation Europe e.V.
SPDX-License-Identifier: CC-BY-SA-4.0

.. include:: ../CHANGELOG.rst
5 changes: 5 additions & 0 deletions docs/index.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
..
SPDX-Copyright: 2017-2018 Free Software Foundation Europe e.V.
SPDX-License-Identifier: CC-BY-SA-4.0

.. reuse documentation master file, created by
sphinx-quickstart on Wed Nov 1 14:41:46 2017.
You can adapt this file completely to your liking, but it should at least
Expand Down
5 changes: 5 additions & 0 deletions docs/readme.rst
Original file line number Diff line number Diff line change
@@ -1 +1,6 @@
..
SPDX-Copyright: 2017-2018 Free Software Foundation Europe e.V.
SPDX-License-Identifier: CC-BY-SA-4.0

.. include:: ../README.rst
4 changes: 2 additions & 2 deletions src/reuse/project.py
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ def all_files(self, directory: PathLike = None) -> Iterator[Path]:
_LOGGER.debug("ignoring %s", root / file_)
continue

_LOGGER.debug(_("yielding %s"), file_)
_LOGGER.debug(_("yielding %s"), root / file_)
yield root / file_

def spdx_info_of(self, path: PathLike) -> SpdxInfo:
Expand Down Expand Up @@ -249,7 +249,7 @@ def _licenses(self) -> Dict[str, Path]:
continue

path = self._relative_from_root(path)
_LOGGER.debug("searching %s for license tags", path)
_LOGGER.debug(_("determining identifier of %s"), path)

try:
identifier = self._identifier_of_license(path)
Expand Down

0 comments on commit 9343d9a

Please sign in to comment.