1 2 3 4 5 6 7 8 9 10 11 12
function! sonictemplate#lang#perl#guess() if expand('%:t') ==# 'Makefile.PL' return 'make' endif if expand('%:t:e') ==# 'pl' return 'script' endif if expand('%:t:e') ==# 'pm' return 'package' endif return '' endfunction