Merge pull request #5007 from nbp/bugwarrior

Add Bugwarrior and its dependencies.
This commit is contained in:
Domen Kožar
2014-12-01 22:20:17 +01:00
3 changed files with 190 additions and 3 deletions

View File

@@ -0,0 +1,30 @@
From e7ed770363e8769727a915b2390c0ce1ab2ce964 Mon Sep 17 00:00:00 2001
From: Michal Hlavinka <mhlavink@redhat.com>
Date: Wed, 18 Jun 2014 20:07:24 -0400
Subject: tests: Fix cookie comparison on rawhide
Cookie comments changed, so just strip them out
(crobinso: Add commit message, make change more readable)
diff --git a/tests/misc.py b/tests/misc.py
index 4b4f99d..12da806 100644
--- a/tests/misc.py
+++ b/tests/misc.py
@@ -83,7 +83,12 @@ class MiscAPI(unittest.TestCase):
# Mozilla should be converted inplace to LWP
bugzilla.Bugzilla3(url=None, cookiefile=cookiesnew)
- self.assertEquals(open(cookiesmoz).read(), open(cookiesnew).read())
+
+ def strip_comments(content):
+ return [l for l in content.split("\n") if not l.startswith("#")]
+ self.assertEquals(
+ strip_comments(open(cookiesmoz).read()),
+ strip_comments(open(cookiesnew).read()))
# Make sure bad cookies raise an error
try:
--
cgit v0.10.2

View File

@@ -0,0 +1,48 @@
commit 4de021d049a9b194da93d7e96ff12cc1cbabac83
Author: Nicolas B. Pierron <nixos@nbp.name>
Date: Sun Nov 16 15:19:38 2014 +0100
Use a template for taskwarrior install path.
diff --git a/taskw/warrior.py b/taskw/warrior.py
index 21dde88..e0509f2 100644
--- a/taskw/warrior.py
+++ b/taskw/warrior.py
@@ -451,17 +451,17 @@ class TaskWarriorShellout(TaskWarriorBase):
def _execute(self, *args):
""" Execute a given taskwarrior command with arguments
Returns a 2-tuple of stdout and stderr (respectively).
"""
command = (
[
- 'task',
+ '@@taskwarrior@@/bin/task',
'rc:%s' % self.config_filename,
]
+ self.get_configuration_override_args()
+ [six.text_type(arg) for arg in args]
)
# subprocess is expecting bytestrings only, so nuke unicode if present
for i in range(len(command)):
@@ -525,17 +525,17 @@ class TaskWarriorShellout(TaskWarriorBase):
except OSError:
# OSError is raised if subprocess.Popen fails to find
# the executable.
return False
@classmethod
def get_version(cls):
taskwarrior_version = subprocess.Popen(
- ['task', '--version'],
+ ['@@taskwarrior@@/bin/task', '--version'],
stdout=subprocess.PIPE
).communicate()[0]
return LooseVersion(taskwarrior_version.decode())
def sync(self, init=False):
if self.get_version() < LooseVersion('2.3'):
raise UnsupportedVersionException(
"'sync' requires version 2.3 of taskwarrior or later."