diff options
author | johannst <johannes.stoelp@gmail.com> | 2019-08-18 20:12:05 +0200 |
---|---|---|
committer | johannst <johannes.stoelp@gmail.com> | 2019-08-18 20:12:05 +0200 |
commit | d0d03fdaa849492f94c1c2504d389614e166b247 (patch) | |
tree | 6049e4d4ab5ccbb240e39cd02b73a6128ed408ad | |
parent | 3043d6d847630d9e295119dbb32f5e9bbac0aa1a (diff) | |
download | dotfiles-d0d03fdaa849492f94c1c2504d389614e166b247.tar.gz dotfiles-d0d03fdaa849492f94c1c2504d389614e166b247.zip |
added emacs config & installer
-rw-r--r-- | emacs.el | 28 | ||||
-rwxr-xr-x | install | 17 | ||||
-rw-r--r-- | install.config | 1 |
3 files changed, 46 insertions, 0 deletions
diff --git a/emacs.el b/emacs.el new file mode 100644 index 0000000..240ca5d --- /dev/null +++ b/emacs.el @@ -0,0 +1,28 @@ +;; dotfiles -- emacs.johannst.el +;; author: johannst + +(provide 'johannst) + +;; fix 'bad request' on package-refresh-contents (should be fixed with emcas 26.3) +(setq gnutls-algorithm-priority "NORMAL:-VERS-TLS1.3") + +;; ELPA & MELPA +(require 'package) +(add-to-list 'package-archives '("melpa" . "https://melpa.org/packages/")) +(add-to-list 'package-archives '("gnu" . "https://elpa.gnu.org/packages/") t) +(package-initialize) + +;; config +(custom-set-variables + '(font-use-system-font t) + '(package-selected-packages (quote (spacemacs-theme evil magit rust-mode cargo))) + '(semantic-mode t) + '(tool-bar-mode nil) +) + +;; theme +(load-theme 'spacemacs-dark t) + +;; rust foo +(add-hook 'rust-mode-hook 'cargo-minor-mode) + @@ -13,6 +13,7 @@ gToolsConfig=( "gitconfig:git:gitConfigInstaller" "tmux.conf:tmux:tmuxConfigInstaller" "vimrc:vim:vimConfigInstaller" +"emacs:emacs:emacsInstaller" "Xresources:xterm:xtermConfigInstaller" "i3config:i3:i3ConfigInstaller" "i3status:i3status:i3statusConfigInstaller" @@ -126,6 +127,22 @@ function vimConfigInstaller() { } #}}} +#{{{ emacsInstaller + +function emacsInstaller() { + local emacsrc=~/.emacs + touch $emacsrc + grep $gMagicNumber $emacsrc > /dev/null 2>&1 + if [[ $? = 0 ]]; then + return 1 + fi + echo -e "\n;; $gMagicNumber - Auto generated, do not delete or modify!" >> $emacsrc + echo -e "(load \"$ABS_BASE_DIR/emacs\")" >> $emacsrc + echo -e "(require 'johannst)" >> $emacsrc + return 0 +} + +#}}} #{{{ xtermConfigInstaller function xtermConfigInstaller() { diff --git a/install.config b/install.config index cdcffa0..67b7bdb 100644 --- a/install.config +++ b/install.config @@ -10,6 +10,7 @@ n - conkyrc n - gitconfig n - tmux.conf n - vimrc +n - emacs n - Xresources n - i3config n - i3status |