Glad that worked out for you.

On Mon, Dec 14, 2015 at 1:10 AM, Tim Johnston <john...@gmail.com> wrote:

> Thanks a lot for the help.
>
> I ended up building myself something in python to do the following:
> 1) Pull down the github issues from their API with curl (based on
> http://www.fullo.net/blog/2012/06/25/export-github-issues-as-csv-with-v3-api/
> ).
> 2) Make 'fossil ticket add' comments (like your Perl)
> -> after filtering out unwanted columns, cleaning up escaped characters
> and all sorts of other annoying details. (for what it's worth, the python
> library 'pandas' was really helpful here)
>
> It worked out nicely, and now I'm really close to ditching all my github
> stuff. Awesome!
>
>
>
> On Wed, Dec 2, 2015 at 9:50 PM, Ron W <ronw.m...@gmail.com> wrote:
>
>> On Wed, Dec 2, 2015 at 5:08 PM, Tim Johnston <john...@gmail.com> wrote:
>>
>>> I'm wondering about migrating my github 'issues' and turning them into
>>> fossil 'tickets'. Does anyone have experience with this? Any
>>> recommendations for approaching it?
>>>
>>
>> I can't help with parsing the github tickets, but I can make suggestions
>> for automating creation of Fossil tickets.
>>
>> See "fossil help ticket" for a description of the CLI to Fossil tickets.
>> Note that the ticket CLI doesn't perform any TH1/TCL processing you might
>> define in the ticket setup via the GUI. What you specify for the fields and
>> values will be what gets put in to the tickets created this way.
>>
>> Here's a partial Perl program to process 1 ticket:
>>
>> #!Perl
>> use strict;
>> use warnings;
>>
>> # List of ticket fields in Fossil (Default fields with addition of gh_id
>> to hold the github ticket id. Modify for your needs.)
>> my @FossilFields = qw/gh_id title status severity priority resolution
>> subsystem private_contact foundin username comment/;
>> # List of ticket fields in github project. Use same order as
>> corresponding Fossil ticket fields. Modify for your project.
>> my @GhFields = qw/id title status severity priority resolution subsystem
>> private_contact foundin username comment/;
>>
>> my %mapGh2F;
>> my $i = 0;
>> for my $n (@GhFields)
>> {
>>     $mapGh2F{$n} = @FossilFields[$i++];
>> }
>>
>> my %FieldsValues;
>>
>> # code to parse github ticket record goes here, inserting extracted
>> values into %FieldsValues
>>
>> # build Fossil command to add ticket
>> my @cmd = qw/fossil ticket add/;
>>
>> # might need to: push@cmd, "-q";
>> # if needed, make sure ticket parser quotes (escapes) certain character
>> as described in "fossil help ticket"
>>
>> for my $n (@FossilFields)
>> {
>>     push @cmd, $n;
>>     push @cmd, $FieldsValues{$n};
>> }
>>
>> # now, run it (the following is roughly equivalent, in C, to:
>> execvp(cmd[0], cmd);
>> system @cmd;
>>
>>
>> _______________________________________________
>> fossil-users mailing list
>> fossil-users@lists.fossil-scm.org
>> http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
>>
>>
>
> _______________________________________________
> fossil-users mailing list
> fossil-users@lists.fossil-scm.org
> http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
>
>
_______________________________________________
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users

Reply via email to