Browse Source

add latexmkrc

Signed-off-by: surenyi <surenyi82@qq.com>
master
surenyi 2 years ago
parent
commit
b414b73a91
  1. 30
      emacs/dot.spacemacs
  2. 3
      emacs/emacsclient.vbs
  3. 2
      emacs/runemacs.vbs
  4. 41
      latex/latexmkrc

30
emacs/dot.spacemacs

@ -50,7 +50,7 @@ This function should only modify configuration layer settings."
auto-completion-private-snippets-directory nil
auto-completion-enable-snippets-in-popup nil
auto-completion-enable-help-tooltip nil
company-emoji-insert-unicode nil
company-emoji-insert-unicode t
auto-completion-use-company-box nil
auto-completion-enable-sort-by-usage nil)
(better-defaults :variables
@ -63,13 +63,14 @@ This function should only modify configuration layer settings."
(git :variables
git-enable-magit-svn-plugin t
git-enable-magit-todos-plugin t
git-enable-magit-delta-plugin t
git-magit-status-fullscreen t)
(helm :variables
helm-use-fuzzy 'source
spacemacs-helm-rg-max-column-number 1024
helm-enable-auto-resize t)
(lsp :varaibles
lsp-lens-enable t)
lsp-lens-enable t)
lua
(vimscript :variables
vimscript-backend 'lsp)
@ -102,6 +103,7 @@ This function should only modify configuration layer settings."
(colors :variables colors-colorize-identifiers 'all)
themes-megapack ;; eziam-theme in packages.el is eziam-themes
pandoc
epub
(shell :variables
shell-default-shell 'eshell
shell-default-full-span nil
@ -112,6 +114,7 @@ This function should only modify configuration layer settings."
;; spell-checking
;; syntax-checking
(version-control :variables
version-control-diff-side 'left
version-control-global-margin t)
semantic
emoji
@ -308,8 +311,8 @@ It should only modify the values of Spacemacs settings."
;; pair of numbers, e.g. `(recents-by-project . (7 . 5))', where the first
;; number is the project limit and the second the limit on the recent files
;; within a project.
dotspacemacs-startup-lists '((recents . 5)
(projects . 7))
dotspacemacs-startup-lists '((recents . 10)
(projects . 5))
;; True if the home buffer should respond to resize events. (default t)
dotspacemacs-startup-buffer-responsive t
@ -575,7 +578,7 @@ It should only modify the values of Spacemacs settings."
;; If non-nil, start an Emacs server if one is not already running.
;; (default nil)
dotspacemacs-enable-server nil
dotspacemacs-enable-server t
;; Set the emacs server socket location.
;; If nil, uses whatever the Emacs default is, otherwise a directory path
@ -683,9 +686,9 @@ It is mostly for variables that should be set before packages are loaded.
If you are unsure, try setting them in `dotspacemacs/user-config' first."
(setq configuration-layer-elpa-archives
'(("melpa-cn" . "http://mirrors.tuna.tsinghua.edu.cn/elpa/melpa/")
("org-cn" . "http://mirrors.tuna.tsinghua.edu.cn/elpa/org/")
("gnu-cn" . "http://mirrors.tuna.tsinghua.edu.cn/elpa/gnu/")
("nongnu" . "https://elpa.nongnu.org/nongnu/")))
("org-cn" . "http://mirrors.tuna.tsinghua.edu.cn/elpa/org/")
("gnu-cn" . "http://mirrors.tuna.tsinghua.edu.cn/elpa/gnu/")
("nongnu" . "https://elpa.nongnu.org/nongnu/")))
dotspacemacs-distinguish-gui-tab t
(setq default-frame-alist (append '((scroll-bar-width . 10))))
)
@ -736,7 +739,6 @@ configuration.
Put your configuration code here, except for variables that should be set
before packages are loaded."
;; Bind clang-format-region to C-M-tab in all modes:
(global-set-key [C-M-tab] 'clang-format-region)
;; Bind clang-format-buffer to tab on the cc-mode:
@ -817,6 +819,16 @@ before packages are loaded."
(plantuml . t)
(latex . t)))
(add-to-list 'org-src-lang-modes '("plantuml" . fundamental))))
;; emoji font
(dolist (font '("Symbola" "Segoe UI Emoji" "Noto Color Emoji" "Apple Color Emoji"))
(when (member font (font-family-list))
(set-fontset-font
t 'symbol (font-spec :family font) nil 'prepend)))
;; (when (member "Segoe UI Emoji" (font-family-list))
;; (set-fontset-font
;; t 'symbol (font-spec :family "Segoe UI Emoji") nil 'prepend))
)
(custom-set-variables

3
emacs/emacsclient.vbs

@ -0,0 +1,3 @@
set ws = WScript.CreateObject("WScript.shell")
ws.Run "emacs.bat emacsclientw.exe -n -r -a ""emacs.bat runemacs.exe --geometry 160x40+100+40""",0

2
emacs/runemacs.vbs

@ -1,3 +1,3 @@
set ws = WScript.CreateObject("WScript.shell")
ws.Run "emacs.bat",0
ws.Run "emacs.bat runemacs.exe --geometry 160x40+100+40",0

41
latex/latexmkrc

@ -0,0 +1,41 @@
# PDF-generating modes are:
# 1: pdflatex, as specified by $pdflatex variable (still largely in use)
# 2: postscript conversion, as specified by the $ps2pdf variable (useless)
# 3: dvi conversion, as specified by the $dvipdf variable (useless)
# 4: lualatex, as specified by the $lualatex variable (best)
# 5: xelatex, as specified by the $xelatex variable (second best)
$pdf_mode=4;
$preview_mode=0;
$out_dir="output";
$pdf_previewer = "SumatraPDF -reuse-instance -inverse-search -a %O %S";
@default_files=("*.tex");
# nonstopmode will print more infomations
$lualatex="lualatex -shell-escape -synctex=1 -interaction=batchmode %O %S";
$success_cmd="internal mycopy %D";
sub mycopy {
use File::Copy;
use FIle::Basename;
my $pdf = $_[0];
my $name = basename($pdf);
my $relpdf = "pdf/".$name;
copy($pdf, $name);
copy($pdf, $relpdf);
# replace extension ".pdf" with ".synctex.gz"
$pdf =~ s{\.[^.]*(?:\.pdf)?$}{.synctex.gz};
copy($pdf, ".");
}
# Add custom dependency.
# latexmk checks whether a file with ending as given in the 2nd
# argument exists ('toextension'). If yes, check if file with
# ending as in first argument ('fromextension') exists. If yes,
# run subroutine as given in fourth argument.
# Third argument is whether file MUST exist. If 0, no action taken.
Loading…
Cancel
Save