emacs

Emacs Orgmode Minted Setup

How to setup orgmode pdf export with minted on Arch Linux

Guowei Lv

1 minute read

Install minted package https://en.wikibooks.org/wiki/LaTeX/Installing_Extra_Packages Install Pygments https://pygments.org/ Configure Emacs (setq org-latex-listings 'minted org-latex-packages-alist '(("" "minted")) org-latex-pdf-process '("pdflatex -shell-escape -interaction nonstopmode -output-directory %o %f" "pdflatex -shell-escape -interaction nonstopmode -output-directory %o %f" "pdflatex -shell-escape -interaction nonstopmode -output-directory %o %f")) Remove cached minted* dirs This is the step that unblocked me. Prevent src block line too long (setq org-latex-minted-options '(("breaklines" "true") ("breakanywhere" "true")))

[Guowei Lv]

1 minute read

Hello World First item Second item this is some code This is a subheading private static void main() {} LaTeX formatted equation: ( E = -J \sum_{i=1}^N s_i s_{i+1} ) \begin{equation} \label{eq:1} C = W\log_{2} (1+\mathrm{SNR}) \end{equation}

Magit Tutorial - Bisect

How to use Magit in Emacs to do bisecting

3 minute read

Git rebase with Magit

It’s 5 o’clock on a sunny Friday afternoon, you are thinking where to have dinner with friends and such. The only thing you have to finish before you can go is to pull your colleage’s latest changes and make a demo build to customer. You pull, there are 20 commits all nicely structured, you are now giving yourself a pat on the back for teaching him to use rebase yesterday (by pointing him to these 2 wonderful articles 1 and 2).

Magit tutorial - Rebase (Part II)

How to use Magit in Emacs to do rebase in Git

2 minute read

Git rebase with Magit

In part I we went through how to use git rebase to modify commit history, things like reword a commit, squash multiple commits, split commit. In this part, we will talk about another common use case of rebase: rebase before merging branches. Let’s first create a new repo and add one file.txt as the first commit. apple pear peach cat dog snake Now we create a feature branch from master branch.

Magit tutorial - Rebase (Part I)

How to use Magit in Emacs to do rebase in Git

3 minute read

Git rebase with Magit

Magit is arguably the best Git tool out there and also my favorite. It is a package in Emacs, and it is text based. In this tutorial, we will explore how to use it to tackle one of the more elusive topics in Git: Rebase. In the beginning there was darkness Let’s create an empty repository and add one empty file to it. git init touch file.txt git add . git commit -m 'first commit' Rewording commit Now let’s add some fruits in the file.