From c6d6246e3f346e1e5a3b327df714fcc73ad7e2fd Mon Sep 17 00:00:00 2001 From: Taylor Bockman Date: Wed, 18 Nov 2015 16:18:06 -0800 Subject: [PATCH] Make changes towards IRC capabilities in emacs --- dotfiles/emacs.d/init.el | 26 +++++++++++++++++++++++++- dotfiles/emacs.d/package.el | 2 +- dotfiles/emacs.d/sample-private.el | 32 ++++++++++++++++++++++++++++++++ dotfiles/zshrc | 4 ++-- 4 files changed, 60 insertions(+), 4 deletions(-) create mode 100644 dotfiles/emacs.d/sample-private.el diff --git a/dotfiles/emacs.d/init.el b/dotfiles/emacs.d/init.el index f664aa4..b2914e0 100644 --- a/dotfiles/emacs.d/init.el +++ b/dotfiles/emacs.d/init.el @@ -6,7 +6,8 @@ ;; - For stuff that requires privacy (such as ERC, Circe, or Email) place them in ;; a .private.el file in your home directory. This script will load that file. ;; This is the best way I could think of protecting sensitive data without making -;; it incredibly inconvenient for you. +;; it incredibly inconvenient for you. Take a look at the sample private.el in +;; the emacs.d folder (currently a work in progress). ;; ;;-------------------------------------------------------------------------------------- @@ -99,6 +100,29 @@ ) ;;-------------------------------------------------------------------------------------- +;; Configure Circe +;;-------------------------------------------------------------------------------------- + +(setq circe-network-options 'irc-servers) +(setq circe-use-cycle-completion t) +(setq helm-mode-no-completion-in-region-in-modes + '(circe-channel-mode + circe-query-mode + circe-server-mode + ) +) + +(setq circe-reduce-lurker-spam t) +(setq circe-set-display-handler "JOIN" (lambda (&rest ignored) nil)) ;; Hide JOIN spam + +(add-hook 'circe-chat-mode-hook 'my-circe-prompt) +(defun my-circe-prompt () + (lui-set-prompt + (concat (propertize (concat (buffer-name) ">") + 'face 'circe-prompt-face) + " "))) + +;;-------------------------------------------------------------------------------------- ;; Enable ParEdit for Emacs lisp modes ;;-------------------------------------------------------------------------------------- diff --git a/dotfiles/emacs.d/package.el b/dotfiles/emacs.d/package.el index 30dd750..c535023 100644 --- a/dotfiles/emacs.d/package.el +++ b/dotfiles/emacs.d/package.el @@ -1,6 +1,6 @@ (require 'cl) -(defvar my-packages '(ag auto-complete clojure-mode coffee-mode css-mode framemove flycheck +(defvar my-packages '(ag auto-complete clojure-mode coffee-mode css-mode circe framemove flycheck fill-column-indicator flycheck-clojure flycheck-haskell flycheck-rust flycheck-pos-tip gitignore-mode haskell-mode helm helm-ag helm-projectile js2-mode less-css-mode magit neotree paredit scss-mode powerline projectile diff --git a/dotfiles/emacs.d/sample-private.el b/dotfiles/emacs.d/sample-private.el new file mode 100644 index 0000000..15e16c8 --- /dev/null +++ b/dotfiles/emacs.d/sample-private.el @@ -0,0 +1,32 @@ +;;------------------------------------------------------------------- +;; Sample private.el +;; +;; Base your private.el off of this if you want an easier time +;; setting things up. +;; +;;------------------------------------------------------------------- + + +;; Circe Configuration +(defvar irc-username "") +(defvar irc-password "") + +(defvar irc-servers '( + ( + "Freenode" + :nick "Your nick" + :channels ("channel1" "channel2") + :nickserv-password irc-password + :port port + :tls t + ) + ) +) + +(defvar default-real-name "Real Name") + +;; Email Configuration + + + +;; Usenet Configuration diff --git a/dotfiles/zshrc b/dotfiles/zshrc index 2374267..0a08412 100644 --- a/dotfiles/zshrc +++ b/dotfiles/zshrc @@ -2,7 +2,7 @@ export ZSH=~/.oh-my-zsh export LC_ALL=en_US.UTF-8 export LANG=en_US.UTF-8 -export VISUAL=vim +export VISUAL="emacs -nw" export EDITOR="$VISUAL" export ITERM_24BIT=1 export TERM=xterm-256color @@ -67,7 +67,7 @@ PROMPT="%{$fg[white]%}┌%{$reset_color%}[%{$fg[yellow]%}%n%{$reset_color%}@%{$f # NOTE: 'Whence' is the ZSH idiom for bash's 'type' export PRENPMPATH=$PATH -if [ -n "$(whence -f npm)" ]; +if [ -n "$(whence -f npm)" ]; then NPMPATH="$(npm bin)"