Skip to content

Commit

Permalink
Update Term-Cap to CPAN version 1.17
Browse files Browse the repository at this point in the history
  [DELTA]

1.16: Sat  5 Apr 10:19:35 BST 2014
    - Make last resort actually work from drm00
      - Removed change log from Cap.pm

1.17-RC1: Wed  1 Jul 10:30:15 BST 2015
    - Fix regression caused by last resort change
    - Add support for capabilities of more than 2 characters

1.17: Mon 17 Aug 08:30:54 BST 2015
    - No changes version bounce
  • Loading branch information
bingos committed Aug 19, 2015
1 parent b13702a commit 23a7573
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 52 deletions.
2 changes: 1 addition & 1 deletion Porting/Maintainers.pl
Expand Up @@ -1055,7 +1055,7 @@ package Maintainers;
},

'Term::Cap' => {
'DISTRIBUTION' => 'JSTOWE/Term-Cap-1.15.tar.gz',
'DISTRIBUTION' => 'JSTOWE/Term-Cap-1.17.tar.gz',
'FILES' => q[cpan/Term-Cap],
},

Expand Down
65 changes: 14 additions & 51 deletions cpan/Term-Cap/Cap.pm
Expand Up @@ -19,51 +19,8 @@ use strict;
use vars qw($VERSION $VMS_TERMCAP);
use vars qw($termpat $state $first $entry);

$VERSION = '1.15';

# Version undef: Thu Dec 14 20:02:42 CST 1995 by sanders@bsdi.com
# Version 1.00: Thu Nov 30 23:34:29 EST 2000 by schwern@pobox.com
# [PATCH] $VERSION crusade, strict, tests, etc... all over lib/
# Version 1.01: Wed May 23 00:00:00 CST 2001 by d-lewart@uiuc.edu
# Avoid warnings in Tgetent and Tputs
# Version 1.02: Sat Nov 17 13:50:39 GMT 2001 by jns@gellyfish.com
# Altered layout of the POD
# Added Test::More to PREREQ_PM in Makefile.PL
# Fixed no argument Tgetent()
# Version 1.03: Wed Nov 28 10:09:38 GMT 2001
# VMS Support from Charles Lane <lane@DUPHY4.Physics.Drexel.Edu>
# Version 1.04: Thu Nov 29 16:22:03 GMT 2001
# Fixed warnings in test
# Version 1.05: Mon Dec 3 15:33:49 GMT 2001
# Don't try to fall back on infocmp if it's not there. From chromatic.
# Version 1.06: Thu Dec 6 18:43:22 GMT 2001
# Preload the default VMS termcap from Charles Lane
# Don't carp at setting OSPEED unless warnings are on.
# Version 1.07: Wed Jan 2 21:35:09 GMT 2002
# Sanity check on infocmp output from Norton Allen
# Repaired INSTALLDIRS thanks to Michael Schwern
# Version 1.08: Sat Sep 28 11:33:15 BST 2002
# Late loading of 'Carp' as per Michael Schwern
# Version 1.09: Tue Apr 20 12:06:51 BST 2004
# Merged in changes from and to Core
# Core (Fri Aug 30 14:15:55 CEST 2002):
# Cope with comments lines from 'infocmp' from Brendan O'Dea
# Allow for EBCDIC in Tgoto magic test.
# Version 1.10: Thu Oct 18 16:52:20 BST 2007
# Don't use try to use $ENV{HOME} if it doesn't exist
# Give Win32 'dumb' if TERM isn't set
# Provide fallback 'dumb' termcap entry as last resort
# Version 1.11: Thu Oct 25 09:33:07 BST 2007
# EBDIC fixes from Chun Bing Ge <gecb@cn.ibm.com>
# Version 1.12: Sat Dec 8 00:10:21 GMT 2007
# QNX test fix from Matt Kraai <kraai@ftbfs.org>
# Version 1.13: Thu Dec 22 22:21:09 GMT 2011
# POD error fix from Domin Hargreaves <dom@earth.li>
# Version 1.14 Sat Oct 26 19:16:38 BST 2013
# Applied all patches from RT and updated contact details
# Version 1.15 Sat Oct 26 21:32:24 BST 2013
# Metadata change from David Steinbrunner
# Forgot to update the email somewhere
$VERSION = '1.17';

# TODO:
# support Berkeley DB termcaps
# force $FH into callers package?
Expand Down Expand Up @@ -279,7 +236,7 @@ sub Tgetent

my @termcap_path = termcap_path();

unless ( @termcap_path || $entry )
if ( !@termcap_path && !$entry )
{

# last resort--fake up a termcap from terminfo
Expand Down Expand Up @@ -405,25 +362,25 @@ sub Tgetent
$entry =~ s/^[^:]*://;
foreach $field ( split( /:[\s:\\]*/, $entry ) )
{
if ( defined $field && $field =~ /^(\w\w)$/ )
if ( defined $field && $field =~ /^(\w{2,})$/ )
{
$self->{ '_' . $field } = 1 unless defined $self->{ '_' . $1 };

# print STDERR "DEBUG: flag $1\n";
}
elsif ( defined $field && $field =~ /^(\w\w)\@/ )
elsif ( defined $field && $field =~ /^(\w{2,})\@/ )
{
$self->{ '_' . $1 } = "";

# print STDERR "DEBUG: unset $1\n";
}
elsif ( defined $field && $field =~ /^(\w\w)#(.*)/ )
elsif ( defined $field && $field =~ /^(\w{2,})#(.*)/ )
{
$self->{ '_' . $1 } = $2 unless defined $self->{ '_' . $1 };

# print STDERR "DEBUG: numeric $1 = $2\n";
}
elsif ( defined $field && $field =~ /^(\w\w)=(.*)/ )
elsif ( defined $field && $field =~ /^(\w{2,})=(.*)/ )
{

# print STDERR "DEBUG: string $1 = $2\n";
Expand Down Expand Up @@ -770,7 +727,13 @@ sub Trequire
=head1 COPYRIGHT AND LICENSE
Please see the README file in distribution.
Copyright 1995-2015 (c) perl5 porters.
This software is free software and can be modified and distributed under
the same terms as Perl itself.
Please see the file README in the Perl source distribution for details of
the Perl license.
=head1 AUTHOR
Expand Down

0 comments on commit 23a7573

Please sign in to comment.