コード例 #1
0
ファイル: dao.py プロジェクト: deximer/jira-shell
 def pull_projects(self):
     if not self.user or not self.password:
         self.password = getpass.getpass('Password: '******'User: '******'server': 'https://jira.zipcar.com'}
             , basic_auth=(self.user, self.password))
         self.agile = jira.client.GreenHopper(
               {'server': 'https://jira.zipcar.com'}
             , basic_auth=(self.user, self.password))
     for prj in self.agile.boards():
         pid = getattr(prj, 'id')
         if self.cache.data.has_key(str(pid)):
             transaction.begin()
             self.cache.data[str(pid)].query = prj.filter.query
             transaction.commit()
             continue
         transaction.begin()
         project = Project(str(pid), prj.name)
         project.query = prj.filter.query
         if prj.sprintSupportEnabled:
             project.process = 'Scrum'
         else:
             project.process = 'Kanban'
         self.cache.data[str(pid)] = project
         transaction.commit()
         transaction.begin()
         docid = self.cache.document_map.add(['jira', str(pid)])
         self.cache.catalog.index_doc(docid, project)
         transaction.commit()
コード例 #2
0
ファイル: Plugin.py プロジェクト: deximer/jira-shell
    from ...dao import Jira
except:
    from dao import Jira
from persistent.list import PersistentList
from ..base import BaseCommand
try:
    from ...model import Release, Project, Story, History
except:
    from model import Release, Project, Story, History

simulations = {}

if not 'SIMS' in Jira.cache.data:
    transaction.begin()
    project = Project('SIMS', 'simulations')
    project.process = 'Simulations'
    project.query = None
    Jira.cache.data['SIMS'] = project
    transaction.commit()

class Command(BaseCommand):
    help = 'Simulate a release'
    usage = '''    simulate
simulate -a I -d F -s I -p I -b I -c I -t I'''
    options_help = '''    -a : Average cycle time of simulated release
    -d : Standard deviation of cycle time of simulated release
    -e : Average and standard deviation of estimates
    -b : Average developer bandwidth to simulate, in cycle time
    -p : Number of developer pairs to simulate
    -v : Standard deviation of developer bandwidth to simulate, in cycle time
    -s : Number of stories to simulate