Skip to content

Commit 83a5869

Browse files
author
Gianluca Arbezzano
committed
bootstrap
0 parents  commit 83a5869

File tree

3 files changed

+74
-0
lines changed

3 files changed

+74
-0
lines changed

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
The MIT License
2+
3+
Copyright (c) 2015, Gianluca Arbezzano, and a number of other of contributors
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in
13+
all copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21+
THE SOFTWARE.

README.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# vim composer
2+
Manage [composer](https://getcomposer.org) in Vim
3+
```vim
4+
:ComposerRun <args>
5+
```
6+
7+
## Install
8+
```vim
9+
Bundle 'vim-php/vim-composer'
10+
```
11+
12+
## Force composer phar
13+
This plugin support an autodetach test to check the correct path of composer.phar
14+
If this check fails you can try to force correct path
15+
```
16+
let g:composer_cmd = "/usr/bin/composer"
17+
```
18+
19+
## Contrib
20+
This plugin is very easy, there is a lot of space for community update, feedback and
21+
features request.
22+
Help me with issues and PRs!
23+
Thanks!

plugin/vim-composer.vim

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
" ------------------------------------------------------------------------------
2+
" Vim Composer {{{
3+
"
4+
" Author: Gianluca Arbezzano <[email protected]>
5+
"
6+
" Description:
7+
" Run Composer from within Vim.
8+
"
9+
" Requires: Vim 6.0 or newer
10+
"
11+
" License: MIT
12+
"
13+
" }}}
14+
" ------------------------------------------------------------------------------
15+
16+
if !exists("g:composer_cmd")
17+
if filereadable('./composer.phar')
18+
let g:composer_cmd='./composer.phar'
19+
else
20+
let g:composer_cmd='composer'
21+
endif
22+
endif
23+
24+
command! -narg=* ComposerRun call s:ComposerRunFunc(<q-args>)
25+
26+
function! s:ComposerRunFunc(arg)
27+
let s:arg = a:arg
28+
exe "!".g:composer_cmd." ".s:arg
29+
endfunction
30+

0 commit comments

Comments
 (0)