Merge pull request #782 from andrewalker/master

Suggest a better default for Perl package names
This commit is contained in:
Louis Pilfold 2016-09-13 17:32:18 +01:00 committed by GitHub
commit ca7b3e6e34

View File

@ -84,7 +84,9 @@ snippet fore
${1:expression} foreach @${2:array}; ${1:expression} foreach @${2:array};
# Package # Package
snippet package snippet package
package ${1:`substitute(vim_snippets#Filename('', 'Page Title'), '^.', '\u&', '')`}; package ${1:`expand('%:p:s?.*lib/??:r:gs?/?::?')`};
use strict;
use warnings;
${0} ${0}
@ -93,7 +95,9 @@ snippet package
__END__ __END__
# Package syntax perl >= 5.14 # Package syntax perl >= 5.14
snippet packagev514 snippet packagev514
package ${1:`substitute(vim_snippets#Filename('', 'Page Title'), '^.', '\u&', '')`} ${2:0.99}; package ${1:`expand('%:p:s?.*lib/??:r:gs?/?::?')`} ${2:0.99};
use v5.14;
use warnings;
${0} ${0}