Skip to content

Commit

Permalink
New README file
Browse files Browse the repository at this point in the history
  • Loading branch information
c9s committed Mar 27, 2010
1 parent 2000427 commit e7a97da
Show file tree
Hide file tree
Showing 2 changed files with 93 additions and 16 deletions.
76 changes: 60 additions & 16 deletions README.mkd
Original file line number Diff line number Diff line change
@@ -1,30 +1,19 @@

Screenshot
==========
![](http://cloud.github.com/downloads/c9s/perl-completion.vim/Screen_shot_2009-11-19_at_7.23.06_AM.png)
![](http://cloud.github.com/downloads/c9s/perl-completion.vim/Screen_shot_2009-11-19_at_7.23.34_AM.png)
![](http://cloud.github.com/downloads/c9s/perl-completion.vim/Screen_shot_2009-11-19_at_7.24.17_AM.png)


Install
========
perl-completion.vim comes with some depended vim scripts (libperl.vim and
search-window.vim) and perl-completion.vim is using PPI (pure perl parser) to
parse perl syntax to make completions.

to install PPI:

$ sudo cpan PPI
just run make:

put the util script `utils/find_base_classes.pl` to your $PATH.
$ make install

copy `ftplugin/perl/perlomni.vim` to your `~/.vim/ftplugin/perl/` runtime path.
and add ~/.vim/bin/ to your $PATH env variable , for example, add these lines to your .bashrc or .zshrc:

and put libperl.vim ( http://github.com/c9s/libperl.vim/raw/master/vimlib/autoload/libperl.vim )
to your `~/.vim/autoload/`.
export PATH=~/.vim/bin:$PATH

to enable perl-completion.vim omni completion, you have to enable your filetype
plugin on. pre-append those settings to your `.vimrc`:
please make sure you've enable filetype plugin your `.vimrc`:

filetype on
filetype plugin on
Expand All @@ -34,3 +23,58 @@ Usage
=====

C-x C-o to emit omnicompletion.


Samples
=======


# complete class methods
Jifty::DBI::Record->

# complete built-in function
seekdir


# complete current object methods
sub testtest { }
sub foo1 { }
sub foo2 { }

$self->


# smart object method completion
my $var = new Jifty;
$var->


# smart object method completion 2
my $var = Jifty::DBI->new;
$var->


# complete variable
$var1 $var2 $var3 $var_test $var__adfasdf
$var__adfasdf


# moose complete

has url => (
metaclass => 'Labeled',
is => 'wo',
isa => 'HashRef',
label => "The site's URL",
);

# role

with 'Restartable' => {
-alias => {
stop => '_stop',
start => '_start'
},
-excludes => [ 'stop', 'start' ],
};

33 changes: 33 additions & 0 deletions README.mkd.old
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@

Screenshot
==========

Install
========

perl-completion.vim comes with some depended vim scripts (libperl.vim and
search-window.vim) and perl-completion.vim is using PPI (pure perl parser) to
parse perl syntax to make completions.

to install PPI:

$ sudo cpan PPI

put the util script `utils/find_base_classes.pl` to your $PATH.

copy `ftplugin/perl/perlomni.vim` to your `~/.vim/ftplugin/perl/` runtime path.

and put libperl.vim ( http://github.com/c9s/libperl.vim/raw/master/vimlib/autoload/libperl.vim )
to your `~/.vim/autoload/`.

to enable perl-completion.vim omni completion, you have to enable your filetype
plugin on. pre-append those settings to your `.vimrc`:

filetype on
filetype plugin on
filetype indent on

Usage
=====

C-x C-o to emit omnicompletion.

0 comments on commit e7a97da

Please sign in to comment.