[Python-modules-commits] [flask-mongoengine] 02/02: Initial package version.
Adrian Vondendriesch
discostu-guest at moszumanska.debian.org
Fri Jun 9 16:27:54 UTC 2017
This is an automated email from the git hooks/post-receive script.
discostu-guest pushed a commit to branch master
in repository flask-mongoengine.
commit 72a4438befd61ddbfe8214de9a75132ac9b9ccaf
Author: Adrian Vondendriesch <adrian.vondendriesch at credativ.de>
Date: Wed May 31 16:02:55 2017 +0200
Initial package version.
---
debian/.git-dpm | 11 +++
debian/changelog | 5 ++
debian/compat | 1 +
debian/control | 53 +++++++++++++
debian/copyright | 108 +++++++++++++++++++++++++++
debian/rules | 6 ++
debian/source/format | 1 +
debian/tests/control | 3 +
debian/tests/simpleapp.sh | 28 +++++++
debian/tests/simpleapp/README.rst | 15 ++++
debian/tests/simpleapp/app.py | 52 +++++++++++++
debian/tests/simpleapp/static/style.css | 18 +++++
debian/tests/simpleapp/templates/index.html | 11 +++
debian/tests/simpleapp/templates/layout.html | 15 ++++
debian/watch | 4 +
15 files changed, 331 insertions(+)
diff --git a/debian/.git-dpm b/debian/.git-dpm
new file mode 100644
index 0000000..e417075
--- /dev/null
+++ b/debian/.git-dpm
@@ -0,0 +1,11 @@
+# see git-dpm(1) from git-dpm package
+4816e2276bf6023534a7172afd4908d90c6bc9ba
+4816e2276bf6023534a7172afd4908d90c6bc9ba
+4816e2276bf6023534a7172afd4908d90c6bc9ba
+4816e2276bf6023534a7172afd4908d90c6bc9ba
+flask-mongoengine_0.9.3.orig.tar.gz
+6ff53cc44b2505784136e36ebf3e10b2fbb1c4ab
+111690
+debianTag="debian/%e%v"
+patchedTag="patched/%e%v"
+upstreamTag="upstream/%e%u"
diff --git a/debian/changelog b/debian/changelog
new file mode 100644
index 0000000..9ee7dc5
--- /dev/null
+++ b/debian/changelog
@@ -0,0 +1,5 @@
+flask-mongoengine (0.9.3-1) unstable; urgency=low
+
+ * Initial package version (Closes: #817766).
+
+ -- Adrian Vondendriesch <adrian.vondendriesch at credativ.de> Wed, 31 May 2017 14:20:29 +0200
diff --git a/debian/compat b/debian/compat
new file mode 100644
index 0000000..ec63514
--- /dev/null
+++ b/debian/compat
@@ -0,0 +1 @@
+9
diff --git a/debian/control b/debian/control
new file mode 100644
index 0000000..85991f2
--- /dev/null
+++ b/debian/control
@@ -0,0 +1,53 @@
+Source: flask-mongoengine
+Maintainer: Debian Python Modules Team <python-modules-team at lists.alioth.debian.org>
+Uploaders: Adrian Vondendriesch <adrian.vondendriesch at credativ.de>
+Section: python
+Priority: optional
+Build-Depends: debhelper (>= 9),
+ dh-python,
+ python-all (>= 2.6.6-3),
+ python-coverage,
+ python-flask,
+ python-flaskext.wtf (>=0.14.2),
+ python-mongoengine,
+ python-nose,
+ python-rednose,
+ python-setuptools (>= 0.6b3),
+ python-six,
+ python-wtforms,
+ python3-all,
+ python3-coverage,
+ python3-flask,
+ python3-flaskext.wtf (>=0.14.2),
+ python3-mongoengine,
+ python3-nose,
+ python3-rednose,
+ python3-setuptools,
+ python3-six,
+ python3-wtforms
+Standards-Version: 3.9.8
+Homepage: https://github.com/mongoengine/flask-mongoengine
+VCS-Git: https://anonscm.debian.org/git/python-modules/packages/flask-mongoengine.git
+Vcs-Browser: https://anonscm.debian.org/cgit/python-modules/packages/flask-mongoengine.git
+
+Package: python-flask-mongoengine
+Architecture: all
+Depends: ${misc:Depends}, ${python:Depends}
+Description: Extension that provides integration with MongoEngine (Python 2)
+ Flask extension that provides integration with MongoEngine.
+ .
+ It handles connection management for your app. You can also use
+ WTForms as model forms for your models.
+ .
+ This is a Python 2 package.
+
+Package: python3-flask-mongoengine
+Architecture: all
+Depends: ${misc:Depends}, ${python3:Depends}
+Description: Extension that provides integration with MongoEngin (Python 3)
+ Flask extension that provides integration with MongoEngine.
+ .
+ It handles connection management for your app. You can also use
+ WTForms as model forms for your models.
+ .
+ This is a Python 3 package.
diff --git a/debian/copyright b/debian/copyright
new file mode 100644
index 0000000..9414f54
--- /dev/null
+++ b/debian/copyright
@@ -0,0 +1,108 @@
+Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
+Upstream-Name: flask-mongoengine
+Upstream-Contact: Stefan Wojcik <wojcikstefan at gmail.com>
+Source: https://github.com/MongoEngine/mongoengine
+
+Files: *
+Copyright: 2016 Adam Chainz <adam at adamj.eu>
+ 2016 Aliaksandr Askerka <aliaksandr.askerka at leverx.com>
+ 2011 Alistair Roche <roche.a at gmail.com>
+ 2015 Almog Cohen <almog1232 at gmail.com>
+ 2017 Aly Sivji <alysivji at gmail.com>
+ 2014 Andrew Elkins <andrewelkins at users.noreply.github.com>
+ 2012 Anthony Nemitz <anemitz at gmail.com>
+ 2015 Anton Antonov <anton.synd.antonov at gmail.com>
+ 2015 Axel Haustant <noirbizarre at gmail.com>
+ 2015 bdadson <brightdadson at gmail.com>
+ 2015 bioneddy <nedrud at email.arizona.edu>
+ 2016 Boullier Jocelyn <kazoomy at gmail.com>
+ 2015 bright <bright at bdadson-pc>
+ 2015-2016 Bright Dadson <brightdadson at gmail.com>
+ 2016 BrightPan <bright_pan at 163.com>
+ 2016 Bruno Belarmino <bb.belarmino at gmail.com>
+ 2015 Bruno Rocha <rochacbruno at gmail.com>
+ 2013 Christian Wygoda <info at wygoda.net>
+ 2014 Clay McClure <clay at daemons.net>
+ 2015 Cory Dolphin <wcdolphin at gmail.com>
+ 2016 Denny Huang <denny0223 at gmail.com>
+ 2013 Dragos Catarahia <dragos.catarahia at gmail.com>
+ 2017 Emmanuel Leblond <emmanuel.leblond at gmail.com>
+ 2015 Fengda Huang <phodal at users.noreply.github.com>
+ 2016 fieliapm <fieliapm at gmail.com>
+ 2015 Garito <garito at sistes.net>
+ 2011 Gregg Lind <gregg.lind at gmail.com>
+ 2015 icoz <icoz.vt at gmail.com>
+ 2014 Jack Stouffer <jack at jackstouffer.com>
+ 2014 Jamar Parris <jamar at jamarparris.com>
+ 2016-2017 jcass <john.cass77 at gmail.com>
+ 2016 Jeff Tharp <jeff at close.io>
+ 2016-2017 Jérôme Lafréchoux <jlafrechoux at nobatek.com>
+ 2016 Jérôme Lafréchoux <lafrech at users.noreply.github.com>
+ 2014 Joao Mesquita <jmesquita at indicium.com.ar>
+ 2011 Joe Shaw <joe at joeshaw.org>
+ 2012 Joe Shaw <joeshaw at litl.com>
+ 2011-2012 jorgebastida <jorge at streetlife.com>
+ 2011 Jorge Bastida <me at jorgebastida.com>
+ 2012 JTG <JTG at gala.net>
+ 2015 Len Buckens <buckensl at b-virtual.org>
+ 2015 Liam McLoughlin <hexxeh at hexxeh.net>
+ 2015-2016 losintikfos <brightdadson at gmail.com>
+ 2013 Lucas Nemeth <lucas.nemeth at gmail.com>
+ 2012 Lucas Vogelsang <l at lucasvo.com>
+ 2014 Marcel Tschopp <mt at corova.net>
+ 2012 Marcus Carlsson <mc at beepsend.se>
+ 2013 Massimo Santini <santini at di.unimi.it>
+ 2014 Mattias Granlund <mtsgrd at gmail.com>
+ 2012 Max Countryman <maxc at me.com>
+ 2013 mickey06 <khalil.elkouhen at gmail.com>
+ 2014 mxck <mmxckk at gmail.com>
+ 2014 Nauman Ahmad <naumanahmad at MacBook-Pro.local>
+ 2014-2015 Nauman Ahmad <nauman-ahmad at outlook.com>
+ 2015 Paul Brown <paul90brown at gmail.com>
+ 2015 Peter Kristensen <peter at ptx.dk>
+ 2015 Philip House <philiphouse2015 at u.northwestern.edu>
+ 2015 rma4ok <rma4ok at gmail.com>
+ 2012 Rod Cloutier <rodcloutier at gmail.com>
+ 2011-2014 Ross Lawley <ross.lawley at gmail.com>
+ 2012 Serge S. Koval <serge.koval+github at gmail.com>
+ 2016 Sibelius Seraphini <sibeliusseraphini at gmail.com>
+ 2013 Simon Eames <simon.richard.eames at gmail.com>
+ 2016 Slavek Kabrda <bkabrda at redhat.com>
+ 2012-2016 Stefan Wojcik <wojcikstefan at gmail.com>
+ 2016 Stefan Wójcik <wojcikstefan at gmail.com>
+ 2017 Stefan Wojcik <wojcikstefan at gmail.com>
+ 2017 Stefan Wójcik <wojcikstefan at gmail.com>
+ 2012 Thomas Steinacher <tom at eggdrop.ch>
+ 2015 Ty3uK <max.karelov at gmail.com>
+ 2014 wcdolphin <wcdolphin at gmail.com>
+ 2013 woo <iampurse at vip.qq.com>
+ 2012 yoyicue <yoyicue at gmail.com>
+ 2015 Zephor 武智辉 <zephor at qq.com>
+ 2015 Павел Литвиненко <gerasim13 at gmail.com>
+ 2016 庄天翼 <zty0826 at gmail.com>
+License: MIT
+
+Files: debian/*
+Copyright: Adrian Vondendriesch <adrian.vondendriesch at credativ.de>
+License: MIT
+
+License: MIT
+ 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/rules b/debian/rules
new file mode 100755
index 0000000..79c9085
--- /dev/null
+++ b/debian/rules
@@ -0,0 +1,6 @@
+#!/usr/bin/make -f
+
+export PYBUILD_NAME=flask-mongoengine
+%:
+ dh $@ --with python2,python3 --buildsystem=pybuild
+
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)
diff --git a/debian/tests/control b/debian/tests/control
new file mode 100644
index 0000000..955d987
--- /dev/null
+++ b/debian/tests/control
@@ -0,0 +1,3 @@
+Tests: simpleapp.sh
+Depends: @, mongodb, curl
+Restrictions: allow-stderr
diff --git a/debian/tests/simpleapp.sh b/debian/tests/simpleapp.sh
new file mode 100755
index 0000000..501159b
--- /dev/null
+++ b/debian/tests/simpleapp.sh
@@ -0,0 +1,28 @@
+#!/bin/bash
+
+set -e
+
+cleanup () {
+ set +e
+ echo "Clean up environment"
+ pkill -P $PYPID
+}
+trap cleanup 0 2 3 15
+
+PYPID=""
+
+# Python 2 tests
+for py in $(pyversions -i) $(py3versions -i); do
+ echo "run test with $($py --version)"
+ $py debian/tests/simpleapp/app.py&
+ PYPID=$!
+
+ sleep 3
+
+ echo "Try to get one row of the sample data"
+ curl -s http://localhost:4000/ | grep "Simple todo B"
+ test $? -eq 0 && echo "OK"
+ sleep 1
+ cleanup
+ sleep 1
+done
diff --git a/debian/tests/simpleapp/README.rst b/debian/tests/simpleapp/README.rst
new file mode 100644
index 0000000..fe69f57
--- /dev/null
+++ b/debian/tests/simpleapp/README.rst
@@ -0,0 +1,15 @@
+Sample app to test the toolbar
+==============================
+
+A simple one file app - to help get you started
+
+1. Install all the requirements from: flask-mongoengine/requirements.txt::
+
+ pip install -r requirements.txt
+
+2. From the root folder run the app eg::
+
+ python ./examples/simpleapp/app.py
+
+3. Point your browser to localhost:4000/
+
diff --git a/debian/tests/simpleapp/app.py b/debian/tests/simpleapp/app.py
new file mode 100644
index 0000000..4f952b4
--- /dev/null
+++ b/debian/tests/simpleapp/app.py
@@ -0,0 +1,52 @@
+# -*- coding: utf-8 -*-
+import os
+import sys
+import datetime
+import flask
+
+sys.path.insert(0, os.path.realpath(os.path.join(os.path.dirname(__file__), '../../')))
+
+from flask_mongoengine import MongoEngine
+#from flask_debugtoolbar import DebugToolbarExtension
+
+app = flask.Flask(__name__)
+app.config.from_object(__name__)
+app.config['MONGODB_SETTINGS'] = {'DB': 'testing', 'host': '192.168.122.61'}
+app.config['TESTING'] = True
+app.config['SECRET_KEY'] = 'flask+mongoengine=<3'
+app.debug = True
+app.config['DEBUG_TB_PANELS'] = (
+ 'flask_debugtoolbar.panels.versions.VersionDebugPanel',
+ 'flask_debugtoolbar.panels.timer.TimerDebugPanel',
+ 'flask_debugtoolbar.panels.headers.HeaderDebugPanel',
+ 'flask_debugtoolbar.panels.request_vars.RequestVarsDebugPanel',
+ 'flask_debugtoolbar.panels.template.TemplateDebugPanel',
+ 'flask_debugtoolbar.panels.logger.LoggingPanel',
+ 'flask_mongoengine.panels.MongoDebugPanel'
+)
+
+app.config['DEBUG_TB_INTERCEPT_REDIRECTS'] = False
+
+db = MongoEngine()
+db.init_app(app)
+
+#DebugToolbarExtension(app)
+
+class Todo(db.Document):
+ title = db.StringField(max_length=60)
+ text = db.StringField()
+ done = db.BooleanField(default=False)
+ pub_date = db.DateTimeField(default=datetime.datetime.now)
+
+ at app.route('/')
+def index():
+ # As a list to test debug toolbar
+ Todo.objects().delete() # Removes
+ Todo(title="Simple todo A ПЫЩЬ!", text="12345678910").save() # Insert
+ Todo(title="Simple todo B", text="12345678910").save() # Insert
+ Todo.objects(title__contains="B").update(set__text="Hello world") # Update
+ todos = Todo.objects.all()
+ return flask.render_template('index.html', todos=todos)
+
+if __name__ == "__main__":
+ app.run(host="0.0.0.0", port=4000)
diff --git a/debian/tests/simpleapp/static/style.css b/debian/tests/simpleapp/static/style.css
new file mode 100644
index 0000000..4f3b71d
--- /dev/null
+++ b/debian/tests/simpleapp/static/style.css
@@ -0,0 +1,18 @@
+body { font-family: sans-serif; background: #eee; }
+a, h1, h2 { color: #377BA8; }
+h1, h2 { font-family: 'Georgia', serif; margin: 0; }
+h1 { border-bottom: 2px solid #eee; }
+h2 { font-size: 1.2em; }
+
+.page { margin: 2em auto; width: 35em; border: 5px solid #ccc;
+ padding: 0.8em; background: white; }
+.entries { list-style: none; margin: 0; padding: 0; }
+.entries li { margin: 0.8em 1.2em; }
+.entries li h2 { margin-left: -1em; }
+.add-entry { font-size: 0.9em; border-bottom: 1px solid #ccc; }
+.add-entry dl { font-weight: bold; }
+.metanav { text-align: right; font-size: 0.8em; padding: 0.3em;
+ margin-bottom: 1em; background: #fafafa; }
+.flash { background: #CEE5F5; padding: 0.5em;
+ border: 1px solid #AACBE2; }
+.error { background: #F0D6D6; padding: 0.5em; }
diff --git a/debian/tests/simpleapp/templates/index.html b/debian/tests/simpleapp/templates/index.html
new file mode 100644
index 0000000..afc0632
--- /dev/null
+++ b/debian/tests/simpleapp/templates/index.html
@@ -0,0 +1,11 @@
+{% extends "layout.html" %}
+{% block body %}
+ {% for todo in todos %}
+ <div>
+ <h2>{{ todo.title }}</h2>
+ {{ todo.text|safe }}
+ </div>
+ {% else %}
+ <em>Unbelievable. No todos here so far <a href="/add">Add one</a></em>
+ {% endfor %}
+{% endblock %}
diff --git a/debian/tests/simpleapp/templates/layout.html b/debian/tests/simpleapp/templates/layout.html
new file mode 100644
index 0000000..20c3857
--- /dev/null
+++ b/debian/tests/simpleapp/templates/layout.html
@@ -0,0 +1,15 @@
+<!doctype html>
+<html>
+<head>
+<title>Flask MongoEngine</title>
+<link rel=stylesheet type=text/css href="{{ url_for('static', filename='style.css') }}">
+</head>
+<body>
+<div class=page>
+ <h1>Toolbar example</h1>
+ <div>
+ {% block body %}{% endblock %}
+ </div>
+</div>
+</body>
+</html>
\ No newline at end of file
diff --git a/debian/watch b/debian/watch
new file mode 100644
index 0000000..4faa02d
--- /dev/null
+++ b/debian/watch
@@ -0,0 +1,4 @@
+# please also check http://pypi.debian.net/flask-mongoengine/watch
+version=3
+opts=uversionmangle=s/(rc|a|b|c)/~$1/ \
+http://pypi.debian.net/flask-mongoengine/flask-mongoengine-(.+)\.(?:zip|tgz|tbz|txz|(?:tar\.(?:gz|bz2|xz)))
\ No newline at end of file
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/python-modules/packages/flask-mongoengine.git
More information about the Python-modules-commits
mailing list