aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--README.org14
-rw-r--r--about.org9
-rw-r--r--blog/horses.org110
-rw-r--r--blog/index.org33
-rw-r--r--config/elfeed.org4
-rw-r--r--config/emacs.el239
-rw-r--r--config/emacs.org121
-rw-r--r--config/index.org34
-rw-r--r--config/nix.org2
-rw-r--r--img/bitcoin.pngbin0 -> 418 bytes
-rw-r--r--img/eth.pngbin0 -> 419 bytes
-rw-r--r--img/monero.pngbin0 -> 7547 bytes
-rw-r--r--index.org14
-rw-r--r--journal/20250102.org12
-rw-r--r--journal/20250103.org13
-rw-r--r--mindmap/Fourier Transform.org5
-rw-r--r--mindmap/LRC circuit.org2
-rw-r--r--mindmap/index.org131
-rw-r--r--mindmap/lrc_circuit.pngbin3271 -> 3229 bytes
-rw-r--r--mindmap/prv_LRC_circuit.org.log35
-rw-r--r--mindmap/texput.log24
-rw-r--r--style.css338
22 files changed, 704 insertions, 436 deletions
diff --git a/README.org b/README.org
index 1a3f08b..4c764cd 100644
--- a/README.org
+++ b/README.org
@@ -9,28 +9,26 @@ It's ret2pop! My website for all things math. Wait, no. Computer science.
Music. Okay, let me try that again.
It's ret2pop! My website for all things.
-
** Sounds awesome! But why is it written in org instead of html?
Because I have converted to the church of emacs. Remember:
-anything and everything that can be rewritten in org, can and should
-be rewritten in org.
+anything and everything that can be rewritten in org should be rewritten in org.
*** so how did you actually do that?
By using the ~org-publish~ function, ~org-roam~, and ~org-journal~,
-as well as writing a lot of things with a literate config.
+as well as writing a lot of things with a literate config. To see more, see my
+[[file:config/emacs.org][emacs configuration]] and my [[https://git.nullring.xyz/toughnix.git/tree/][NixOS configuration]].
** So, where is this website of yours located?
https://ret2pop.nullring.xyz, it is the road to enlightenment.
-
* Wait, so where are your dotfiles?
To use my dotfiles, clone this repository:
#+begin_src bash
git clone https://github.com/ret2pop/ret2pop-website.git ~/org/website
#+end_src
-and install my [[https://github.com/ret2pop/hyprnixmacs][NixOS Configuration]]. The org files /are/ the dotfiles, or
+and install my [[https://git.nullring.xyz/toughnix.git/][NixOS configuration]]. The org files /are/ the dotfiles, or
at least in the case of emacs.
To use my full system, you also need to have a ~password-store~ from the ~pass~
-password manager in its standard location with an entry called ~Mail~, and you need
-to clone my [[https://github.com/ret2pop/wallpapers.git][wallpapers]] repository.
+password manager in its standard location with an entry called ~Mail~, and you should
+otherwise follow the instructions listed on the hyprnixmacs repository.
* License
See the [[file:LICENSE.org][license]]. The style.css has its own license.
diff --git a/about.org b/about.org
index 866c374..8c1c0ec 100644
--- a/about.org
+++ b/about.org
@@ -41,14 +41,17 @@ contact me on matrix at ~ret2pop:social.nullring.xyz~.
My callsign is ~VE7PPN~.
*** Linkedin
You can see my [[https://ca.linkedin.com/in/preston-pan-4aa635296][personal linkedin profile]].
+*** How Old am I?
+born in 12/23/2005, but does it really matter?
** Keys
This is for all my public keys that are important. Note: for cryptocurrency public keys, see
[[file:index.org][the index]] page with all my addresses. Use either your own self hosted scanner, or another
public scanner to get my public keys.
- This is [[file:public-key.asc][my gpg public key for ret2pop]].
- This is [[file:id_ed25519.pub][my ssh key]].
+* Feeds
+RSS (and Atom feeds) are ways of keeping up-to-date in a minimal and universal way.
+- [[https://git.nullring.xyz/ret2pop-website.git/?format=atom][Website Cgit repo atom feed]]
+
* Professional
Here you can find [[file:./resume2.pdf][my resume]], which contains it all. I am always open for new job opportunities!
-
-* How Old am I?
-born in 12/23/2005, but does it really matter?
diff --git a/blog/horses.org b/blog/horses.org
new file mode 100644
index 0000000..7c68834
--- /dev/null
+++ b/blog/horses.org
@@ -0,0 +1,110 @@
+#+title: Stop Asking for Better Horses
+#+author: Preston Pan
+#+description: It doesn't happen instantly.
+#+html_head: <link rel="stylesheet" type="text/css" href="../style.css" />
+#+html_head: <link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png">
+#+html_head: <link rel="icon" type="image/png" sizes="32x32" href="/favicon-32x32.png">
+#+html_head: <link rel="icon" type="image/png" sizes="16x16" href="/favicon-16x16.png">
+#+html_head: <link rel="manifest" href="/site.webmanifest">
+#+html_head: <link rel="mask-icon" href="/safari-pinned-tab.svg" color="#5bbad5">
+#+html_head: <meta name="msapplication-TileColor" content="#da532c">
+#+html_head: <meta name="theme-color" content="#ffffff">
+#+html_head: <meta name="viewport" content="width=1000; user-scalable=0;" />
+#+language: en
+#+OPTIONS: broken-links:t
+
+* Times Never Change
+#+name: Henry Ford (allegedly)
+#+begin_quote
+If I had asked people what they wanted, they would have asked for better horses -- Henry Ford (Allegedly)
+#+end_quote
+Before his time, cars were nothing but a novelty item for people that could afford them.
+It's a simple idea, but it's what runs our world today. However, the democratization of information
+that the internet has blessed upon us has some side-effects that distort truth signals created
+by the market. Let's take a deep dive into the strange difference between what people /say is true/
+(i.e. "people want better horses!") versus what people /actually want/ (i.e. real demand or real
+risk taking).
+* You're Not Vested
+You (probably) are not an investor. You have no skin in the game, and you do not lose anything
+if your guess is wrong on the internet. Nobody will ultimately point out your mistake, because
+you're likely not important enough that your mistakes will be talked about. And, even for people
+that are, nobody will call them out on how wrong they are; people are too busy making their
+own opinions! So if you're not investor, it does no good to you if you think something is a bubble.
+In fact, if you /are/ an investor and have enough capital for what I'm suggesting, you should know
+about:
+** Information and Markets
+In a market, any relevant information that's not reflected in the price is an arbitrage opportunity.
+If you believe that some technology's fundamental value is zero (or low), you have a couple of
+options: shorting and puts (or some put spread). Of course, the common counterargument is that
+the market is irrational, so you'll just end up losing all your money if you buy puts. Well, you
+always have a choice of parameters. For instance, you can buy less puts and you can increase your
+amount OTM. If you have a couple million dollars, you could make a profit by buying one-week put
+options every week, while adjusting your parameters OTM. During a bubble, there are only two
+possibilities: either put options are not priced in, so as long as you continue to have capital
+there's always some risk exposure (isolating your thesis) that could allow you to make money, or
+the put options are priced in, in which case the fact that it's a bubble should be obvious from the
+EMH. Therefore, there's always a way to make money off of your twitter prediction! Will you? I
+believe that should be our measure of how much we should continue to believe in people on the
+internet.
+** Economists as Market Participants
+When economists predict a recession or predict a Ponzi scheme or bubble, why don't they participate
+in the market place? The government has essentially infinite capital; they could roll put options
+on their own economy if they wanted to. If the government is correct about a possible recession,
+then great: their bet in the market pays off, and it can use that bet to employ people and put
+them back to work. If the government is incorrect, more money flows into the private sector,
+strengthening the correct market actors and crippling the inefficient market actor. When economists
+make predictions, remember: they don't take risks like this, the government doesn't take risks like
+this in the same way market participants do. Therefore, this is my rule of thumb: /never/ trust
+/anyone/ that isn't vested in the market to tell you what's happening in the market, even
+/expert economists/. Economists can advise the government to short or to buy puts, basically
+participating in the market in the same way that regular market actors do. In this way, there is
+an inherent accountability/feedback mechanism.
+* The Internet is the Better Fax Machine
+People forget that the general sentiment at the time of the dot com bubble: while there were many
+people who were fanatics about the new technology, there were many skeptics, which all said the same
+thing: why do we need the internet when we already have [[https://www.laphamsquarterly.org/revolutions/miscellany/paul-krugmans-poor-prediction][fax machines]]? Often, they forget that
+they're /not/ market participants, and there's probably some underlying /reason/ why people are
+investing money at such a large volume. Of course, real bubbles exist, but it's no use in trying
+to distinguish fake bubbles from real bubbles if you're /not vested/. And, often, real bubbles
+are in part propped up by the government. In fact, if the government simply bought puts in the way
+outlined above, and they were correct, there would /be no bubbles/. Why do we need the internet?
+It's not for the economists to comment on, let alone the /average Joe/.
+* Blockchain is the Better (or Worse) Bank
+The same sentiment is currently being expressed by the public consciousness for blockchain
+technology. First, probably 80% of these people have never heard about smart contracts or how
+they work. I'm currently vested in blockchain, and I used to work in the industry. I can tell
+you a couple things about blockchain, but most of what I'll tell you is that most of the public
+is just /wrong/, like horribly wrong, most of the time. It's probably a common theme in most
+industries, but for blockchain, where on one hand there is a huge craze, and on the other there
+are people saying the technology is worth $0, it is even more so.
+
+Blockchain technology gives people incentives to agree on the state of some data so long as the
+native token is valuable, with possibly some state machine that manipulates this database of data.
+That's literally it. A lot of research into blockchain technology boils down to this, and its
+uses range from supply chain tracking to finance (which I think is the most realistic use-case).
+This isn't a debunk of common talking points, but what I can tell you is that for many use cases,
+if you didn't have the concept of blockchain, you'd almost have to reinvent it, but worse. That
+in and of itself makes the industry valuable, and given my "insider experience" (I didn't do that
+much but I was very much surrounded by world class experts), I can tell you that it's not all
+vaporware. And yet, despite all of these peoples' hard work, all their long hours and vision and
+clever insight, people have the audacity to say that the technology is equivalent to "a worse bank".
+* AI is the Better Autocomplete
+Now the new kid on the block is AI. Of course, people are already saying that this technology should
+be worth close to $0, or that this technology might be a net negative on society, when we haven't
+even seen 3 years worth of LLMs existing. People refuse to believe that these LLMs are developing
+emergent abilities, despite the [[https://cset.georgetown.edu/article/emergent-abilities-in-large-language-models-an-explainer/][clear evidence]] from LLM researchers suggesting so. People are out
+here still talking about next token prediction, meanwhile chain-of-thought reasoning and
+[[https://ai.meta.com/research/publications/large-concept-models-language-modeling-in-a-sentence-representation-space/][Large Concept Models]] are under way. The reason why we saw an explosion of narrative that
+"AI is just a better autocomplete" is specifically because people are resistant to change despite
+it being ultimately more demanded and better for them, in the same way people wanted
+/better horses/. When will the public learn to stop tracing the same loop?
+* Conclusion: Stop Asking for Better Horses
+Silicon Valley often reinvents the wheel in the early stages of large technology. However,
+clearly we see that investments into technology that on the surface are just "theoretically better
+horses" end up being completely different, and often more demanded and better products than the
+original. Of course there are real fuck-ups as well. See Enron and Theranos. But investors don't
+want to lose money; the government, on the other hand, won't leave people alone about regulations
+on the finance industry without showing us that it actually has better knowledge. And, it'd really
+be nice if the general public would stop expecting better horses, and then getting disappointed
+when they don't get them.
+
diff --git a/blog/index.org b/blog/index.org
index 26e36c8..8086990 100644
--- a/blog/index.org
+++ b/blog/index.org
@@ -21,23 +21,30 @@ Blog Articles:
#+begin_src shell :results output raw :exports both
for f in *;
do
- if [[ "$f" == "index.org" || "$f" == "img" ]]; then
- continue
+ if [[ "$f" == "index.org" || "$f" == "README.org" || "$f" == "emacs.el" ]]; then
+ continue
fi
- printf -- "- [[file:$f][$f]]\n"
+
+ if [ -d "$f" ]; then
+ continue
+ fi
+
+ name="$(grep '^#+title:' "$f" | sed 's/^#+title:[[:space:]]*//')"
+ printf -- "- [[file:$f][$name]]\n"
done
#+end_src
#+RESULTS:
-- [[file:automation.org][automation.org]]
-- [[file:cognition.org][cognition.org]]
-- [[file:crypto.org][crypto.org]]
-- [[file:machine_learning.org][machine_learning.org]]
-- [[file:nixos.org][nixos.org]]
-- [[file:private_keys.org][private_keys.org]]
-- [[file:stem.org][stem.org]]
-- [[file:tech-bros.org][tech-bros.org]]
-- [[file:voting.org][voting.org]]
-- [[file:you_dont_matter.org][you_dont_matter.org]]
+- [[file:automation.org][Automation, Hypocrisy, and Capitalism]]
+- [[file:cognition.org][Cognition]]
+- [[file:crypto.org][A Review of Cryptocurrency]]
+- [[file:horses.org][Stop Asking for Better Horses]]
+- [[file:machine_learning.org][Machine Learning is Here]]
+- [[file:nixos.org][You should use NixOS]]
+- [[file:private_keys.org][Passwords Are Obselete]]
+- [[file:stem.org][Stem]]
+- [[file:tech-bros.org][Tech Bros]]
+- [[file:voting.org][Representative Voting]]
+- [[file:you_dont_matter.org][You Don't Matter]]
@@html: </div>@@
diff --git a/config/elfeed.org b/config/elfeed.org
index cd37c15..f898995 100644
--- a/config/elfeed.org
+++ b/config/elfeed.org
@@ -22,6 +22,7 @@ but I mostly just want to inform myself about technology subjects.
*** [[https://www.wired.com/feed/tag/ai/latest/rss][Wired AI News]]
Wired isn't too bad at covering science and technology.
*** [[https://www.wired.com/feed/category/science/latest/rss][Wired Science]]
+Look above.
*** [[https://feeds.washingtonpost.com/rss/politics?itid=lk_inline_manual_2][Washington Post Politics]]
Politics is almost useless, but it helps with understanding what people are saying around me.
*** [[https://news.ycombinator.com/rss][Hacker News]]
@@ -30,6 +31,7 @@ Hacker News!
Credibility: misreported on ER EPR correspondence
** Podcasts :podcast:
*** [[https://notrelated.xyz/rss][Not Related]] :lukesmith:
+This is a podcast by Luke Smith that talks about anything that he wants to.
** Forums :forum:
** Science Journals :journal:
I like to get new information about recent studies related to technology.
@@ -47,4 +49,4 @@ UnHerd is one of the best, most interesting political podcasts, period, in my op
about politics is kind of pointless.
** Misc.
This is a section dedicated to everything that does not fit the above categories
-or is newly added from Qutebrowser with the xr keybinding.
+or is newly added from [[file:qutebrowser.org][Qutebrowser]] with the xr keybinding.
diff --git a/config/emacs.el b/config/emacs.el
index b56c646..9a7d473 100644
--- a/config/emacs.el
+++ b/config/emacs.el
@@ -1,3 +1,4 @@
+(require 'tex-site)
(pixel-scroll-precision-mode 1)
(setq scroll-conservatively 101)
(display-battery-mode 1)
@@ -23,7 +24,20 @@
(setq debug-ignored-errors
(cons 'remote-file-error debug-ignored-errors))
(set-face-attribute 'default nil :font "Iosevka Nerd Font" :height 140)
+(setq preview-default-option-list '("displaymath" "textmath" "graphics"))
+(setq preview-image-type 'png)
+(setq org-latex-pdf-process
+ '("xelatex -interaction=nonstopmode -output-directory=%o %f"))
+(setq org-latex-preview-image-directory "/home/preston/.cache/ltximg/")
(setq org-preview-latex-image-directory "/home/preston/.cache/ltximg/")
+(setq-default line-spacing 2)
+(setq org-startup-with-latex-preview t)
+(setq-default org-startup-indented t
+ org-pretty-entities t
+ org-use-sub-superscripts "{}"
+ org-hide-emphasis-markers t
+ org-startup-with-inline-images t
+ org-image-actual-width '(300))
(setq-default fill-column 100)
(add-hook 'text-mode-hook #'auto-fill-mode)
@@ -33,57 +47,58 @@
(setopt display-fill-column-indicator-column 100)
(add-hook 'prog-mode-hook #'display-fill-column-indicator-mode)
(add-hook 'org-mode-hook #'display-fill-column-indicator-mode)
+(setq TeX-engine 'xetex)
(add-hook 'prog-mode-hook
- (lambda ()
- (setq prettify-symbols-alist
- '(("lambda" . ?λ)
- ("->" . ?→)
- ("map" . ?↦)
- ("/=" . ?≠)
- ("!=" . ?≠)
- ("==" . ?≡)
- ("<=" . ?≤)
- (">=" . ?≥)
- ("&&" . ?∧)
- ("||" . ?∨)
- ("sqrt" . ?√)
- ("..." . ?…)))
- (prettify-symbols-mode)))
+ (lambda ()
+ (setq prettify-symbols-alist
+ '(("lambda" . ?λ)
+ ("->" . ?→)
+ ("map" . ?↦)
+ ("/=" . ?≠)
+ ("!=" . ?≠)
+ ("==" . ?≡)
+ ("<=" . ?≤)
+ (">=" . ?≥)
+ ("&&" . ?∧)
+ ("||" . ?∨)
+ ("sqrt" . ?√)
+ ("..." . ?…)))
+ (prettify-symbols-mode)))
(add-hook 'org-mode-hook (lambda ()
- (setq prettify-symbols-alist
- '(("#+begin_src" . ?)
- ("#+BEGIN_SRC" . ?)
- ("#+end_src" . ?)
- ("#+END_SRC" . ?)
- ("#+begin_example" . ?)
- ("#+BEGIN_EXAMPLE" . ?)
- ("#+end_example" . ?)
- ("#+END_EXAMPLE" . ?)
- ("#+header:" . ?)
- ("#+HEADER:" . ?)
- ("#+name:" . ?﮸)
- ("#+NAME:" . ?﮸)
- ("#+results:" . ?)
- ("#+RESULTS:" . ?)
- ("#+call:" . ?)
- ("#+CALL:" . ?)
- (":PROPERTIES:" . ?)
- (":properties:" . ?)
- ("lambda" . ?λ)
- ("->" . ?→)
- ("map" . ?↦)
- ("/=" . ?≠)
- ("!=" . ?≠)
- ("==" . ?≡)
- ("<=" . ?≤)
- (">=" . ?≥)
- ("&&" . ?∧)
- ("||" . ?∨)
- ("sqrt" . ?√)
- ("..." . ?…))))
- (prettify-symbols-mode))
+ (setq prettify-symbols-alist
+ '(("#+begin_src" . ?)
+ ("#+BEGIN_SRC" . ?)
+ ("#+end_src" . ?)
+ ("#+END_SRC" . ?)
+ ("#+begin_example" . ?)
+ ("#+BEGIN_EXAMPLE" . ?)
+ ("#+end_example" . ?)
+ ("#+END_EXAMPLE" . ?)
+ ("#+header:" . ?)
+ ("#+HEADER:" . ?)
+ ("#+name:" . ?﮸)
+ ("#+NAME:" . ?﮸)
+ ("#+results:" . ?)
+ ("#+RESULTS:" . ?)
+ ("#+call:" . ?)
+ ("#+CALL:" . ?)
+ (":PROPERTIES:" . ?)
+ (":properties:" . ?)
+ ("lambda" . ?λ)
+ ("->" . ?→)
+ ("map" . ?↦)
+ ("/=" . ?≠)
+ ("!=" . ?≠)
+ ("==" . ?≡)
+ ("<=" . ?≤)
+ (">=" . ?≥)
+ ("&&" . ?∧)
+ ("||" . ?∨)
+ ("sqrt" . ?√)
+ ("..." . ?…))))
+ (prettify-symbols-mode))
(global-prettify-symbols-mode 1)
(use-package unicode-fonts
@@ -99,28 +114,28 @@
(require 'org-habit)
(setq org-agenda-files (list "~/org/agenda.org"
- "~/org/notes.org"))
+ "~/org/notes.org"))
(setq org-default-notes-file (concat org-directory "/notes.org"))
(setq org-habit-preceding-days 1)
(require 'ox-publish)
(setq org-publish-project-alist
- '(("website-org"
- :base-directory "~/org/website"
- :base-extension "org"
- :publishing-directory "~/website_html"
- :recursive t
- :publishing-function org-html-publish-to-html
- :headline-levels 4
- :html-preamble t
- :html-preamble-format (("en" "<p class=\"preamble\"><a href=\"/index.html\">home</a> | <a href=\"./index.html\">section main page</a></p><hr>")))
- ("website-static"
- :base-directory "~/org/website"
- :base-extension "css\\|js\\|png\\|jpg\\|gif\\|pdf\\|mp3\\|ogg\\|swf\\|ico"
- :publishing-directory "~/website_html/"
- :recursive t
- :publishing-function org-publish-attachment)
- ("website" :auto-sitemap t :components ("website-org" "website-static"))))
+ '(("website-org"
+ :base-directory "~/org/website"
+ :base-extension "org"
+ :publishing-directory "~/website_html"
+ :recursive t
+ :publishing-function org-html-publish-to-html
+ :headline-levels 4
+ :html-preamble t
+ :html-preamble-format (("en" "<p class=\"preamble\"><a href=\"/index.html\">home</a> | <a href=\"./index.html\">section main page</a></p><hr>")))
+ ("website-static"
+ :base-directory "~/org/website"
+ :base-extension "css\\|js\\|png\\|jpg\\|gif\\|pdf\\|mp3\\|ogg\\|swf\\|ico\\|asc\\|pub\\|webmanifest\\|xml"
+ :publishing-directory "~/website_html/"
+ :recursive t
+ :publishing-function org-publish-attachment)
+ ("website" :auto-sitemap t :components ("website-org" "website-static"))))
;; (setq org-export-html-postamble-format '(("en" "<p class=\"preamble\"><a href=\"../index.html\">previous page</a> | <a href=\"/index.html\">home</a></p>")))
(setq org-html-postamble "Copyright © 2024 Preston Pan")
@@ -131,18 +146,18 @@ Otherwise, just insert the typed character."
(if (eolp) (let (parens-require-spaces) (insert-pair)) (self-insert-command 1)))
(add-hook 'org-mode-hook
- (lambda ()
- (define-key org-mode-map "\"" 'electric-pair)
- (define-key org-mode-map "(" 'electric-pair)
- (define-key org-mode-map "[" 'electric-pair)
- (define-key org-mode-map "{" 'electric-pair)))
+ (lambda ()
+ (define-key org-mode-map "\"" 'electric-pair)
+ (define-key org-mode-map "(" 'electric-pair)
+ (define-key org-mode-map "[" 'electric-pair)
+ (define-key org-mode-map "{" 'electric-pair)))
(add-hook 'prog-mode-hook
- (lambda ()
- (define-key prog-mode-map "\"" 'electric-pair)
- (define-key prog-mode-map "(" 'electric-pair)
- (define-key prog-mode-map "[" 'electric-pair)
- (define-key prog-mode-map "{" 'electric-pair)))
+ (lambda ()
+ (define-key prog-mode-map "\"" 'electric-pair)
+ (define-key prog-mode-map "(" 'electric-pair)
+ (define-key prog-mode-map "[" 'electric-pair)
+ (define-key prog-mode-map "{" 'electric-pair)))
(electric-pair-mode)
(use-package lyrics-fetcher
@@ -159,12 +174,12 @@ Otherwise, just insert the typed character."
(add-to-list 'yas-snippet-dirs "~/org/website/yasnippet/")
(yas-global-mode 1))
(add-hook 'org-mode-hook
- (lambda () (yas-minor-mode)
- (yas-activate-extra-mode 'latex-mode)))
+ (lambda () (yas-minor-mode)
+ (yas-activate-extra-mode 'latex-mode)))
(eval-after-load "company" '(add-to-list 'company-backends
- '(company-ispell company-capf company-irony
- company-yasnippet company-files)))
+ '(company-ispell company-capf company-irony
+ company-yasnippet company-files)))
(add-hook 'after-init-hook 'global-company-mode)
(use-package ispell
:init
@@ -178,9 +193,9 @@ Otherwise, just insert the typed character."
(org-babel-do-load-languages 'org-babel-load-languages
'(
- (shell . t)
- (python . t)
- (latex . t)
+ (shell . t)
+ (python . t)
+ (latex . t)
)
)
@@ -231,11 +246,11 @@ Otherwise, just insert the typed character."
(defun org-journal-file-header-func (time)
"Custom function to create journal header."
(concat
- (pcase org-journal-file-type
- (`daily "#+TITLE: Daily Journal\n#+STARTUP: showeverything\n#+DESCRIPTION: My daily journal entry\n#+AUTHOR: Preston Pan\n#+HTML_HEAD: <link rel=\"stylesheet\" type=\"text/css\" href=\"../style.css\" />\n#+html_head: <script src=\"https://polyfill.io/v3/polyfill.min.js?features=es6\"></script>\n#+html_head: <script id=\"MathJax-script\" async src=\"https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js\"></script>\n#+options: broken-links:t")
- (`weekly "#+TITLE: Weekly Journal\n#+STARTUP: folded")
- (`monthly "#+TITLE: Monthly Journal\n#+STARTUP: folded")
- (`yearly "#+TITLE: Yearly Journal\n#+STARTUP: folded"))))
+ (pcase org-journal-file-type
+ (`daily "#+TITLE: Daily Journal\n#+STARTUP: showeverything\n#+DESCRIPTION: My daily journal entry\n#+AUTHOR: Preston Pan\n#+HTML_HEAD: <link rel=\"stylesheet\" type=\"text/css\" href=\"../style.css\" />\n#+html_head: <script src=\"https://polyfill.io/v3/polyfill.min.js?features=es6\"></script>\n#+html_head: <script id=\"MathJax-script\" async src=\"https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js\"></script>\n#+options: broken-links:t")
+ (`weekly "#+TITLE: Weekly Journal\n#+STARTUP: folded")
+ (`monthly "#+TITLE: Monthly Journal\n#+STARTUP: folded")
+ (`yearly "#+TITLE: Yearly Journal\n#+STARTUP: folded"))))
(setq org-journal-file-header 'org-journal-file-header-func)
(setq org-journal-file-format "%Y%m%d.org")
@@ -302,10 +317,10 @@ Otherwise, just insert the typed character."
(setq dashboard-set-init-info t)
(setq dashboard-week-agenda t)
(setq dashboard-items '((recents . 5)
- (bookmarks . 5)
- (projects . 5)
- (agenda . 5)
- (registers . 5)))
+ (bookmarks . 5)
+ (projects . 5)
+ (agenda . 5)
+ (registers . 5)))
:config
(dashboard-setup-startup-hook))
@@ -345,18 +360,18 @@ Otherwise, just insert the typed character."
(defun prestonpan ()
(interactive)
(erc-tls :server "nullring.xyz"
- :port "6697"))
+ :port "6697"))
(defun liberachat ()
(interactive)
(erc-tls :server "irc.libera.chat"
- :port "6697"))
+ :port "6697"))
(defun efnet ()
(interactive)
(erc-tls :server "irc.prison.net"
- :port "6697"))
+ :port "6697"))
(defun matrix-org ()
(interactive)
@@ -423,8 +438,8 @@ Otherwise, just insert the typed character."
(require 'llm-ollama)
(with-eval-after-load 'llm-ollama)
(setopt ellama-provider (make-llm-ollama
- :host "localhost"
- :chat-model "gemma:7b")))
+ :host "localhost"
+ :chat-model "gemma:7b")))
(use-package elfeed
:init
@@ -453,8 +468,8 @@ Otherwise, just insert the typed character."
(setq search-engine-default "google")
(setq eww-search-prefix "https://google.com/search?q=")
-(setq browse-url-secondary-browser-function 'browse-url-generic browse-url-generic-program "chromium")
-(setq browse-url-browser-function 'eww-browse-url)
+(setq browse-url-secondary-browser-function 'browse-url-generic browse-url-generic-program "firefox")
+;; (setq browse-url-browser-function "firefox")
(add-hook 'eww-mode-hook
(lambda () (local-set-key (kbd "y Y") #'eww-copy-page-url)))
@@ -465,8 +480,8 @@ Otherwise, just insert the typed character."
(setq org-roam-directory (file-truename "~/org/website/mindmap"))
(setq org-roam-capture-templates '(("d" "default" plain "%?"
:target (file+head "${title}.org"
- "#+title: ${title}\n#+author: Preston Pan\n#+html_head: <link rel=\"stylesheet\" type=\"text/css\" href=\"../style.css\" />\n#+html_head: <script src=\"https://polyfill.io/v3/polyfill.min.js?features=es6\"></script>\n#+html_head: <script id=\"MathJax-script\" async src=\"https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js\"></script>\n#+options: broken-links:t")
- :unnarrowed t)))
+ "#+title: ${title}\n#+author: Preston Pan\n#+html_head: <link rel=\"stylesheet\" type=\"text/css\" href=\"../style.css\" />\n#+html_head: <script src=\"https://polyfill.io/v3/polyfill.min.js?features=es6\"></script>\n#+html_head: <script id=\"MathJax-script\" async src=\"https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js\"></script>\n#+options: broken-links:t")
+ :unnarrowed t)))
:config
(org-roam-db-autosync-mode))
@@ -475,9 +490,9 @@ Otherwise, just insert the typed character."
:hook (after-init . org-roam-ui-mode)
:config
(setq org-roam-ui-sync-theme t
- org-roam-ui-follow t
- org-roam-ui-update-on-save t
- org-roam-ui-open-on-start t))
+ org-roam-ui-follow t
+ org-roam-ui-update-on-save t
+ org-roam-ui-open-on-start t))
(use-package pinentry
:init (setq epa-pinentry-mode `loopback)
@@ -494,10 +509,10 @@ Otherwise, just insert the typed character."
(setq user-mail-address "preston@nullring.xyz")
(setq user-full-name "Preston Pan")
(setq sendmail-program "msmtp"
- send-mail-function 'smtpmail-send-it
- message-sendmail-f-is-evil t
- message-sendmail-extra-arguments '("--read-envelope-from")
- message-send-mail-function 'message-send-mail-with-sendmail)
+ send-mail-function 'smtpmail-send-it
+ message-sendmail-f-is-evil t
+ message-sendmail-extra-arguments '("--read-envelope-from")
+ message-send-mail-function 'message-send-mail-with-sendmail)
(require 'smtpmail)
(use-package mu4e
@@ -513,14 +528,14 @@ Otherwise, just insert the typed character."
(setq message-kill-buffer-on-exit t)
(setq mu4e-compose-dont-reply-to-self t)
(setq mu4e-change-filenames-when-moving t)
- (setq mu4e-get-mail-command "mbsync prestonpan")
+ (setq mu4e-get-mail-command "mbsync ret2pop")
(setq mu4e-compose-reply-ignore-address '("no-?reply" "ret2pop@gmail.com"))
(setq mu4e-html2text-command "w3m -T text/html" ; how to hanfle html-formatted emails
- mu4e-update-interval 300 ; seconds between each mail retrieval
- mu4e-headers-auto-update t ; avoid to type `g' to update
- mu4e-view-show-images t ; show images in the view buffer
- mu4e-compose-signature-auto-include nil ; I don't want a message signature
- mu4e-use-fancy-chars t))
+ mu4e-update-interval 300 ; seconds between each mail retrieval
+ mu4e-headers-auto-update t ; avoid to type `g' to update
+ mu4e-view-show-images t ; show images in the view buffer
+ mu4e-compose-signature-auto-include nil ; I don't want a message signature
+ mu4e-use-fancy-chars t))
(use-package ivy-pass)
diff --git a/config/emacs.org b/config/emacs.org
index 6b91f82..b46f973 100644
--- a/config/emacs.org
+++ b/config/emacs.org
@@ -1,4 +1,4 @@
-#+TITLE: Emacs Configuration
+#+title: Emacs Configuration
#+AUTHOR: Preston Pan
#+DESCRIPTION: my personal emacs configuration for nixOS
#+html_head: <link rel="stylesheet" type="text/css" href="../style.css" />
@@ -12,6 +12,7 @@ emacs-lisp language only to configure variables for said packages, for the most
This section contains important UI elements and starting customization variables to make
emacs work in a semi-sane way and make it not look ugly:
#+begin_src emacs-lisp
+ (require 'tex-site)
(pixel-scroll-precision-mode 1)
(setq scroll-conservatively 101)
(display-battery-mode 1)
@@ -35,9 +36,22 @@ emacs work in a semi-sane way and make it not look ugly:
(add-hook 'text-mode-hook 'visual-line-mode)
(and window-system (server-start))
(setq debug-ignored-errors
- (cons 'remote-file-error debug-ignored-errors))
+ (cons 'remote-file-error debug-ignored-errors))
(set-face-attribute 'default nil :font "Iosevka Nerd Font" :height 140)
+ (setq preview-default-option-list '("displaymath" "textmath" "graphics"))
+ (setq preview-image-type 'png)
+ (setq org-latex-pdf-process
+ '("xelatex -interaction=nonstopmode -output-directory=%o %f"))
+ (setq org-latex-preview-image-directory "/home/preston/.cache/ltximg/")
(setq org-preview-latex-image-directory "/home/preston/.cache/ltximg/")
+ (setq-default line-spacing 2)
+ (setq org-startup-with-latex-preview t)
+ (setq-default org-startup-indented t
+ org-pretty-entities t
+ org-use-sub-superscripts "{}"
+ org-hide-emphasis-markers t
+ org-startup-with-inline-images t
+ org-image-actual-width '(300))
(setq-default fill-column 100)
(add-hook 'text-mode-hook #'auto-fill-mode)
@@ -47,57 +61,58 @@ emacs work in a semi-sane way and make it not look ugly:
(setopt display-fill-column-indicator-column 100)
(add-hook 'prog-mode-hook #'display-fill-column-indicator-mode)
(add-hook 'org-mode-hook #'display-fill-column-indicator-mode)
+ (setq TeX-engine 'xetex)
(add-hook 'prog-mode-hook
- (lambda ()
- (setq prettify-symbols-alist
- '(("lambda" . ?λ)
- ("->" . ?→)
- ("map" . ?↦)
- ("/=" . ?≠)
- ("!=" . ?≠)
- ("==" . ?≡)
- ("<=" . ?≤)
- (">=" . ?≥)
- ("&&" . ?∧)
- ("||" . ?∨)
- ("sqrt" . ?√)
- ("..." . ?…)))
- (prettify-symbols-mode)))
+ (lambda ()
+ (setq prettify-symbols-alist
+ '(("lambda" . ?λ)
+ ("->" . ?→)
+ ("map" . ?↦)
+ ("/=" . ?≠)
+ ("!=" . ?≠)
+ ("==" . ?≡)
+ ("<=" . ?≤)
+ (">=" . ?≥)
+ ("&&" . ?∧)
+ ("||" . ?∨)
+ ("sqrt" . ?√)
+ ("..." . ?…)))
+ (prettify-symbols-mode)))
(add-hook 'org-mode-hook (lambda ()
- (setq prettify-symbols-alist
- '(("#+begin_src" . ?)
- ("#+BEGIN_SRC" . ?)
- ("#+end_src" . ?)
- ("#+END_SRC" . ?)
- ("#+begin_example" . ?)
- ("#+BEGIN_EXAMPLE" . ?)
- ("#+end_example" . ?)
- ("#+END_EXAMPLE" . ?)
- ("#+header:" . ?)
- ("#+HEADER:" . ?)
- ("#+name:" . ?﮸)
- ("#+NAME:" . ?﮸)
- ("#+results:" . ?)
- ("#+RESULTS:" . ?)
- ("#+call:" . ?)
- ("#+CALL:" . ?)
- (":PROPERTIES:" . ?)
- (":properties:" . ?)
- ("lambda" . ?λ)
- ("->" . ?→)
- ("map" . ?↦)
- ("/=" . ?≠)
- ("!=" . ?≠)
- ("==" . ?≡)
- ("<=" . ?≤)
- (">=" . ?≥)
- ("&&" . ?∧)
- ("||"