Created
September 20, 2013 12:43
-
-
Save hanabokuro/6636905 to your computer and use it in GitHub Desktop.
snippet for perl. expand "package".
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- mode: snippet -*- | |
# name: package | |
# key: package | |
# -- | |
package ${1:`(if (string-match "/lib/\\(.*\\)\\.pm" buffer-file-name) (replace-regexp-in-string "/" "::" (match-string 1 buffer-file-name)) "")`}; | |
use strict; | |
use warnings FATAL => qw(all); | |
$0 | |
1; | |
__END__ | |
=encoding utf-8 | |
=head1 NAME | |
$1 - | |
=head1 DESCRIPTION | |
=head1 AUTHOR | |
`(user-full-name)` `(if (boundp \`user-mail-address) (format "- E<lt>%sE<gt>" user-mail-address) "")` | |
=cut |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment