about summary refs log tree commit diff
path: root/src/etc/vim/compiler/cargo.vim
diff options
context:
space:
mode:
authorAlex Crichton <alex@alexcrichton.com>2015-01-30 12:03:26 -0800
committerAlex Crichton <alex@alexcrichton.com>2015-01-30 12:03:26 -0800
commite2282f9cfbf47fcbc0cf637507215dadb8cb1fc5 (patch)
tree8a080ee809e9f3ec18fad48ede8551121d485825 /src/etc/vim/compiler/cargo.vim
parentebee4b4b37bc860accb8ad41946edfd5acdfc6a8 (diff)
parent017b3a543182006fa64bdc8c721969ae38c125f9 (diff)
downloadrust-e2282f9cfbf47fcbc0cf637507215dadb8cb1fc5.tar.gz
rust-e2282f9cfbf47fcbc0cf637507215dadb8cb1fc5.zip
rollup merge of #21738: steveklabnik/move_out_editors
As we grow, these don't belong in-tree.

http://internals.rust-lang.org/t/moving-editor-highlighting-into-their-own-repos/1395

* https://github.com/rust-lang/rust.vim
* https://github.com/rust-lang/rust-mode
* https://github.com/rust-lang/gedit-config
* https://github.com/rust-lang/kate-config
* https://github.com/rust-lang/nano-config
* https://github.com/rust-lang/zsh-config
Diffstat (limited to 'src/etc/vim/compiler/cargo.vim')
-rw-r--r--src/etc/vim/compiler/cargo.vim65
1 files changed, 0 insertions, 65 deletions
diff --git a/src/etc/vim/compiler/cargo.vim b/src/etc/vim/compiler/cargo.vim
deleted file mode 100644
index ed487a308e1..00000000000
--- a/src/etc/vim/compiler/cargo.vim
+++ /dev/null
@@ -1,65 +0,0 @@
-" Vim compiler file
-" Compiler:         Cargo Compiler
-" Maintainer:       Damien Radtke <damienradtke@gmail.com>
-" Latest Revision:  2014 Sep 24
-
-if exists('current_compiler')
-  finish
-endif
-runtime compiler/rustc.vim
-let current_compiler = "cargo"
-
-if exists(':CompilerSet') != 2
-    command -nargs=* CompilerSet setlocal <args>
-endif
-
-if exists('g:cargo_makeprg_params')
-    execute 'CompilerSet makeprg=cargo\ '.escape(g:cargo_makeprg_params, ' \|"').'\ $*'
-else
-    CompilerSet makeprg=cargo\ $*
-endif
-
-" Allow a configurable global Cargo.toml name. This makes it easy to
-" support variations like 'cargo.toml'.
-let s:cargo_manifest_name = get(g:, 'cargo_manifest_name', 'Cargo.toml')
-
-function! s:is_absolute(path)
-    return a:path[0] == '/' || a:path =~ '[A-Z]\+:'
-endfunction
-
-let s:local_manifest = findfile(s:cargo_manifest_name, '.;')
-if s:local_manifest != ''
-    let s:local_manifest = fnamemodify(s:local_manifest, ':p:h').'/'
-    augroup cargo
-        au!
-        au QuickfixCmdPost make call s:FixPaths()
-    augroup END
-
-    " FixPaths() is run after Cargo, and is used to change the file paths
-    " to be relative to the current directory instead of Cargo.toml.
-    function! s:FixPaths()
-        let qflist = getqflist()
-        let manifest = s:local_manifest
-        for qf in qflist
-            if !qf.valid
-                let m = matchlist(qf.text, '(file://\(.*\))$')
-                if !empty(m)
-                    let manifest = m[1].'/'
-                    " Manually strip another slash if needed; usually just an
-                    " issue on Windows.
-                    if manifest =~ '^/[A-Z]\+:/'
-                        let manifest = manifest[1:]
-                    endif
-                endif
-                continue
-            endif
-            let filename = bufname(qf.bufnr)
-            if s:is_absolute(filename)
-                continue
-            endif
-            let qf.filename = simplify(manifest.filename)
-            call remove(qf, 'bufnr')
-        endfor
-        call setqflist(qflist, 'r')
-    endfunction
-endif