~ubuntu-branches/ubuntu/vivid/vim/vivid

« back to all changes in this revision

Viewing changes to runtime/ftplugin/perl.vim

  • Committer: Bazaar Package Importer
  • Author(s): Soren Hansen
  • Date: 2008-11-05 11:37:43 UTC
  • mfrom: (1.1.6 upstream)
  • Revision ID: james.westby@ubuntu.com-20081105113743-9i4urcsm3n44mhqe
Tags: 2:7.2.025-2ubuntu1
* Merge from debian unstable, remaining changes:
  - runtime/syntax/debcontrol.vim:
    + Add "metapackages" to the list of valid sections.
  - runtime/syntax/debchangelog.vim:
    + Add "jaunty" to the list of valid suites.
  - Drop vim-lesstif package and lesstif2-dev build-dependency.
  - Enable Python interpreter on basic builds.
  - Create a .pot file for translations.
  - Disable autoindent, line-wrapping, and backup files by default.
  - runtime/syntax/debsources.vim:
    + Add "jaunty" to debsourcesDistrKeyword
  - runtime/syntax/grub.vim:
    + Add Ubuntu-specific 'quiet' keyword.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
" Vim filetype plugin file
2
2
" Language:     Perl
3
3
" Maintainer:   Dan Sharp <dwsharp at hotmail dot com>
4
 
" Last Change:  2005 Dec 16
 
4
" Last Change:  17 Jul 2008
5
5
" URL:          http://mywebpage.netscape.com/sharppeople/vim/ftplugin
6
6
 
7
7
if exists("b:did_ftplugin") | finish | endif
13
13
set cpo-=C
14
14
 
15
15
setlocal formatoptions+=crq
 
16
setlocal keywordprg=perldoc\ -f
16
17
 
17
18
setlocal comments=:#
18
19
setlocal commentstring=#%s
39
40
set isfname+=:
40
41
"setlocal iskeyword=48-57,_,A-Z,a-z,:
41
42
 
42
 
" Debian patch: use perldoc for keyword lookup
43
 
setlocal keywordprg=perldoc\ -f
44
 
 
45
43
" Set this once, globally.
46
44
if !exists("perlpath")
47
45
    if executable("perl")
 
46
      try
48
47
        if &shellxquote != '"'
49
48
            let perlpath = system('perl -e "print join(q/,/,@INC)"')
50
49
        else
51
50
            let perlpath = system("perl -e 'print join(q/,/,@INC)'")
52
51
        endif
53
52
        let perlpath = substitute(perlpath,',.$',',,','')
 
53
      catch /E145:/
 
54
        let perlpath = ".,,"
 
55
      endtry
54
56
    else
55
57
        " If we can't call perl to get its path, just default to using the
56
58
        " current directory and the directory of the current file.
62
64
"---------------------------------------------
63
65
 
64
66
" Undo the stuff we changed.
65
 
let b:undo_ftplugin = "setlocal fo< com< cms< inc< inex< def< isf<" .
 
67
let b:undo_ftplugin = "setlocal fo< com< cms< inc< inex< def< isf< kp<" .
66
68
            \         " | unlet! b:browsefilter"
67
69
 
68
70
" Restore the saved compatibility options.