Add the following code to you. Emacs. Bind this equation to a button you.
(Require 'AutoInsert)
(Auto-INSERT-MODE) ;; Adds Hook to Find-Files-Hook
(setq auto-insert-directory "~ / .mytemplates /")
(setq auto-insert-query nil) ;; if you don't want to be propped before insertion
(Define-auto-insert "/.pl" "my-perl-template.pl")