vim-plugins icon indicating copy to clipboard operation
vim-plugins copied to clipboard

Perl-Support: Extending the Perl/POD templates and menu

Open gllore opened this issue 8 years ago • 2 comments

Dear Wolfgang,

How about including some of the more general items in POD? For example, I prefer to include the following at the start of my programs:

=head2 SYNOPSIS

PACKAGE NAME:

AUTHOR: Juan Lorenzo

DATE:

DESCRIPTION: Version:

=head2 USE

=head3 NOTES

=head4 Examples

=head2 SYNOPSIS

=head3 SEISMIC UNIX NOTES

=head2 CHANGES and their DATES

=cut

THANKYOU!

gllore avatar Aug 25 '17 15:08 gllore

Sorry for the long response time.

The new version of Perl-Support I just uploaded now includes "File Skeletons". You can specify the list of templates to be included if you create a new file.

Use the map \ntw or the menu entry Perl -> Snippets -> template setup wizard inside a Perl buffer and create a "template customization file". It will create an example file for you, that even includes your request as an example. Uncomment the property and the template to use it:

§ templates automatically included into new files
SetProperty ( 'Perl::FileSkeleton::Module', 'Comments.file description pm; ;Skeleton.module-pod; ;Skeleton.module-use' )

== Skeleton.module-pod == nomenu, below ==
=pod

=head2 SYNOPSIS

PACKAGE NAME: |BASENAME|

AUTHOR: |AUTHOR|

DATE: |DATE_PRETTY1|

DESCRIPTION:
Version:

=head2 USE

=cut
== ENDTEMPLATE ==


Alternatively, use can modify the customization file to create a new menu entry for the Perl -> POD sub-menu.

== POD.module documentation == below, map:pmd ==
=pod

...

WolfgangMehner avatar Oct 03 '17 13:10 WolfgangMehner

No worries I continue to use your plugin!! Thanks very much Juan

Sent from my iPhone

On 3 Oct 2017, at 08:22, Wolfgang Mehner <[email protected]mailto:[email protected]> wrote:

Sorry for the long response time.

The new version of Perl-Supporthttps://github.com/WolfgangMehner/vim-plugins/commit/53d963d5d838958cf84b889a4621007b83ac2a25 I just uploaded now includes "File Skeletons". You can specify the list of templates to be included if you create a new file.

Use the map \ntw or the menu entry Perl -> Snippets -> template setup wizard inside a Perl buffer and create a "template customization file". It will create an example file for you, that even includes your request as an example. Uncomment the property and the template to use it:

§ templates automatically included into new files SetProperty ( 'Perl::FileSkeleton::Module', 'Comments.file description pm; ;Skeleton.module-pod; ;Skeleton.module-use' )

== Skeleton.module-pod == nomenu, below == =pod

=head2 SYNOPSIS

PACKAGE NAME: |BASENAME|

AUTHOR: |AUTHOR|

DATE: |DATE_PRETTY1|

DESCRIPTION: Version:

=head2 USE

=cut == ENDTEMPLATE ==

Alternatively, use can modify the customization file to create a new menu entry for the Perl -> POD sub-menu.

== POD.module documentation == below, map:pmd == =pod

...

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/WolfgangMehner/vim-plugins/issues/42#issuecomment-333839888, or mute the threadhttps://github.com/notifications/unsubscribe-auth/ACBVvWnWdkdnmdCieblolYpc0DOr9u2_ks5sojUfgaJpZM4PCzfv.

gllore avatar Oct 03 '17 19:10 gllore