diff options
-rw-r--r-- | Makefile | 8 | ||||
-rw-r--r-- | README | 4 | ||||
-rw-r--r-- | libbe/command/web.py | 43 | ||||
-rw-r--r-- | libbe/interfaces/web/.hgignore (renamed from interfaces/web/.hgignore) | 0 | ||||
-rw-r--r-- | libbe/interfaces/web/.hgtags (renamed from interfaces/web/.hgtags) | 0 | ||||
-rw-r--r-- | libbe/interfaces/web/LICENSE (renamed from interfaces/web/LICENSE) | 0 | ||||
-rw-r--r-- | libbe/interfaces/web/README (renamed from interfaces/web/README) | 0 | ||||
-rw-r--r-- | libbe/interfaces/web/__init__.py (renamed from interfaces/web/__init__.py) | 0 | ||||
-rwxr-xr-x | libbe/interfaces/web/cfbe.py (renamed from interfaces/web/cfbe.py) | 0 | ||||
-rw-r--r-- | libbe/interfaces/web/static/scripts/jquery.corners.min.js (renamed from interfaces/web/static/scripts/jquery.corners.min.js) | 0 | ||||
-rw-r--r-- | libbe/interfaces/web/static/style/aal.css (renamed from interfaces/web/static/style/aal.css) | 0 | ||||
-rw-r--r-- | libbe/interfaces/web/static/style/cfbe.css (renamed from interfaces/web/static/style/cfbe.css) | 0 | ||||
-rw-r--r-- | libbe/interfaces/web/templates/base.html (renamed from interfaces/web/templates/base.html) | 0 | ||||
-rw-r--r-- | libbe/interfaces/web/templates/bug.html (renamed from interfaces/web/templates/bug.html) | 0 | ||||
-rw-r--r-- | libbe/interfaces/web/templates/empty-list.html (renamed from interfaces/web/templates/empty-list.html) | 0 | ||||
-rw-r--r-- | libbe/interfaces/web/templates/list.html (renamed from interfaces/web/templates/list.html) | 0 | ||||
-rw-r--r-- | libbe/interfaces/web/web.py (renamed from interfaces/web/web.py) | 9 | ||||
-rw-r--r-- | libbe/ui/command_line.py | 3 |
18 files changed, 58 insertions, 9 deletions
@@ -35,7 +35,7 @@ RST2HTML = /usr/bin/rst2html #PATH = /usr/bin:/bin # must include sphinx-build for 'sphinx' target. #INSTALL_OPTIONS = "--prefix=/usr/local" -INSTALL_OPTIONS = "--user" +#INSTALL_OPTIONS = "--user" # Select the documentation you wish to build DOC = sphinx man @@ -59,17 +59,17 @@ all: build .PHONY: build build: $(LIBBE_VERSION) - python setup.py build + python2 setup.py build .PHONY: doc doc: $(DOC) .PHONY: install install: build doc - python setup.py install ${INSTALL_OPTIONS} + python2 setup.py install ${INSTALL_OPTIONS} test: build - python test.py + python2 test.py .PHONY: clean clean: @@ -16,7 +16,7 @@ Getting BE BE is available as a Git repository:: - $ git clone https://gitlab.com/bugseverywhere/bugseverywhere.git be + $ git clone https://github.com/aaiyer/bugseverywhere.git be See the homepage_ for details. If you do branch the Git repo, you'll need to run:: @@ -31,7 +31,7 @@ to install BE. By default BE will install into your home directory, but you can tweak the ``INSTALL_OPTIONS`` variable in ``Makefile`` to install to another location. -.. _homepage: http://bugseverywhere.org/ +.. _homepage: https://github.com/aaiyer/bugseverywhere Getting started diff --git a/libbe/command/web.py b/libbe/command/web.py new file mode 100644 index 0000000..9ebd0c9 --- /dev/null +++ b/libbe/command/web.py @@ -0,0 +1,43 @@ +# Copyright (C) 2005-2012 Aaron Bentley <abentley@panoramicfeedback.com> +# Andrew Cooper <andrew.cooper@hkcreations.org> +# Chris Ball <cjb@laptop.org> +# Gianluca Montecchi <gian@grys.it> +# Niall Douglas (s_sourceforge@nedprod.com) <spam@spamtrap.com> +# W. Trevor King <wking@tremily.us> +# +# This file is part of Bugs Everywhere. +# +# Bugs Everywhere is free software: you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by the Free +# Software Foundation, either version 2 of the License, or (at your option) any +# later version. +# +# Bugs Everywhere is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for +# more details. +# +# You should have received a copy of the GNU General Public License along with +# Bugs Everywhere. If not, see <http://www.gnu.org/licenses/>. + +import libbe +import libbe.command +import libbe.command.util + +import sys, os + +class Web (libbe.command.Command): + "Run the web interface" + name = 'web' + + def __init__(self, *args, **kwargs): + libbe.command.Command.__init__(self, *args, **kwargs) + + def _run(self, **params): + storage = self._get_storage() + repo = storage.repo + os.execl(sys.executable, sys.executable, os.path.abspath(os.path.join(os.path.dirname(__file__), "..", "interfaces", "web", "cfbe.py")), repo) + return 0 + + def _long_help(self): + return "Launch the web interface" diff --git a/interfaces/web/.hgignore b/libbe/interfaces/web/.hgignore index a0e81b7..a0e81b7 100644 --- a/interfaces/web/.hgignore +++ b/libbe/interfaces/web/.hgignore diff --git a/interfaces/web/.hgtags b/libbe/interfaces/web/.hgtags index eeea432..eeea432 100644 --- a/interfaces/web/.hgtags +++ b/libbe/interfaces/web/.hgtags diff --git a/interfaces/web/LICENSE b/libbe/interfaces/web/LICENSE index 44f0935..44f0935 100644 --- a/interfaces/web/LICENSE +++ b/libbe/interfaces/web/LICENSE diff --git a/interfaces/web/README b/libbe/interfaces/web/README index 6bd04e5..6bd04e5 100644 --- a/interfaces/web/README +++ b/libbe/interfaces/web/README diff --git a/interfaces/web/__init__.py b/libbe/interfaces/web/__init__.py index e69de29..e69de29 100644 --- a/interfaces/web/__init__.py +++ b/libbe/interfaces/web/__init__.py diff --git a/interfaces/web/cfbe.py b/libbe/interfaces/web/cfbe.py index 68c484d..68c484d 100755 --- a/interfaces/web/cfbe.py +++ b/libbe/interfaces/web/cfbe.py diff --git a/interfaces/web/static/scripts/jquery.corners.min.js b/libbe/interfaces/web/static/scripts/jquery.corners.min.js index 0b2f979..0b2f979 100644 --- a/interfaces/web/static/scripts/jquery.corners.min.js +++ b/libbe/interfaces/web/static/scripts/jquery.corners.min.js diff --git a/interfaces/web/static/style/aal.css b/libbe/interfaces/web/static/style/aal.css index 9bad98f..9bad98f 100644 --- a/interfaces/web/static/style/aal.css +++ b/libbe/interfaces/web/static/style/aal.css diff --git a/interfaces/web/static/style/cfbe.css b/libbe/interfaces/web/static/style/cfbe.css index 2d7b90b..2d7b90b 100644 --- a/interfaces/web/static/style/cfbe.css +++ b/libbe/interfaces/web/static/style/cfbe.css diff --git a/interfaces/web/templates/base.html b/libbe/interfaces/web/templates/base.html index 5287470..5287470 100644 --- a/interfaces/web/templates/base.html +++ b/libbe/interfaces/web/templates/base.html diff --git a/interfaces/web/templates/bug.html b/libbe/interfaces/web/templates/bug.html index b6986a9..b6986a9 100644 --- a/interfaces/web/templates/bug.html +++ b/libbe/interfaces/web/templates/bug.html diff --git a/interfaces/web/templates/empty-list.html b/libbe/interfaces/web/templates/empty-list.html index 4c01cb2..4c01cb2 100644 --- a/interfaces/web/templates/empty-list.html +++ b/libbe/interfaces/web/templates/empty-list.html diff --git a/interfaces/web/templates/list.html b/libbe/interfaces/web/templates/list.html index 65e6fe2..65e6fe2 100644 --- a/interfaces/web/templates/list.html +++ b/libbe/interfaces/web/templates/list.html diff --git a/interfaces/web/web.py b/libbe/interfaces/web/web.py index 2907932..513483f 100644 --- a/interfaces/web/web.py +++ b/libbe/interfaces/web/web.py @@ -36,6 +36,10 @@ class WebInterface: self.env = Environment(loader=FileSystemLoader(template_root)) self.env.filters['datetimeformat'] = datetimeformat + @property + def bds(self): + return {self.bd.uuid: self.bd} + def get_common_information(self): """Returns a dict of common information that most pages will need.""" possible_assignees = list(set( @@ -200,9 +204,10 @@ class WebInterface: if current_target: remove_target(self.bd, bug) if target != "None": - add_target(self.bd, bug, target) + add_target(self.bds, self.bd, bug, target) else: - add_target(self.bd, bug, target) + if target != "None": + add_target(self.bds, self.bd, bug, target) bug.save() diff --git a/libbe/ui/command_line.py b/libbe/ui/command_line.py index 5d4d80a..a7fcc1e 100644 --- a/libbe/ui/command_line.py +++ b/libbe/ui/command_line.py @@ -379,7 +379,8 @@ def main(): ui.setup_command(command) if command.name in [ - 'new', 'comment', 'commit', 'html', 'import-xml', 'serve-commands']: + 'new', 'comment', 'commit', 'html', 'import-xml', 'serve-storage', + 'serve-commands', 'web']: paginate = 'never' else: paginate = 'auto' |