Merge pull request #6 from mike42/feature/packaging

Add Debian packaging
This commit is contained in:
Michael Billington 2017-06-06 06:21:58 +10:00 committed by GitHub
commit f57af24d0c
12 changed files with 97 additions and 2 deletions

View File

@ -7,8 +7,12 @@ addons:
packages:
- pandoc
- libxml2-utils
- devscripts
- build-essential
- lintian
- debhelper
script:
- bash -n mdcheckr
- (cd tests && ./test.sh)
- make test
- ./mdcheckr README.md
- make unsigned-package

27
CONTRIBUTING.md Normal file
View File

@ -0,0 +1,27 @@
# Contributors guide
## Packaging
## Source release
A source tarball can be created from the `Makefile`:
```bash
git checkout v1.0
make source-release
```
This is suitable as a "pristine" source for downstream packagers.
## Debian unsigned package
An unsigned Debian package can also be created from the repository in a few steps.
Check out the version you want:
```bash
git checkout v1.0
make unsigned-package
```
You will then have source and binary packages in the current directory.

31
Makefile Normal file
View File

@ -0,0 +1,31 @@
VERSION=1.0
.PHONY: default test offline-test source-tarball unsigned-package
default: test
test:
bash -n mdcheckr
(cd tests && ./test.sh)
source-tarball: mdcheckr_$(VERSION).orig.tar.gz
mdcheckr_$(VERSION).orig.tar.gz:
tar --transform "s,^,mdcheckr-$(VERSION)/," -cvzf \
mdcheckr_$(VERSION).orig.tar.gz \
LICENSE.md \
README.md \
mdcheckr \
mdcheckr.1 \
tests
unsigned-package: mdcheckr_$(VERSION)-1_all.deb
mdcheckr_$(VERSION)-1_all.deb: mdcheckr_$(VERSION).orig.tar.gz
tar -xvzf mdcheckr_$(VERSION).orig.tar.gz
cp -Rf debian/ mdcheckr-$(VERSION)/
(cd mdcheckr-$(VERSION)/ && debuild -us -uc)
rm -Rf mdcheckr-$(VERSION)/
clean:
rm -Rf mdcheckr-$(VERSION)* mdcheckr_$(VERSION)*

5
debian/changelog vendored Normal file
View File

@ -0,0 +1,5 @@
mdcheckr (1.0-1) UNRELEASED; urgency=low
* Initial release.
-- Michael Billington <michael.billington@gmail.com> Sun, 04 Jun 2017 17:33:37 +1000

1
debian/compat vendored Normal file
View File

@ -0,0 +1 @@
9

12
debian/control vendored Normal file
View File

@ -0,0 +1,12 @@
Source: mdcheckr
Maintainer: Michael Billington <michael.billington@gmail.com>
Section: misc
Priority: optional
Standards-Version: 3.9.2
Build-Depends: debhelper (>= 9)
Package: mdcheckr
Architecture: all
Depends: ${shlibs:Depends}, ${misc:Depends}, pandoc, curl, libxml2-utils, which
Description:
check markdown files for broken links and other errors

7
debian/copyright vendored Normal file
View File

@ -0,0 +1,7 @@
Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
Source: https://github.com/mike42/mdcheckr
Files: *
Copyright: 2017 Michael Billington
License: MIT

1
debian/debhelper-build-stamp vendored Normal file
View File

@ -0,0 +1 @@
mdcheckr

1
debian/install vendored Normal file
View File

@ -0,0 +1 @@
mdcheckr usr/bin

1
debian/manpages vendored Normal file
View File

@ -0,0 +1 @@
mdcheckr.1

4
debian/rules vendored Executable file
View File

@ -0,0 +1,4 @@
#!/usr/bin/make -f
%:
dh $@

1
debian/source/format vendored Normal file
View File

@ -0,0 +1 @@
3.0 (quilt)