From bf98cb1ef36abf715ab7948955727fd933b5b5c0 Mon Sep 17 00:00:00 2001 From: Taylor Bockman Date: Mon, 28 May 2018 13:25:11 -0700 Subject: [PATCH 01/12] Update README.md --- README.md | 57 --------------------------------------------------------- 1 file changed, 57 deletions(-) diff --git a/README.md b/README.md index 516d6a5..7216541 100644 --- a/README.md +++ b/README.md @@ -17,60 +17,3 @@ The directory structure is as follows: Take care with the dotfiles. My configurations change the terminal colors to be solarized dark. If you do not like them they can be easily changed in the Xresources dotfile. - -# Issues - -There are of course a things that aren't covered (yet). - -1. Thinkpad T440s function keys don't work (in the works) -2. Thinkpad T440s mousepad right-click and gestures do not work -3. No automated way to setup locker -4. No automated way to setup suspend on lid close -5. No chef script to do everything for you -6. Rustc - local libs aren't initially visible - 1. Rustc requires you to manually enter sudo ldconfig /usr/local/lib once so that it can find its libraries - -# Software To Install - -Below is a not a comprehensive list of software you should install and configure. The *install_packages.sh* script is -a work in progress that will get the system up and running with everything I am using. - - -## Package Management -1. Yaourt - -## Wallpaper -1. Feh - -In order to install wallpapers properly, the xinitrc in this repository includes a line to start a task in the -background to show the wallpaper. If you use sh instead of zsh, change it appropriately. - -## Terminal -1. rxvt-unicode-256color - -## Display -1. xorg -2. xorg-xinit -3. i3 - -## Screen Locking -1. Physlock - -## Fonts -1. infinality-bundle -2. ibfonts-meta-base -3. ttf-inconsolata (for the terminal) - -## Mousepad -1. Synaptic - -## Editing -1. GVim - -## Browsing -1. Google Chrome - - -# Neovim Configuration Notes - -1. Make sure to run `:GoInstallBinaries` if you want to use `vim-go`. Make sure Go and `$GOPATH` are available. From 61bdb7338548ccd3f7a497cf0e9dd0540eb0d8ca Mon Sep 17 00:00:00 2001 From: Taylor Bockman Date: Mon, 28 May 2018 13:25:24 -0700 Subject: [PATCH 02/12] Update README.md --- README.md | 3 --- 1 file changed, 3 deletions(-) diff --git a/README.md b/README.md index 7216541..8feed5c 100644 --- a/README.md +++ b/README.md @@ -14,6 +14,3 @@ The directory structure is as follows: 5. *scripts/diagnostics/* - This directory contains scripts for helping to diagnose problems 3. *installation_instructions* - This file contains a series of command you copy and paste during install of Arch 4. *nix/* - This contains all the stuff needed to get up and running with my nix configuration - -Take care with the dotfiles. My configurations change the terminal colors to be solarized dark. If you do not like them -they can be easily changed in the Xresources dotfile. From ac69098ac1a92b505db9cf5fba0c0b6b314062ac Mon Sep 17 00:00:00 2001 From: angrygoats Date: Tue, 29 May 2018 10:42:45 -0700 Subject: [PATCH 03/12] Minor changes to emacs.d to support yaml/magit better --- dotfiles/emacs.d/init.el | 7 ++++--- dotfiles/emacs.d/package.el | 1 + 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/dotfiles/emacs.d/init.el b/dotfiles/emacs.d/init.el index 4436abb..3e6b420 100644 --- a/dotfiles/emacs.d/init.el +++ b/dotfiles/emacs.d/init.el @@ -99,14 +99,15 @@ setq org-log-done t) (filename . "emacs.d"))) ("Org" (or (mode . org-mode) (filename . "OrgMode"))) - ("Magit" (name . "\*magit\*")) + ("Magit" (name . "^\\*magit\\*")) ("Help" (or (name . "\*Help\*") (name . "\*Apropos\*") (name . "\*info\*"))) ("Dired" (mode . dired-mode)) ;; Dev has groups for all languages you program in - ("Dev" (or (mode . cc-mode)) - ) + ("Dev" (or (mode . cc-mode) + (mode . yaml-mode)) + ) ("Emacs" (or (name . "^\\*scratch\\*$") (name . "^\\*Messages\\*$"))) ("Gnus" (or (mode . message-mode) diff --git a/dotfiles/emacs.d/package.el b/dotfiles/emacs.d/package.el index 8840ee2..e0aaae0 100644 --- a/dotfiles/emacs.d/package.el +++ b/dotfiles/emacs.d/package.el @@ -2,6 +2,7 @@ (defvar my-packages '(ag auto-complete cc-mode + yaml-mode markdown-mode counsel expand-region From d8cba86c24d1d0628f5fbea7d782ce0292a82af4 Mon Sep 17 00:00:00 2001 From: angrygoats Date: Tue, 29 May 2018 22:06:50 -0700 Subject: [PATCH 04/12] clean up buffers --- dotfiles/emacs.d/init.el | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/dotfiles/emacs.d/init.el b/dotfiles/emacs.d/init.el index 3e6b420..aee90a4 100644 --- a/dotfiles/emacs.d/init.el +++ b/dotfiles/emacs.d/init.el @@ -99,13 +99,16 @@ setq org-log-done t) (filename . "emacs.d"))) ("Org" (or (mode . org-mode) (filename . "OrgMode"))) - ("Magit" (name . "^\\*magit\\*")) + ("Magit" (name . "magit")) ("Help" (or (name . "\*Help\*") (name . "\*Apropos\*") (name . "\*info\*"))) ("Dired" (mode . dired-mode)) ;; Dev has groups for all languages you program in ("Dev" (or (mode . cc-mode) + (filename . ".c") + (filename . ".h") + (filename . ".am") (mode . yaml-mode)) ) ("Emacs" (or (name . "^\\*scratch\\*$") From 808ac6d76ccc2ce57889ed0ade0ac67303c294fc Mon Sep 17 00:00:00 2001 From: Taylor Bockman Date: Wed, 30 May 2018 08:32:41 -0700 Subject: [PATCH 05/12] Add some java support to ibuffer --- dotfiles/emacs.d/init.el | 3 +++ 1 file changed, 3 insertions(+) diff --git a/dotfiles/emacs.d/init.el b/dotfiles/emacs.d/init.el index b646540..72e1acc 100644 --- a/dotfiles/emacs.d/init.el +++ b/dotfiles/emacs.d/init.el @@ -109,6 +109,9 @@ setq org-log-done t) ("Dev" (or (mode . cc-mode) (filename . ".c") (filename . ".h") + (filename . ".java") + (filename . ".properties") + (filename . ".gradle") (filename . ".am") (mode . yaml-mode)) ) From 3032b855b43f4b3ca96e48617e2170ad8d0ce298 Mon Sep 17 00:00:00 2001 From: Taylor Bockman Date: Wed, 30 May 2018 09:12:11 -0700 Subject: [PATCH 06/12] Add text section to ibuffer --- dotfiles/emacs.d/init.el | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/dotfiles/emacs.d/init.el b/dotfiles/emacs.d/init.el index 72e1acc..d2522c1 100644 --- a/dotfiles/emacs.d/init.el +++ b/dotfiles/emacs.d/init.el @@ -100,7 +100,6 @@ setq org-log-done t) ("Org" (or (mode . org-mode) (filename . "OrgMode"))) ("Magit" (name . "magit")) - ("Help" (or (name . "\*Help\*") (name . "\*Apropos\*") (name . "\*info\*"))) @@ -114,7 +113,12 @@ setq org-log-done t) (filename . ".gradle") (filename . ".am") (mode . yaml-mode)) - ) + ) + ("Text" (or (filename . ".csv") + (filename . ".tsv") + (filename . ".txt") + (filename . ".log"))) + ("Emacs" (or (name . "^\\*scratch\\*$") (name . "^\\*Messages\\*$"))) ("Gnus" (or (mode . message-mode) From 1cee6970487ec5a023a7d5108f35915c05f30105 Mon Sep 17 00:00:00 2001 From: Taylor Bockman Date: Wed, 30 May 2018 10:30:50 -0700 Subject: [PATCH 07/12] Clean up files, fix CC-mode, add eclim to java mode --- dotfiles/emacs.d/init.el | 44 +++++++++++++++++++++-------- dotfiles/emacs.d/package.el | 68 +++++++++++++++++++++++++++++---------------- 2 files changed, 76 insertions(+), 36 deletions(-) diff --git a/dotfiles/emacs.d/init.el b/dotfiles/emacs.d/init.el index d2522c1..8cac2c0 100644 --- a/dotfiles/emacs.d/init.el +++ b/dotfiles/emacs.d/init.el @@ -49,7 +49,7 @@ (setq Inhibit-Splash-Screen t) ;;-------------------------------------------------------------------------------------- -;; Prefer Utf-8 For Buffers +;; Prefer UTF-8 For Buffers ;;-------------------------------------------------------------------------------------- (prefer-coding-system 'utf-8) @@ -241,17 +241,6 @@ setq org-log-done t) (require 'expand-region) (pending-delete-mode t) ; Selected region contents are replaced on typing -;;-------------------------------------------------------------------------------------- -;; CC-Mode Settings -;;------------------------------------------------------------------------------------- - -;; Keep character limit to 80 -(eval-after-load "c" - '(progn - (setq fci-rule-column 80))) - -(setq-default c-basic-offset 4) ;; NASA Style Guide says 4 spaces is optimal -(setq-default c-default-style "linux") ;; Use Linux code style ;;-------------------------------------------------------------------------------------- ;; Line Numbering - Note: Might not look good with files with 10,000 or more lines @@ -320,6 +309,12 @@ setq org-log-done t) (sh-set-shell "zsh")))) ;;------------------------------------------------------------------------------------- +;; Enable and Configure `company-mode` +;;------------------------------------------------------------------------------------ + +(add-hook 'after-init-hook 'global-company-mode) + +;;------------------------------------------------------------------------------------- ;; Alignment ;;------------------------------------------------------------------------------------- @@ -374,6 +369,31 @@ setq org-log-done t) (setq deactivate-mark nil)) (self-insert-command N))) +;;-------------------------------------------------------------------------------------- +;; CC-Mode Settings +;;------------------------------------------------------------------------------------- + +;; Keep character limit to 80 +(eval-after-load "c-mode" + '(progn + (setq fci-rule-column 80))) + +(setq-default c-basic-offset 4) ;; NASA Style Guide says 4 spaces is optimal +(setq-default c-default-style "linux") ;; Use Linux code style + +;;-------------------------------------------------------------------------------------- +;; Java Mode Setup +;;------------------------------------------------------------------------------------- + +(defun my-java-mode-hook () + (require 'eclim) + (eclim-mode t) + (require 'company-emacs-eclim) + (company-emacs-eclim-setup) + ) + +(add-hook 'java-mode-hook 'my-java-mode-hook) + ;;------------------------------------------------------------------------------------- ;; Key Bindings ;;------------------------------------------------------------------------------------- diff --git a/dotfiles/emacs.d/package.el b/dotfiles/emacs.d/package.el index e0aaae0..4c960ee 100644 --- a/dotfiles/emacs.d/package.el +++ b/dotfiles/emacs.d/package.el @@ -1,29 +1,49 @@ (require 'cl) -(defvar my-packages '(ag auto-complete - cc-mode - yaml-mode - markdown-mode - counsel - expand-region - flycheck - grizzl - fill-column-indicator - feature-mode - flycheck-pos-tip - gitignore-mode - golden-ratio - swiper - linum-relative - magit - neotree - paredit - smex - powerline - projectile - wrap-region - rainbow-delimiters - zenburn-theme) +(defvar my-packages '(ag + ;; Completion Frameworks + company + eclim + irony + counsel + swiper + ;;;;;;;;;;;;;;;;;;;;;;;; + + ;; Programming modes + cc-mode + yaml-mode + markdown-mode + gitignore-mode + feature-mode + paredit + magit + ;;;;;;;;;;;;;;;;;;;; + + ;; Navigation + neotree + ;;;;;;;;;;;;; + + ;; UI + fill-column-indicator + golden-ratio + linum-relative + powerline + rainbow-delimiters + zenburn-theme + wrap-region + expand-region + wrap-region + ;;;;; + + ;; Project Interaction/Search/Syntax + flycheck + flycheck-pos-tip + grizzl + smex + projectile + ;;;;;;;;;;;;;;;;;;;;;;;;;;;;; + + ) "Packages to make sure are installed") (defun my-packages-installed-p () From 4726a9bce64bd0117324b8e9d7b6f220d55cb97f Mon Sep 17 00:00:00 2001 From: Taylor Bockman Date: Wed, 30 May 2018 11:08:50 -0700 Subject: [PATCH 08/12] Get rid of autocomplete enitrely from emacs --- dotfiles/emacs.d/init.el | 18 ------------------ 1 file changed, 18 deletions(-) diff --git a/dotfiles/emacs.d/init.el b/dotfiles/emacs.d/init.el index 8cac2c0..ef6a3a9 100644 --- a/dotfiles/emacs.d/init.el +++ b/dotfiles/emacs.d/init.el @@ -282,24 +282,6 @@ setq org-log-done t) (setq projectile-completion-system 'grizzl) ;;------------------------------------------------------------------------------------- -;; Use Grizzl with Projectile -;;------------------------------------------------------------------------------------- - -(setq projectile-completion-system 'grizzl) - - -;;------------------------------------------------------------------------------------- -;; Enable Autocomplete -;; -;; NOTE: You can replace the 't' in (setq ac-auto-start t) with a positive integer -;; to trigger autocompletion only after that number of characters. This will -;; improve performance on slower systems. -;;------------------------------------------------------------------------------------- - -(global-auto-complete-mode t) -(setq ac-auto-start t) - -;;------------------------------------------------------------------------------------- ;; ZSH script detection ;;------------------------------------------------------------------------------------ From 3954cd16efac84465badd4b51cf3403ea1258049 Mon Sep 17 00:00:00 2001 From: angrygoats Date: Wed, 30 May 2018 12:14:39 -0700 Subject: [PATCH 09/12] update gitingore again... --- .gitignore | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/.gitignore b/.gitignore index d4363db..3e0780b 100644 --- a/.gitignore +++ b/.gitignore @@ -36,16 +36,19 @@ autoload/ npm-debug.log -dotfiles/config/configstore/update-notifier-nodemon.json +/dotfiles/config/configstore/update-notifier-nodemon.json -dotfiles/config/yarn +/dotfiles/config/yarn -dotfiles/emacs.d/network-security.data +/dotfiles/emacs.d/network-security.data -dotfiles/emacs.d/recentf +/dotfiles/emacs.d/recentf # Wireshark temporary files -dotfiles/config/wireshark/recent -dotfiles/config/wireshark/dfilters -dotfiles/config/wireshark/recent_common +/dotfiles/config/wireshark/recent +/dotfiles/config/wireshark/dfilters +/dotfiles/config/wireshark/recent_common + + + From 4526fded02bb98451af9c43a4cd53b741cb52dbf Mon Sep 17 00:00:00 2001 From: angrygoats Date: Wed, 30 May 2018 12:33:23 -0700 Subject: [PATCH 10/12] Stuff for irony --- .gitignore | 8 +++++--- dotfiles/emacs.d/init.el | 2 ++ 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index 3e0780b..fa54c66 100644 --- a/.gitignore +++ b/.gitignore @@ -29,6 +29,8 @@ helm-adaptive-history /smex-save-file /recentf +*/emacs.d/irony/* + # nvim specific plugged bundle/** @@ -45,9 +47,9 @@ npm-debug.log /dotfiles/emacs.d/recentf # Wireshark temporary files -/dotfiles/config/wireshark/recent -/dotfiles/config/wireshark/dfilters -/dotfiles/config/wireshark/recent_common +*/dotfiles/config/wireshark/recent +*/dotfiles/config/wireshark/dfilters +*/dotfiles/config/wireshark/recent_common diff --git a/dotfiles/emacs.d/init.el b/dotfiles/emacs.d/init.el index ef6a3a9..a5a7c3e 100644 --- a/dotfiles/emacs.d/init.el +++ b/dotfiles/emacs.d/init.el @@ -363,6 +363,8 @@ setq org-log-done t) (setq-default c-basic-offset 4) ;; NASA Style Guide says 4 spaces is optimal (setq-default c-default-style "linux") ;; Use Linux code style +(add-hook 'c-mode-hook 'irony-mode) + ;;-------------------------------------------------------------------------------------- ;; Java Mode Setup ;;------------------------------------------------------------------------------------- From a11e9ba517690eef73c102ec9d972ccae8162512 Mon Sep 17 00:00:00 2001 From: angrygoats Date: Wed, 30 May 2018 12:37:20 -0700 Subject: [PATCH 11/12] notes --- README.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/README.md b/README.md index 8feed5c..44b9f1b 100644 --- a/README.md +++ b/README.md @@ -14,3 +14,10 @@ The directory structure is as follows: 5. *scripts/diagnostics/* - This directory contains scripts for helping to diagnose problems 3. *installation_instructions* - This file contains a series of command you copy and paste during install of Arch 4. *nix/* - This contains all the stuff needed to get up and running with my nix configuration + +## Emacs Specific Things + +Before programming C, install `global` and `libclang` in your distro. After doing that, run `M-x irony-install-server` to install the server in the emacs directory. +Finally, `cd` to the root of your project and run `gtags`. You now have functioning irony C completion. + +Before programming Java, install `eclim`, and `eclipse`. From 201bb863f690288138580f7f08e421a9c937f1b2 Mon Sep 17 00:00:00 2001 From: angrygoats Date: Wed, 30 May 2018 12:40:52 -0700 Subject: [PATCH 12/12] Add some c mode stuff --- dotfiles/emacs.d/init.el | 9 +++++++++ dotfiles/emacs.d/package.el | 1 + 2 files changed, 10 insertions(+) diff --git a/dotfiles/emacs.d/init.el b/dotfiles/emacs.d/init.el index a5a7c3e..1deb76b 100644 --- a/dotfiles/emacs.d/init.el +++ b/dotfiles/emacs.d/init.el @@ -296,6 +296,8 @@ setq org-log-done t) (add-hook 'after-init-hook 'global-company-mode) + + ;;------------------------------------------------------------------------------------- ;; Alignment ;;------------------------------------------------------------------------------------- @@ -365,6 +367,13 @@ setq org-log-done t) (add-hook 'c-mode-hook 'irony-mode) +;; Backend for Company +(defun my-c-mode-hook () + (eval-after-load 'company + '(add-to-list 'company-backends 'company-irony))) + +(add-hook 'c-mode-hook 'my-c-mode-hook) + ;;-------------------------------------------------------------------------------------- ;; Java Mode Setup ;;------------------------------------------------------------------------------------- diff --git a/dotfiles/emacs.d/package.el b/dotfiles/emacs.d/package.el index 4c960ee..fba1851 100644 --- a/dotfiles/emacs.d/package.el +++ b/dotfiles/emacs.d/package.el @@ -3,6 +3,7 @@ (defvar my-packages '(ag ;; Completion Frameworks company + company-irony eclim irony counsel