Skip to content

nykma/nema

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

NEMA - Nayuki’s EMAcs config

https://builds.sr.ht/~nykma/nema/test.yml.svg https://img.shields.io/badge/written%20with-nema-e298b6.svg

https://user-images.githubusercontent.com/1191636/74646301-85dc6c80-51b4-11ea-900e-3827ee42c979.png

What’s this?

A not-so-hurt-yet-still-make-kind-of-sense emacs configuration set, c/w a bunch of packages.

Goal

  1. Any specific {package,variable} config should be found no more than 2 layers down from init.el.
  2. I will not focus on “startup speed”, since daemonize Emacs is all you need.

Usage

cd ~
mv .emacs.d .emacs.d.old
git clone https://github.com/nykma/nema.git .emacs.d
emacs -nw

Hotkey cheatsheet

HotkeyCommandDefined inComment
C-c g gmagit-statusnema-vcs.elgit status
C-c g bmagit-blamenema-vcs.elgit blame current buffer
C-c g dmagit-diff-buffer-filenema-vcs.elgit diff current buffer
C-’avy-goto-char-timernema-basic.elCursor jump to location
C->mc/mark-next-like-this-symbolnema-basic.elMulti cursor (find next symbol)
C-Cmc/edit-linesnema-basic.elMulti cursor (add one cursor each line)
M-S-RETedwina-clone-windownema-basic.elProvided by edwina
M-inema-termnema-terminal.elStart a terminal buffer
C-c & waya-createnema-snippet.elCreate and use a snippet when editing
C-M-oace-windownema-basic.elPowerful window switch
C-1 ~ C-9winum-select-window-1nema-basic.elQuick window switch

Customize

customize-group

There is a customize group called nema to give you a few customization options. Remember to restart emacs if anything is changed.
nema-use-evil
Whether or not to use evil-mode. Default to nil. My evil-mode intergration is at a very basic level (since I don’t use evil-mode). Any pull request is welcomed.
nema-emacs-completion-engine
Choose between ivy, helm, vertico and ido. Default to ivy
nema-lsp
Use LSP or not. Remember to follow server installation instructions below. Default to nil
nema-theme
Choose one theme from given pre-defined themes list.
nema-theme-style
Switch between dark and light mode of your theme (if supported).
nema-mode-line
Choose which mode line to use.

Besides

There are many ways to hack this. You can
  1. Write your ELisp in .emacs.d/my/*.el. They will be loaded after all nema-* modules are loaded.
    • Your YAS snippets will be saved and loaded in .emacs.d/my/snippets/**/*. (See nema-snippet.el)
    • .emacs.d/my/**/* is in .gitignore list. So you can save sensitive data (e.g. IRC login info or Mail account) or some machine-specific configs (e.g. if you have a HiDPI laptop and a workstation with normal DPI displays) without syncing across with VCS.
    • I’ve written some maybe-useful scripts in my-sample/*.el. Symlink (or copy) them into your my/ folder to enable them.
  2. Fork me.

LSP server installation

See lsp-mode supported languages

Known issues

  1. If it is run at its first time, make sure not to use emacs --server, since it may prompt you of Elisp-enabled themes warning or native plugin compilation. Use emacs or emacs -nw instead, and press y if prompted. When .emacs.d/custom.el is built, you can use server mode without problem.

Many thanks to

License

GPLv3 for
  • Initialization and core files
  • Layer files (nema-*.el)
  • my-sample/*.el

See LICENSE file