[Bps-public-commit] rt-extension-repeatticket branch, rt5, repushed

? sunnavy sunnavy at bestpractical.com
Fri Jul 17 18:10:14 EDT 2020


The branch rt5 was deleted and repushed:
       was ed3bd7dfdde7294d6717a3dea4ef54096f2ffd94
       now e820db37f4b5100da323a61ed3234c3b25832064

1:  de096f2 = 1:  de096f2 Migrate to elevator themes for RT 5
2:  902b838 = 2:  902b838 Update tests to make them pass on RT 5
3:  ab30f36 = 3:  ab30f36 Remove unnecessary "undef $m"
6:  c69582b ! 4:  fa9f028 Bump version to 2.0 for RT 5
    @@ -5,30 +5,17 @@
         This big version bump makes it more notable that it's not a back
         compatible version.
     
    -diff --git a/Changes b/Changes
    ---- a/Changes
    -+++ b/Changes
    -@@
    - Revision history for RT-Extension-RepeatTicket
    - 
    -+2.00 2020-07-09
    -+ - Migrate to RT 5
    -+
    - 1.11 2017-11-07
    - 
    -  - Correctly display concurrent ticket number of 0
    -
     diff --git a/META.yml b/META.yml
     --- a/META.yml
     +++ b/META.yml
     @@
    -   perl: 5.10.1
    +   perl: 5.8.3
      resources:
        license: http://opensource.org/licenses/gpl-license.php
     -version: '1.11'
     +version: '2.0'
    - x_module_install_rtx_version: '0.41'
    - x_requires_rt: 4.6.0
    + x_module_install_rtx_version: '0.39'
    + x_requires_rt: 4.0.6
     
     diff --git a/lib/RT/Extension/RepeatTicket.pm b/lib/RT/Extension/RepeatTicket.pm
     --- a/lib/RT/Extension/RepeatTicket.pm
5:  c51673b ! 5:  6e8b810 Note it only works with RT 5+
    @@ -1,6 +1,6 @@
     Author: sunnavy <sunnavy at bestpractical.com>
     
    -    Update note that it only works with RT 5+
    +    Note it only works with RT 5+
     
     diff --git a/META.yml b/META.yml
     --- a/META.yml
    @@ -13,10 +13,10 @@
     +  perl: 5.10.1
      resources:
        license: http://opensource.org/licenses/gpl-license.php
    - version: '1.11'
    - x_module_install_rtx_version: '0.41'
    + version: '2.0'
    + x_module_install_rtx_version: '0.39'
     -x_requires_rt: 4.0.6
    -+x_requires_rt: 4.6.0
    ++x_requires_rt: 5.0.0
     
     diff --git a/Makefile.PL b/Makefile.PL
     --- a/Makefile.PL
    @@ -26,7 +26,7 @@
      requires('DateTime::Event::ICal');
      
     -requires_rt('4.0.6');
    -+requires_rt('4.6.0'); # i.e. RT 5.
    ++requires_rt('5.0.0');
      
      my ($lp) = ($INC{'RT.pm'} =~ /^(.*)[\\\/]/);
      my $lib_path = join( ' ', "$RT::LocalPath/lib", $lp );
    @@ -38,8 +38,8 @@
          tickets are needed, and when your daily cron job runs the
          rt-repeat-ticket script.
      
    -+    Note that this version only works with RT 5 or later versions, check out
    -+    1.* if you are still using RT 4.
    ++RT VERSION
    ++    Works with RT 5.0. Check out 1.* versions if you are still using RT 4.
     +
      INSTALLATION
          perl Makefile.PL
    @@ -70,8 +70,9 @@
      tickets are needed, and when your daily cron job runs the rt-repeat-ticket
      script.
      
    -+Note that this version only works with RT 5 or later versions, check out 1.*
    -+if you are still using RT 4.
    ++=head1 RT VERSION
    ++
    ++Works with RT 5.0. Check out 1.* versions if you are still using RT 4.
     +
      =head1 INSTALLATION
      
-:  ------- > 6:  c5911c3 Default RT path to /opt/rt5
4:  779e395 ! 7:  993325c Update M:I
    @@ -17,10 +17,10 @@
     @@
      resources:
        license: http://opensource.org/licenses/gpl-license.php
    - version: '1.11'
    + version: '2.0'
     -x_module_install_rtx_version: '0.39'
    -+x_module_install_rtx_version: '0.41'
    - x_requires_rt: 4.0.6
    ++x_module_install_rtx_version: '0.42'
    + x_requires_rt: 5.0.0
     
     diff --git a/inc/Module/AutoInstall.pm b/inc/Module/AutoInstall.pm
     --- a/inc/Module/AutoInstall.pm
    @@ -143,11 +143,14 @@
     --- a/inc/Module/Install/RTx.pm
     +++ b/inc/Module/Install/RTx.pm
     @@
    - 
    + use warnings;
    + no warnings 'once';
    + 
    ++use Term::ANSIColor qw(:constants);
      use Module::Install::Base;
      use base 'Module::Install::Base';
     -our $VERSION = '0.39';
    -+our $VERSION = '0.41';
    ++our $VERSION = '0.42';
      
      use FindBin;
      use File::Glob     ();
    @@ -160,6 +163,80 @@
              last if eval {local @INC = @look; require RT; $RT::LocalLibPath};
      
              warn
    +@@
    +         $self->requires_rt('4.0.0');
    +     }
    + 
    ++    my $package = $name;
    ++    $package =~ s/-/::/g;
    ++    if ( $RT::CORED_PLUGINS{$package} ) {
    ++        my ($base_version) = $RT::VERSION =~ /(\d+\.\d+\.\d+)/;
    ++        die RED, <<"EOT";
    ++
    ++**** Error: Your installed version of RT ($RT::VERSION) already
    ++            contains this extension in core, so you don't need to
    ++            install it.
    ++
    ++            Check https://docs.bestpractical.com/rt/$base_version/RT_Config.html
    ++            to configure it.
    ++
    ++EOT
    ++    }
    ++
    +     # Installation locations
    +     my %path;
    +     my $plugin_path;
    +@@
    +     my @sorted = sort RT::Handle::cmp_version $version,$RT::VERSION;
    + 
    +     if ($sorted[-1] eq $version) {
    +-        die <<"EOT";
    ++        die RED, <<"EOT";
    + 
    + **** Error: This extension requires RT $version. Your installed version
    +             of RT ($RT::VERSION) is too old.
    +@@
    +         unshift @INC, $path;
    +     } else {
    +         my $name = $self->name;
    +-        warn <<"EOT";
    ++        my $msg = <<"EOT";
    + 
    + **** Warning: $name requires that the $plugin plugin be installed and
    +               enabled; it does not appear to be installed.
    +-
    + EOT
    ++        warn RED, $msg, RESET, "\n";
    +     }
    +     $self->requires(@_);
    + }
    +@@
    +     my $name = $self->name;
    +     $msg ||= <<EOT;
    + 
    +-**** Error: Your installed version of RT (%s) is too new; this extension
    +-            only works with versions older than %s.
    +-
    ++**** Warning: Your installed version of RT (%s) is too new; this extension
    ++              has not been tested on your version of RT and may not work as expected.
    + EOT
    +     $self->add_metadata("x_rt_too_new", $version) if $self->is_admin;
    + 
    +@@
    +     my @sorted = sort RT::Handle::cmp_version $version,$RT::VERSION;
    + 
    +     if ($sorted[0] eq $version) {
    +-        die sprintf($msg,$RT::VERSION,$version);
    ++        warn RED, sprintf($msg,$RT::VERSION), RESET, "\n";
    +     }
    + }
    + 
    +@@
    + 
    + __END__
    + 
    +-#line 468
    ++#line 484
     
     diff --git a/inc/Module/Install/RTx/Runtime.pm b/inc/Module/Install/RTx/Runtime.pm
     --- a/inc/Module/Install/RTx/Runtime.pm
7:  ff2bcd2 < -:  ------- Update M:I:RTx to 0.42
8:  ed3bd7d = 8:  e820db3 Add "." to @INC for perl 5.26+



More information about the Bps-public-commit mailing list