Compare commits

..

10 commits

Author SHA1 Message Date
Laurens Miers
6c169b230e Re-add helm-mt 2019-05-09 17:23:48 +02:00
Laurens Miers
5792beb9ee Remove helm-mt for now 2019-05-09 17:18:06 +02:00
Laurens Miers
71b5e34a9e Add Multi-term and Helm-mt 2019-05-09 16:53:50 +02:00
laurensmiers
593de2293d ensure eglot package + add prog-mode-hook
- TODO: don't add it to prog-mode-hook, add it to c-mode-hook and
  others supporting LSP
2019-04-24 19:30:43 +02:00
laurensmiers
5559316d09 Ensure ccls package is installed 2019-04-24 19:30:43 +02:00
laurensmiers
e411693eb0 Enable ccls for c-mode 2019-04-24 19:30:43 +02:00
laurensmiers
348b36dafd Cleanup 2019-04-24 19:30:43 +02:00
laurensmiers
57c0927448 working lsp with cquery 2019-04-24 19:28:44 +02:00
laurensmiers
fb94a22ec9 working lsp with clangd 2019-04-24 19:28:44 +02:00
laurensmiers
6e2fb64ec8 lsp-experiment:
- call lsp-clangd-enable + flycheck-mode to have IDE like stuff
2019-04-24 19:28:44 +02:00
21 changed files with 1242 additions and 2744 deletions

26
.gitignore vendored
View file

@ -1,26 +0,0 @@
custom.el
backups
eshell
elpaca
eln-cache
elpa
org-roam.db
transient
# projectile
projectile*
# savehist file
history
# recentf file
recentf
session*
# .org converted files
config*.el
# Tramp connection file
tramp

3
.gitmodules vendored Normal file
View file

@ -0,0 +1,3 @@
[submodule "extra/sunrise-commander"]
path = extra/sunrise-commander
url = https://github.com/escherdragon/sunrise-commander

8
cheat-sheet.txt Normal file
View file

@ -0,0 +1,8 @@
C-M-Space : smartparens wrapping
C-c C-c : calculator (see init.el)
C-h k <key-sequence>: lookup key sequence
C-x 0 : close current window
C-q <tab> : insert a <tab>
M-x (un)tabify : (replace) tabs
M-x describe-bindings : list of all mapped keys/commands
M-p : fill-paragraph, works for doxygen as well

2121
config.org

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,8 @@
;; Add irony as flycheck hook
(eval-after-load 'flycheck
'(add-hook 'flycheck-mode-hook 'flycheck-irony-setup))
;; Set tab to autocomplete or indent depending on context
(global-set-key (kbd "<tab>") 'company-indent-or-complete-common)
(provide 'setup-autocompletion)

11
custom/setup-coding.el Normal file
View file

@ -0,0 +1,11 @@
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Python ;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(require 'py-autopep8)
(elpy-enable)
(setq elpy-modules (delq 'elpy-module-flycheck elpy-modules))
(add-hook 'elpy-mode-hook 'flycheck-mode)
(add-hook 'elpy-mode-hook 'py-autopep8-enable-on-save)
(provide 'setup-coding)

28
custom/setup-org.el Normal file
View file

@ -0,0 +1,28 @@
(require 'org)
(define-key global-map "\C-cl" 'org-store-link)
(define-key global-map "\C-ca" 'org-agenda)
;; when ending TODO (C-C C-t) end with a note + timestamp
(setq org-log-done 'note)
;; Specify root dir to search for agenda files, TODOs, ...
(setq org-agenda-files '("~/org"))
;; Add extra states for keywords
(setq org-todo-keywords
'((sequence "TODO" "IN-PROGRESS" "WAITING" "DONE")))
(setq org-export-with-sub-superscripts nil)
;; Preserve indentation in SRC blocks
(setq org-src-preserve-indentation t)
;; Specify which languages are allowed to run inside org-mode
(org-babel-do-load-languages
'org-babel-load-languages '(
(ditaa . t))
)
;; Tell org where to look for ditaa
(setq org-ditaa-jar-path "/usr/share/java/ditaa/ditaa-0_10.jar")
(provide 'setup-org)

View file

@ -1,18 +0,0 @@
;;; early-init.el --- Early Init -*- lexical-binding: t; -*-
;;; Commentary:
;; Early init configuration for Emacs Solo
;;
;;; Code:
;; Only care about errors in *Messages* buffer
(setq warning-minimum-level :error)
;; We control when packages are enabled
(setq package-enable-at-startup nil)
(provide 'early-init)
;;; early-init.el ends here

@ -0,0 +1 @@
Subproject commit cf8305a149a321d028858057e7a7c92f0038a06a

BIN
img/dash_logo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 64 KiB

53
init.el
View file

@ -1,28 +1,39 @@
;;; init.el --- Init -*- lexical-binding: t; -*- ;; IMPORTANT: add (require 'package), else package-archives is not declared (void-variable)
(require 'package)
(setq package-enable-at-startup nil)
;;; Commentary: ;; add melpa-stable to package-archives
;;; Load init files (add-to-list 'package-archives
'("melpa-stable" . "https://stable.melpa.org/packages/") t)
(add-to-list 'package-archives
'("melpa" . "http://melpa.milkbox.net/packages/") t)
;; MUST be called after package-archives is updated
(package-initialize)
;;; Code: ;;; Bootstrapping use-package
(unless (package-installed-p 'use-package)
(package-refresh-contents)
(package-install 'use-package))
;;; Increase garbage collection threshold during init but leave it to the default value after ;;; This is the actual config file. It is omitted if it doesn't exist so emacs won't refuse to launch.
;;; There are a LOT of articles/sites/... discussing this: (when (file-readable-p "~/.emacs.d/config.org")
;;; https://bling.github.io/blog/2016/01/18/why-are-you-changing-gc-cons-threshold/ (org-babel-load-file (expand-file-name "~/.emacs.d/config.org")))
;;; https://jonnay.github.io/emagicians-starter-kit/Emagician-Base.html
;;; ...
(let ((gc-cons-threshold most-positive-fixnum))
(setq custom-file (expand-file-name "custom.el" user-emacs-directory))
;; This is the actual config file. It is omitted if it doesn't exist so emacs won't refuse to launch.
(defvar my-config-file (expand-file-name "config.org" user-emacs-directory))
(when (file-readable-p my-config-file)
(org-babel-load-file (expand-file-name my-config-file)))
(load custom-file :no-error-if-file-is-missing)
)
(provide 'init) (provide 'init)
(custom-set-variables
;;; init.el ends here ;; custom-set-variables was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
'(helm-gtags-auto-update t)
'(package-selected-packages
(quote
(elpy linum-relative avy flycheck-irony irony-eldoc company-irony company-c-headers flycheck magit py-autopep8 multiple-cursors helm-gtags helm-swoop zygospore yasnippet volatile-highlights use-package undo-tree smartparens smart-mode-line monokai-theme iedit helm expand-region dashboard comment-dwim-2))))
(custom-set-faces
;; custom-set-faces was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
)

View file

@ -3,6 +3,6 @@
# key: fori # key: fori
# -- # --
for (${1:size_t i = 0}; ${2:i < N}; ${3:++i}) { for (${1:int i = 0}; ${2:i < N}; ${3:++i}) {
$0 $0
} }

View file

@ -0,0 +1,9 @@
#name : #ifndef XXX; #define XXX; #endif
# key: oncekl
# --
#ifndef ${1:`(upcase (file-name-nondirectory (file-name-sans-extension (or (buffer-file-name) ""))))`_H_}
#define $1
$0
#endif /* $1 */

View file

@ -1,6 +0,0 @@
# -*- mode: snippet -*-
# name: Make a define
# key: def
# --
#define ${1:mydefine$(upcase yas-text)} $2

View file

@ -1,10 +0,0 @@
#name : #ifndef XXX; #define XXX; #endif
# key: header
# --
#ifndef ${1:_`(upcase (file-name-nondirectory (file-name-sans-extension (or (buffer-file-name) ""))))`_H_}
#define $1
$0
#endif /* $1 */

View file

@ -1,6 +0,0 @@
# -*- mode: snippet -*-
# name: kaboom
# key: kb
# --
char (*__kaboom)[sizeof($1)] = 1;

View file

@ -1,8 +0,0 @@
# -*- mode: snippet -*-
# name: Start emacs source block
# key: se
# --
#+BEGIN_SRC emacs-lisp
${1}
#+END_SRC

View file

@ -1,6 +0,0 @@
# -*- mode: snippet -*-
# name: Filetags
# key: ft
# --
#+FILETAGS: :$1:

View file

@ -1,8 +0,0 @@
# -*- mode: snippet -*-
# name: Org source code block
# key: s
# --
#+BEGIN_SRC
${1}
#+END_SRC

View file

@ -1,10 +0,0 @@
# -*- mode: snippet -*-
# name: Git commit message template
# key: bac
# --
Before this commit,
${1}
After this commit,
${2}