Sha256: a9977f3a40a7dd50e69575ff540192d580d6117bba0f30c95efe395898306295
Contents?: true
Size: 495 Bytes
Versions: 16
Compression:
Stored size: 495 Bytes
Contents
let $RUBYPATH = 'lib' function! s:run_example() if &ft != "ruby" " Not ruby, do nothing. return endif " look for it ", with no word character just before ‘it’ let line = search( '\w\@<!it "', "bnW" ) let cmd = "rspec --no-color " . expand( "%" ) . " -l " . line if line > 0 execute "!" . cmd else echo "No rspec example found at or before cursor position." endif endfun nmap <leader>t :call <SID>run_example()<CR>
Version data entries
16 entries across 16 versions & 1 rubygems