aboutsummaryrefslogtreecommitdiffstats
path: root/autoload/xolox/easytags/utils.vim
blob: a88c7a83033d26f305352cce9362b0d7a34846ce (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
" Vim script
" Author: Peter Odding <peter@peterodding.com>
" Last Change: June 20, 2014
" URL: http://peterodding.com/code/vim/easytags/

" Utility functions for vim-easytags.

function! xolox#easytags#utils#canonicalize(pathname)
  if !empty(a:pathname)
    return xolox#misc#path#absolute(xolox#easytags#utils#resolve(a:pathname))
  endif
  return a:pathname
endfunction

function! xolox#easytags#utils#resolve(pathname)
  if !empty(a:pathname) && xolox#misc#option#get('easytags_resolve_links', 0)
    return resolve(a:pathname)
  endif
  return a:pathname
endfunction