Changeset f38b66d in lab.git for Dev/github


Ignore:
Timestamp:
Aug 21, 2013 11:02:55 AM (11 years ago)
Author:
Ken-ichi Mito <mitty@…>
Branches:
master
Children:
9353238
Parents:
c5b427c
Message:

check repository response parameters

File:
1 edited

Legend:

Unmodified
Added
Removed
  • Dev/github/GitHubBackup.pm

    rc5b427c rf38b66d  
    165165sub full_name { 
    166166    return (shift)->{repos}{full_name}; 
     167} 
     168 
     169sub has_downloads { 
     170    return (shift)->{repos}{has_downloads}; 
     171} 
     172 
     173sub forks_count { 
     174    return (shift)->{repos}{forks_count}; 
     175} 
     176 
     177sub has_wiki { 
     178    return (shift)->{repos}{has_wiki}; 
     179} 
     180 
     181sub has_issues { 
     182    return (shift)->{repos}{has_issues}; 
    167183} 
    168184 
     
    295311    my $self = shift; 
    296312     
    297     $self->clone_git; 
    298     $self->set_forks; 
    299     $self->clone_wiki; 
    300     $self->save_issues; 
     313    $self->clone_git   if ($self->has_downloads eq 'true'); 
     314    $self->set_forks   if ($self->forks_count > 0); 
     315    $self->clone_wiki  if ($self->has_wiki eq 'true'); 
     316    $self->save_issues if ($self->has_issues eq 'true'); 
    301317     
    302318    return $self; 
Note: See TracChangeset for help on using the changeset viewer.