 
 (add-to-list 'auto-mode-alist '("\\.js\\'" . js2-mode))
 
+;; rust
+(add-to-list 'auto-mode-alist '("\\.rs\\'" . rust-mode))
+(add-hook 'flycheck-mode-hook #'flycheck-rust-setup)
+(setq rust-format-on-save t)
+
 (custom-set-variables
  ;; custom-set-variables was added by Custom.
  ;; If you edit it by hand, you could mess it up, so be careful.

 '(js2-bounce-indent-p t)
 '(package-selected-packages
   (quote
    (tide yari yaml-mode web-mode wakatime-mode use-package tidy smartparens slime scss-mode rw-hunspell ruby-electric ruby-block php-extras php-auto-yasnippets php+-mode multiple-cursors markdown-toc less-css-mode key-chord jsx-mode jade-mode inf-ruby highlight-chars go-mode flymake-ruby flymake-phpcs flymake-php flymake-json flymake-jslint flymake-jshint flycheck fish-mode feature-mode exec-path-from-shell emr column-enforce-mode coffee-mode auctex ac-js2 ac-c-headers))))

;; wakatime
(setq wakatime-api-key "2579cd0a-ac6b-4065-85f4-c1c2116d360a")
(setq wakatime-cli-path "/usr/local/bin/wakatime")
(setq wakatime-python-bin "/usr/local/bin/python")

;;;;;;;;;;;;;;;;;;
;; KEY BINDINGS ;;

(setq ac-use-menu-map t)
(setq-default fill-column 80) ;; 80 character rule

;; smex setup
  (smex-initialize) ; Can be omitted. This might cause a (minimal) delay
                    ; when Smex is auto-initialized on its first run.
(global-set-key (kbd "M-x") 'smex)
  (global-set-key (kbd "M-X") 'smex-major-mode-commands)
  ;; This is your old M-x.
  (global-set-key (kbd "C-c C-c M-x") 'execute-extended-command)

;; expand region
(global-set-key (kbd "C-=") 'er/expand-region)

;; slime setup
(load (expand-file-name "~/quicklisp/slime-helper.el"))
(setq inferior-lisp-program "/usr/local/bin/sbcl")
