Skip to content

Instantly share code, notes, and snippets.

Avatar

Michael Piotrowski mxpiotrowski

View GitHub Profile
@mxpiotrowski
mxpiotrowski / mxp-copy-as-rich-text.el
Created Jun 2, 2021
Convert region to RTF (using pandoc) and copy to macOS clipboard.
View mxp-copy-as-rich-text.el
(defun mxp-copy-as-rich-text (start end)
"Convert region to RTF (using pandoc) and copy to macOS clipboard.
Input format is “org” or “markdown” depending on the buffer's major mode."
(interactive "r")
(let ((coding-system-for-read 'utf-8)
(coding-system-for-write 'utf-8)
(src (cond ((eq major-mode 'org-mode) "org")
(t "markdown"))))
(shell-command-on-region start end
View markdown-mode-additions.el
;;; Markdown
(defun my-markdown-mode-hook ()
(visual-line-mode)
(setq markdown-use-pandoc-style-yaml-metadata t)
(define-key markdown-mode-map [(control c) (?\[)] 'helm-bibtex)
(define-key markdown-mode-map [(control c) (control v)] 'mxp-find-corresponding-pdf)
(when (package-installed-p 'bury-successful-compilation)
(bury-successful-compilation))
View biblatex-locode-mwe.tex
\documentclass[a4paper]{article}
\usepackage[ngerman, american]{babel}
\usepackage[autostyle=true, german=swiss]{csquotes}
\usepackage[backend=biber, style=authoryear, isbn=false, autolang=hyphen]{biblatex}
\usepackage{filecontents}
\begin{filecontents}{\jobname.bib}
@Book{Piotrowski2012a,
author = {Piotrowski, Michael},
title = {Natural Language Processing for Historical Texts},
View keybase.md

Keybase proof

I hereby claim:

  • I am mxpiotrowski on github.
  • I am mxpi (https://keybase.io/mxpi) on keybase.
  • I have a public key ASBRU27S0HyRzjOcDq9pIAbF6BaPbh0slm0Zv7qLR7f8ewo

To claim this, I am signing this object: