From: Andreas Gerler Date: Wed, 7 Sep 2022 16:59:31 +0000 (+0200) Subject: custom org-mode snippets X-Git-Url: http://git.bundesbrandschatzamt.de/?a=commitdiff_plain;h=aed598b70cdc08377640b9e892b059b2f7bcfafe;p=emacsconfig.git custom org-mode snippets Signed-off-by: Andreas Gerler --- diff --git a/snippets/org-mode.org b/snippets/org-mode.org index 8f670ddc..1c54d1be 100644 --- a/snippets/org-mode.org +++ b/snippets/org-mode.org @@ -4,6 +4,7 @@ | babel-sh | babel-shell | skeleton to generate a sh file out of an org file | | blog | blog | skeleton for a blog entry | | results | :res | add results parameter. for src block. | +| epilogue | :epi | ignore exit code and get result | | sqlmysql | sqlmysql | properties to connect to MySQL via org | | sqlora | sqlora | properties to connect to Oracle via org and Perl DBI | | srcclient | &1 | grep -E '(start date|expire date|subject)' + curl -kvvI https://$1 2>&1 | grep -E '(start date|expire date|subject)' #+end_src $0 diff --git a/snippets/org-mode/epilogue b/snippets/org-mode/epilogue new file mode 100644 index 00000000..0e98b7b6 --- /dev/null +++ b/snippets/org-mode/epilogue @@ -0,0 +1,5 @@ +# -*- mode: snippet -*- +# name: epilogue +# key: :epi +# -- +:epilogue true$0 \ No newline at end of file diff --git a/snippets/org-mode/pagerduty b/snippets/org-mode/pagerduty index 4e3c1e75..6f6b5dab 100644 --- a/snippets/org-mode/pagerduty +++ b/snippets/org-mode/pagerduty @@ -2,5 +2,5 @@ # name: pagerduty-clocktable # key: pagerduty_ # -- -$0#+BEGIN: clocktable :maxlevel 2 :narrow 80 :scope agenda-with-archives :tstart "${1:`(org-read-date nil nil "-1mon")`}" :tend "${2:`(org-read-date nil nil "today")`}" :match "PAGERDUTY" :fileskip0 :formula :link % +$0#+BEGIN: clocktable :maxlevel 2 :narrow 80 :scope agenda-with-archives :tstart "${1:`(org-read-date nil nil "-1mon")`}" :tend "${2:`(org-read-date nil nil "today")`} 12:00:00" :match "PAGERDUTY" :fileskip0 :formula :link % #+END: \ No newline at end of file diff --git a/snippets/org-mode/res b/snippets/org-mode/res index 5b1dad3e..9c896c8d 100644 --- a/snippets/org-mode/res +++ b/snippets/org-mode/res @@ -3,6 +3,6 @@ # key: res_ # -- #+RESULTS: -:RESULTS: +#+begin_src fundamental $0 -:END: \ No newline at end of file +#+end_src \ No newline at end of file diff --git a/snippets/org-mode/results b/snippets/org-mode/results index 1afec474..ea35855e 100644 --- a/snippets/org-mode/results +++ b/snippets/org-mode/results @@ -3,4 +3,4 @@ # key: :res # add results parameter to src block # -- -:results ${1:$$(yas-choose-value '("verbatim drawer" "table" "list" "silent" "value code :wrap SRC sql" "value code :wrap SRC json" "value code :wrap SRC fundamental"))} $0 \ No newline at end of file +:results ${1:$$(yas-choose-value '("verbatim drawer" "table" "list" "silent" "output code :wrap SRC sql" "output code :wrap SRC json" "output code :wrap SRC fundamental"))} $0 \ No newline at end of file