- GNU Official Windows Binaries
- Mac Universal Binaries (
brew cask install emacs) - Emacs Mac Port
Clone Emacs source code from official repository
- Install Xcode command line tools by
xcode-select --install - Install dependencies by
brew install pkg-config gnutls(Hint:brew info emacs) ./configure --with-native-compilationmake install -j$(nproc) NATIVE_FULL_AOT=1(This step will assemble the app innextstep/Emacs.app. Seenextstep/INSTALLfor more information.)- Link or copy
nextstep/Emacs.appto/Applications
- Follow the instructions in https://github.com/d12frosted/homebrew-emacs-plus
apt install build-essentialandapt build-dep emacs. These commands install the necessary dependent packages.make(SeeINSTALL.REPOin the emacs repository for more information.)- To use native elisp ahead-of-time compilation in Emacs 29, run
./autogen.sh && ./configure --with-native-compilation=aot && make -j$(nproc) - After the build finished,
emacsandemacsclientwill be available undersrcandlib-src, respectively. Add them to the loading path of your preferred shell.
- “Wrong type argument: commandp” error
- eval-after-load vs. mode hook
- Call function with prefix argument programmatically
- Directory name and its name as a file
- Prefix Command Arguments
- File variables
- Use
trace-functionto see the callstack of a given function.
- Use
describe-coding-systemto show current coding system. - Use
set-buffer-file-coding-system(orC-x RET f) to convert the current buffer to a coding system. - http://www.masteringemacs.org/articles/2012/08/09/working-coding-systems-unicode-emacs/
- http://www.reai.us/windows-emacs-encoding
- During selecting a candidate, press
M-oto select an action to perform. https://oremacs.com/swiper/#how-can-different-actions-be-called
- Check installed dictionaries:
hunspell -D - Download en_US dictionary
- On Mac OS, dictionaries can be installed under
~/Library/Spelling/ - Hunspell executable for Windows
C-c ': edit source code block.C-c *: toggle the heading statusC-c -: toggle the items in plain list.C-c ^: sort the plain list.C-c C-e b: export the file to HTML and show it in browser.C-c C-l: insert a link.C-c C-x C-f: insert or change emphasis.C-u C-c C-l: insert a file link.- Adjust exported headline levels
- Support languages in source code block
org-export-with-sub-superscripts: Interpret “_” and “^” for export. Set^:{}
C-x u: undo-tree-visualize
M-x magit-toggle-verbose-refreshto debug magit performance issue https://magit.vc/manual/magit/Performance.html https://jakemccrary.com/blog/2020/11/14/speeding-up-magit/
- Install
wgrep. - Use
counsel-rgand type the search string. - Press
C-c C-oto convert to a `ivy-occur` buffer. - Press
C-x C-qorwto switch to edit mode. - After editing the lines in buffers, press
C-x C-sto save all.
https://www.gnu.org/software/emacs/manual/html_node/efaq/Replacing-text-across-multiple-files.html
Press C-u C-\ greek RET to switch to Greek input method. Leave by pressing C-\.