OK, np! :ok:


On Thu, Aug 8, 2013 at 3:33 PM, damianimc <notifications@github.com> wrote:

> In cit.py:
>
> > +
> > +    rename_jobs = {}
> > +    delete_jobs = []
> > +    if reindex:
> > +        remote_jobs = GetRemoteJobInfos(search_pattern, global_config, jenkins=jenkins)
> > +        remote_basenames = dict((ji.BaseName(), ji) for ji in remote_jobs)
> > +
> > +        for job_info in local_jobs:
> > +            base_name = job_info.BaseName()
> > +            remote_job = remote_basenames.pop(base_name, None)
> > +            if remote_job is not None and remote_job.name != job_info.name:
> > +                rename_jobs[job_info.name] = remote_job.name
> > +
> > +        delete_jobs = [ji.name for ji in remote_basenames.itervalues()]
> > +
> > +    for job_info in local_jobs:
>
> Sorting is not a good approach, specially if I use the base name which has
> no index. I already try that.
> I'm always using the same order given by jenkins when listing the jobs.
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/nicoddemus/cit/pull/29/files#r5665915>
> .
>