Table of contents for fic exports, save elfeed db, automatically track dwpost
This commit is contained in:
parent
a636884879
commit
5842a69d22
6 changed files with 43 additions and 15 deletions
9
.gitignore
vendored
9
.gitignore
vendored
|
@ -1,16 +1,17 @@
|
||||||
|
\#*
|
||||||
auto-save-list/*
|
auto-save-list/*
|
||||||
backups/*
|
backups/*
|
||||||
|
bookmarks
|
||||||
config.el
|
config.el
|
||||||
elpa/*
|
elpa/*
|
||||||
emojis/*
|
emojis/*
|
||||||
*recentf
|
fic-export-files/auto/*
|
||||||
url/*
|
|
||||||
bookmarks
|
|
||||||
nohup.out
|
nohup.out
|
||||||
\#*
|
|
||||||
network-security.data
|
network-security.data
|
||||||
nov-places
|
nov-places
|
||||||
places
|
places
|
||||||
|
*recentf
|
||||||
request/*
|
request/*
|
||||||
tramp
|
tramp
|
||||||
transient/*
|
transient/*
|
||||||
|
url/*
|
12
config.org
12
config.org
|
@ -338,6 +338,18 @@ This apparently deletes really old entries from the database.
|
||||||
:remove 'unread))
|
:remove 'unread))
|
||||||
#+END_SRC
|
#+END_SRC
|
||||||
|
|
||||||
|
Save elfeed state properly when exiting Emacs.
|
||||||
|
|
||||||
|
#+BEGIN_SRC emacs-lisp
|
||||||
|
(defun save-if-elfeed ()
|
||||||
|
(if (get-buffer "*elfeed-search*")
|
||||||
|
(progn
|
||||||
|
(elfeed-db-save)
|
||||||
|
(message "Elfeed DB saved"))))
|
||||||
|
|
||||||
|
(add-hook 'kill-emacs-hook 'save-if-elfeed)
|
||||||
|
#+END_SRC
|
||||||
|
|
||||||
** =git-gutter=
|
** =git-gutter=
|
||||||
|
|
||||||
Shows, or at least purports to show, =git diff= in the left margin if the file is being tracked by =git=. The colours don’t seem to work properly with the current theme.
|
Shows, or at least purports to show, =git diff= in the left margin if the file is being tracked by =git=. The colours don’t seem to work properly with the current theme.
|
||||||
|
|
|
@ -98,6 +98,14 @@
|
||||||
(sleep-for 0)
|
(sleep-for 0)
|
||||||
(insert (concat "post-music: " music "\n"))))
|
(insert (concat "post-music: " music "\n"))))
|
||||||
|
|
||||||
|
(defun dw-posted ()
|
||||||
|
(find-file-noselect "~/Documents/drive/org/calendar/habit.org")
|
||||||
|
(with-current-buffer "habit.org"
|
||||||
|
(goto-char (point-min))
|
||||||
|
(re-search-forward "RECUR dw posts")
|
||||||
|
(org-shiftright)
|
||||||
|
(save-buffer)))
|
||||||
|
|
||||||
(defun dwpost (psubject tags)
|
(defun dwpost (psubject tags)
|
||||||
(interactive (list (read-string "Post title (REQUIRED): ")
|
(interactive (list (read-string "Post title (REQUIRED): ")
|
||||||
(read-string "Tags (comma-separated): ")))
|
(read-string "Tags (comma-separated): ")))
|
||||||
|
@ -118,4 +126,5 @@
|
||||||
(kill-buffer newname)
|
(kill-buffer newname)
|
||||||
(kill-buffer (concat "*sent mail to " dw-username "*"))
|
(kill-buffer (concat "*sent mail to " dw-username "*"))
|
||||||
(with-current-buffer oldname
|
(with-current-buffer oldname
|
||||||
(delete-file newname)))
|
(delete-file newname))
|
||||||
|
(dw-posted))
|
||||||
|
|
|
@ -187,7 +187,10 @@
|
||||||
(progn
|
(progn
|
||||||
(goto-char (point-min))
|
(goto-char (point-min))
|
||||||
(while (re-search-forward "\\\\begin{document}" nil t)
|
(while (re-search-forward "\\\\begin{document}" nil t)
|
||||||
(replace-match "\\begin{document}\n\\pagestyle{multititlechapters}" nil t)))
|
(replace-match "\\begin{document}\n\\pagestyle{multititlechapters}" nil t))
|
||||||
|
(goto-char (point-min))
|
||||||
|
(while (re-search-forward "\\\\end{titlingpage}" nil t)
|
||||||
|
(replace-match "\\end{titlingpage}\n\\tableofcontents\*" nil t)))
|
||||||
(progn
|
(progn
|
||||||
(goto-char (point-min))
|
(goto-char (point-min))
|
||||||
(while (re-search-forward "\\\\begin{document}" nil t)
|
(while (re-search-forward "\\\\begin{document}" nil t)
|
||||||
|
@ -196,7 +199,7 @@
|
||||||
(progn
|
(progn
|
||||||
(goto-char (point-min))
|
(goto-char (point-min))
|
||||||
(while (re-search-forward "\\\\begin{document}" nil t)
|
(while (re-search-forward "\\\\begin{document}" nil t)
|
||||||
(replace-match "\\begin{document}\n\\pagestyle{multinotitlechapters}" nil t)))
|
(replace-match "\\begin{document}\n\\pagestyle{multinotitlechapters}\n\\tableofcontents\*" nil t)))
|
||||||
(progn
|
(progn
|
||||||
(goto-char (point-min))
|
(goto-char (point-min))
|
||||||
(while (re-search-forward "\\\\begin{document}" nil t)
|
(while (re-search-forward "\\\\begin{document}" nil t)
|
||||||
|
@ -216,7 +219,7 @@
|
||||||
(format "xelatex -interaction=batchmode %s"
|
(format "xelatex -interaction=batchmode %s"
|
||||||
(shell-quote-argument (buffer-file-name))))
|
(shell-quote-argument (buffer-file-name))))
|
||||||
(shell-command
|
(shell-command
|
||||||
(format "xelatex -interaction=batchmode -halt-on-error %s"
|
(format "xelatex -interaction=batchmode %s"
|
||||||
(shell-quote-argument (buffer-file-name))))
|
(shell-quote-argument (buffer-file-name))))
|
||||||
(kill-current-buffer))
|
(kill-current-buffer))
|
||||||
(delete-file "FFXYevon.ttf")
|
(delete-file "FFXYevon.ttf")
|
||||||
|
|
|
@ -28,7 +28,8 @@
|
||||||
"sepffx"
|
"sepffx"
|
||||||
"currentname"
|
"currentname"
|
||||||
"titlegen"
|
"titlegen"
|
||||||
"titleasal")
|
"titleasal"
|
||||||
|
"cftchapterpresnum")
|
||||||
(LaTeX-add-polyglossia-langs
|
(LaTeX-add-polyglossia-langs
|
||||||
'("english" "defaultlanguage" "variant=british"))
|
'("english" "defaultlanguage" "variant=british"))
|
||||||
(LaTeX-add-fontspec-newfontcmds
|
(LaTeX-add-fontspec-newfontcmds
|
||||||
|
|
|
@ -16,6 +16,13 @@
|
||||||
|
|
||||||
\usepackage{titling}
|
\usepackage{titling}
|
||||||
|
|
||||||
|
\makeatletter
|
||||||
|
\def\cftchapterpresnum #1\@cftasnum{}
|
||||||
|
\cftsetindents{chapter}{0pt}{0pt}
|
||||||
|
\makeatother
|
||||||
|
\renewcommand*{\cftchapterfont}{\normalfont}
|
||||||
|
\renewcommand*{\cftchapterpagefont}{\normalfont}
|
||||||
|
|
||||||
\usepackage{polyglossia}
|
\usepackage{polyglossia}
|
||||||
\setdefaultlanguage[variant=british]{english}
|
\setdefaultlanguage[variant=british]{english}
|
||||||
|
|
||||||
|
@ -24,12 +31,7 @@
|
||||||
\usepackage{graphicx}
|
\usepackage{graphicx}
|
||||||
|
|
||||||
\PassOptionsToPackage{hyphens}{url}\usepackage[hidelinks]{hyperref}
|
\PassOptionsToPackage{hyphens}{url}\usepackage[hidelinks]{hyperref}
|
||||||
\hypersetup{
|
|
||||||
colorlinks,
|
|
||||||
linkcolor={red!50!black},
|
|
||||||
citecolor={green!30!black},
|
|
||||||
urlcolor={blue!80!black}
|
|
||||||
}
|
|
||||||
\makeatletter
|
\makeatletter
|
||||||
\DeclareMathSymbol{0}{\mathalpha}{\eu@DigitsArabic@symfont}{`0}
|
\DeclareMathSymbol{0}{\mathalpha}{\eu@DigitsArabic@symfont}{`0}
|
||||||
\DeclareMathSymbol{1}{\mathalpha}{\eu@DigitsArabic@symfont}{`1}
|
\DeclareMathSymbol{1}{\mathalpha}{\eu@DigitsArabic@symfont}{`1}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue