[Pkg-javascript-commits] [typescript-types] 01/01: Initial packaging
Ximin Luo
infinity0 at debian.org
Mon Apr 24 20:46:47 UTC 2017
This is an automated email from the git hooks/post-receive script.
infinity0 pushed a commit to branch master
in repository typescript-types.
commit bfa46b89728908fc9a01ce49eb4ec965ceaf1d5f
Author: Ximin Luo <infinity0 at debian.org>
Date: Mon Apr 24 22:45:37 2017 +0200
Initial packaging
---
debian/README.Debian | 14 +++++++++++
debian/README.source | 29 +++++++++++++++++++++
debian/changelog | 5 ++++
debian/compat | 1 +
debian/control | 49 ++++++++++++++++++++++++++++++++++++
debian/copyright | 31 +++++++++++++++++++++++
debian/gbp.conf | 2 ++
debian/get-orig-source.sh | 46 +++++++++++++++++++++++++++++++++
debian/node-typescript-types.install | 1 +
debian/rules | 10 ++++++++
debian/source/format | 1 +
11 files changed, 189 insertions(+)
diff --git a/debian/README.Debian b/debian/README.Debian
new file mode 100644
index 0000000..c96d2e4
--- /dev/null
+++ b/debian/README.Debian
@@ -0,0 +1,14 @@
+Types in this package
+=====================
+
+Right now we only package a subset of what upstream has, because it would be
+crazy to package it all in one Debian package. However, feel free to extend
+this subset within reason.
+
+Sometimes the type definitions here are out-of-sync with the corresponding
+javascript library in Debian. This is an inherent flaw with the upstream
+package as well as the surrounding ecosystem; this cannot be fixed in Debian.
+However, most of the time it should still work, i.e. the typechecks should
+still succeed with the (likely newer) types in this package, and the overall
+behaviour should be unaffected. If this doesn't work out for you, please file a
+bug to the upstream package to fix the situation on their end.
diff --git a/debian/README.source b/debian/README.source
new file mode 100644
index 0000000..e223bf9
--- /dev/null
+++ b/debian/README.source
@@ -0,0 +1,29 @@
+General info
+============
+
+The upstream sources are at:
+
+https://github.com/DefinitelyTyped/DefinitelyTyped
+
+However this isn't directly published to NPM. Instead, they have some scripts
+to auto-generate package.json for each package etc:
+
+https://github.com/Microsoft/types-publisher
+
+The extra data generated is both small and human-readable, so trying to package
+this generator would really be a waste of effort for Debian. Therefore, the
+get-orig-source.sh shell script just downloads the NPM packages and extracts
+them directly.
+
+Updating checklist
+==================
+
+- Check that "small and human-readable" still holds for the imported packages.
+ If not, we will have to figure out a proper solution for Debian.
+
+ In particular, check that they don't e.g. start bundling pre-built javascript
+ into this package; `find . -type f -name '*.js'` should output nothing.
+
+- Update d/control with the new contents of packages.list.
+
+- Run `grep license */package.json` and update d/copyright as necessary.
diff --git a/debian/changelog b/debian/changelog
new file mode 100644
index 0000000..7db05da
--- /dev/null
+++ b/debian/changelog
@@ -0,0 +1,5 @@
+typescript-types (20170424-1) UNRELEASED; urgency=medium
+
+ * Initial release. (Closes: #861130)
+
+ -- Ximin Luo <infinity0 at debian.org> Mon, 24 Apr 2017 21:55:44 +0200
diff --git a/debian/compat b/debian/compat
new file mode 100644
index 0000000..f599e28
--- /dev/null
+++ b/debian/compat
@@ -0,0 +1 @@
+10
diff --git a/debian/control b/debian/control
new file mode 100644
index 0000000..8db5936
--- /dev/null
+++ b/debian/control
@@ -0,0 +1,49 @@
+Source: typescript-types
+Priority: extra
+Maintainer: Debian Javascript Maintainers <pkg-javascript-devel at lists.alioth.debian.org>
+Uploaders: Ximin Luo <infinity0 at debian.org>
+Build-Depends: debhelper (>= 10)
+Standards-Version: 3.9.8
+Section: libs
+Homepage: http://definitelytyped.org/
+Vcs-Git: https://anonscm.debian.org/git/pkg-javascript/typescript-types.git
+Vcs-Browser: https://anonscm.debian.org/cgit/pkg-javascript/typescript-types.git
+
+Package: node-typescript-types
+Architecture: all
+Depends: ${misc:Depends}
+Description: Supposedly "high quality" TypeScript type definitions
+ TypeScript type definitions supplied by the DefinitelyTyped project, for
+ JavaScript packages that don't supply their own type definitions.
+ .
+ This description would be longer, but upstream does not give one on their
+ website nor on their Github page. After some very painful experience using
+ NPM, one can eventually deduce that these definitions are needed for certain
+ typescript packages that build on top of javascript packages, where these
+ latter packages don't themselves define any typescript types.
+ .
+ This package contains a subset of the upstream type definitions because there
+ are a ridiculous amount (a few hundred megabytes) and the vast majority of
+ them are probably never going to be needed for Debian. Currently these are:
+ .
+ @types/backbone 1.3.33
+ @types/expect.js 0.3.29
+ @types/fs-extra 2.1.0
+ @types/handlebars 4.0.32
+ @types/highlight.js 9.1.9
+ @types/jquery 2.0.41
+ @types/lodash 4.14.63
+ @types/marked 0.0.28
+ @types/mathjax 0.0.31
+ @types/minimatch 2.0.29
+ @types/minimist 1.2.0
+ @types/mocha 2.2.41
+ @types/node 7.0.13
+ @types/requirejs 2.1.29
+ @types/semver 5.3.31
+ @types/shelljs 0.7.0
+ @types/sinon 2.1.3
+ @types/underscore 1.8.0
+ .
+ If you need more than these, please file a bug report asking for git access so
+ that you can update this package yourself.
diff --git a/debian/copyright b/debian/copyright
new file mode 100644
index 0000000..41b0daf
--- /dev/null
+++ b/debian/copyright
@@ -0,0 +1,31 @@
+Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
+Upstream-Name: DefinitelyTyped
+Source: https://github.com/DefinitelyTyped/DefinitelyTyped
+
+Files: *
+Copyright: 2012-2017 Boris Yankov <borisyankov at gmail.com>
+ 2012-2017 DefinitelyTyped contributors
+License: Expat
+
+Files: debian/*
+Copyright: 2017 Ximin Luo <infinity0 at debian.org>
+License: Expat
+
+License: Expat
+ Permission is hereby granted, free of charge, to any person obtaining a copy
+ of this software and associated documentation files (the "Software"), to deal
+ in the Software without restriction, including without limitation the rights
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ copies of the Software, and to permit persons to whom the Software is
+ furnished to do so, subject to the following conditions:
+ .
+ The above copyright notice and this permission notice shall be included in
+ all copies or substantial portions of the Software.
+ .
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+ THE SOFTWARE.
diff --git a/debian/gbp.conf b/debian/gbp.conf
new file mode 100644
index 0000000..cec628c
--- /dev/null
+++ b/debian/gbp.conf
@@ -0,0 +1,2 @@
+[DEFAULT]
+pristine-tar = True
diff --git a/debian/get-orig-source.sh b/debian/get-orig-source.sh
new file mode 100755
index 0000000..bca4769
--- /dev/null
+++ b/debian/get-orig-source.sh
@@ -0,0 +1,46 @@
+#!/bin/sh
+set -e
+
+PKG=typescript-types
+VER=$(date +'%Y%m%d')
+
+packages="backbone
+expect.js
+fs-extra
+handlebars
+highlight.js
+jquery
+lodash
+marked
+mathjax
+minimatch
+minimist
+mocha
+node
+requirejs
+semver
+shelljs
+sinon
+underscore"
+
+rm -rf dl "$PKG-$VER"
+mkdir -p dl
+cd dl
+
+for p in $packages; do
+ echo >&2 -n "downloading $p"
+ version=$(wget -q -O - "https://registry.npmjs.org/-/package/@types%2F${p}/dist-tags" | \
+ python3 -m json.tool | \
+ sed -ne 's/.*"latest": "\(.*\)".*/\1/gp')
+ echo " $version"
+ wget -qO- "https://registry.npmjs.org/@types/$p/-/$p-${version}.tgz" | tar -xzf-
+ printf "%-40s%s\n" "@types/$p" "$version" >> packages.list
+done
+
+cd ..
+
+mv dl "$PKG-$VER"
+tar --sort=name \
+ --owner=root --group=root \
+ -cJf "${PKG}_${VER}.orig.tar.xz" "$PKG-$VER"
+rm -rf "$PKG-$VER"
diff --git a/debian/node-typescript-types.install b/debian/node-typescript-types.install
new file mode 100644
index 0000000..1c69af7
--- /dev/null
+++ b/debian/node-typescript-types.install
@@ -0,0 +1 @@
+* /usr/lib/nodejs/@types
diff --git a/debian/rules b/debian/rules
new file mode 100755
index 0000000..e78ee2b
--- /dev/null
+++ b/debian/rules
@@ -0,0 +1,10 @@
+#!/usr/bin/make -f
+
+# Uncomment this to turn on verbose mode.
+#export DH_VERBOSE=1
+
+%:
+ dh $@
+
+override_dh_install:
+ dh_install -Xdebian -Xpackages.list -XLICENSE
diff --git a/debian/source/format b/debian/source/format
new file mode 100644
index 0000000..163aaf8
--- /dev/null
+++ b/debian/source/format
@@ -0,0 +1 @@
+3.0 (quilt)
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/typescript-types.git
More information about the Pkg-javascript-commits
mailing list