mirror of
https://github.com/amix/vimrc
synced 2025-07-06 07:55:00 +08:00
Revert "Merge from original repo"
This commit is contained in:
@ -30,11 +30,6 @@ endglobal
|
||||
###########################################################################
|
||||
# TextMate Snippets #
|
||||
###########################################################################
|
||||
snippet ponce "#pragma once include guard"
|
||||
#pragma once
|
||||
|
||||
endsnippet
|
||||
|
||||
snippet main
|
||||
int main(int argc, char *argv[])
|
||||
{
|
||||
@ -72,14 +67,6 @@ namespace${1/.+/ /m}${1:`!p snip.rv = snip.basename or "name"`}
|
||||
}${1/.+/ \/* /m}$1${1/.+/ *\/ /m}
|
||||
endsnippet
|
||||
|
||||
snippet nsa "namespace alias"
|
||||
namespace ${1:alias} = ${2:namespace};
|
||||
endsnippet
|
||||
|
||||
snippet using "using directive/using declaration/type alias"
|
||||
using ${1:namespace}`!p snip.rv = ' ' if t[1] == 'namespace' else ' = ' if t[1] != '' else ''`${2:name};
|
||||
endsnippet
|
||||
|
||||
snippet readfile "read file (readF)"
|
||||
std::vector<char> v;
|
||||
if (FILE *fp = fopen(${1:"filename"}, "r"))
|
||||
|
@ -104,11 +104,11 @@ snippet local "local x = 1"
|
||||
local ${1:x} = ${0:1}
|
||||
endsnippet
|
||||
|
||||
snippet use "Use" b
|
||||
snippet use "Use" Ab
|
||||
use { '$1' }
|
||||
endsnippet
|
||||
|
||||
snippet req "Require" b
|
||||
snippet req "Require"
|
||||
require('$1')
|
||||
endsnippet
|
||||
|
||||
|
@ -1,28 +0,0 @@
|
||||
# snippets for smarty3
|
||||
|
||||
extends html
|
||||
extends javascript
|
||||
extends css
|
||||
|
||||
|
||||
|
||||
|
||||
# https://www.smarty.net/docs/en/language.function.append.tpl
|
||||
snippet append "{append} is used for creating or appending template variable arrays during the execution of a template."
|
||||
{append var='${1}' value='${2}'${3: index='${4|first,last|}'}${5: scope='${6|parent,root,global|}'}}
|
||||
endsnippet
|
||||
|
||||
# https://www.smarty.net/docs/en/language.function.assign.tpl
|
||||
snippet assign "{assign} is used for assigning template variables during the execution of a template."
|
||||
{assign var='${1}' value='${2}'${3: scope='${4|parent,root,global|}'}}
|
||||
endsnippet
|
||||
|
||||
# https://www.smarty.net/docs/en/language.function.config.load.tpl
|
||||
snippet config_load "config_load"
|
||||
{config_load file='${1}'${2: section='${3}'}${4: scope='${5|local,parent,global|}'}}
|
||||
endsnippet
|
||||
|
||||
# https://www.smarty.net/docs/en/language.function.include.tpl
|
||||
snippet include "{include} tags are used for including other templates in the current template. Any variables available in the current template are also available within the included template."
|
||||
{include file='${1}'${2: assign='${3}'}${4: cache_lifetime=${5}}${6: compile_id='${7}'}${8: cache_id='${9}'}${10: scope='${11|parent,root,global|}'}${12: variables}}
|
||||
endsnippet
|
@ -454,6 +454,27 @@ snippet docls "Document Class" bA
|
||||
\documentclass{$1}$0
|
||||
endsnippet
|
||||
|
||||
snippet tmplt "Template"
|
||||
\documentclass{article}
|
||||
|
||||
\usepackage{import}
|
||||
\usepackage{pdfpages}
|
||||
\usepackage{transparent}
|
||||
\usepackage{xcolor}
|
||||
$1
|
||||
|
||||
\newcommand{\incfig}[2][1]{%
|
||||
\def\svgwidth{#1\columnwidth}
|
||||
\import{./figures/}{#2.pdf_tex}
|
||||
}
|
||||
$2
|
||||
\pdfsuppresswarningpagegroup=1
|
||||
|
||||
\begin{document}
|
||||
$0
|
||||
\end{document}
|
||||
endsnippet
|
||||
|
||||
|
||||
#########
|
||||
# OTHER #
|
||||
|
Reference in New Issue
Block a user