perl_h2xs : Automate creating perl modules via h2xs
| script karma
Downloaded by 1027
Comments, bugs, improvements
script versions (upload new version)
|The Perl_h2xs.vim plugin is a plugin that allows you to automate the process of perl module creation. Writing Perl modules with the recommended structure can be time consuming so this ftplugin automates the process by involking h2xs when you edit a non-existant .pm file. I.e.
Will invoke h2xs -XAn Test::Bob, and if the module skeleton is created, will swap the edited file to Test/Bob/Bob.pm.
Through the use of variables, you can also set the plugin to create a MANIFEST.SKIP to exclude the CVS directories (and update the MANIFEST to include this new file) and to use CVS to import (or add) the newly created tree to a respository.
It works under windows and unix and you can even create .pm trees in another directory by specifying a directory name and module name in one. I.e.
would create the module:
See the readme file and help docs for detalis.
Enjoy, this is me being lazy :)
|The tarball contains the files:
so you can just untar'gzip the tarball in your local vim directory. I.e. .vim or vim61\vimfiles and all of the files will go into place. Start vim and rebuild your local help docs tags file using
Contact me if you have problems (with the module that is :-)
Click on the package to download.
ip used for rating: 126.96.36.199
||Regexp in substitution when getting module filenamewasn't anchored so it was turning X::Y::Z => X/Y/Z/Y/Z.pm not X/Y/Z/Z.pm
If module exists you start editing that rather than not checking if it exists and auto starting h2xs. This means you can create with vim X::Y::Z.pm then use !v to go back and you'll edit the module properly, added new var so you can be prompted before this happens if you want.