Minor changes
This commit is contained in:
9
init.el
9
init.el
@@ -5,12 +5,6 @@
|
|||||||
(interactive)
|
(interactive)
|
||||||
(byte-recompile-directory user-emacs-directory 0))
|
(byte-recompile-directory user-emacs-directory 0))
|
||||||
|
|
||||||
(defadvice find-file (after find-file-sudo activate)
|
|
||||||
"Find file as root if necessary."
|
|
||||||
(unless (and buffer-file-name
|
|
||||||
(file-writable-p buffer-file-name))
|
|
||||||
(find-alternate-file (concat "/sudo:root@localhost:" buffer-file-name))))
|
|
||||||
|
|
||||||
(load "~/.emacs.d/my-packages.el")
|
(load "~/.emacs.d/my-packages.el")
|
||||||
(byte-compile-init-dir)
|
(byte-compile-init-dir)
|
||||||
(load "~/.emacs.d/my-loadpackages.elc")
|
(load "~/.emacs.d/my-loadpackages.elc")
|
||||||
@@ -29,6 +23,9 @@
|
|||||||
;; If you edit it by hand, you could mess it up, so be careful.
|
;; If you edit it by hand, you could mess it up, so be careful.
|
||||||
;; Your init file should contain only one such instance.
|
;; Your init file should contain only one such instance.
|
||||||
;; If there is more than one, they won't work right.
|
;; If there is more than one, they won't work right.
|
||||||
|
'(custom-safe-themes
|
||||||
|
(quote
|
||||||
|
("16dd114a84d0aeccc5ad6fd64752a11ea2e841e3853234f19dc02a7b91f5d661" "f2dd097452b79276ce522df2f8aeb37f6d90f504529616aa46122d549910e46d" "21c6b494da74b10ff573fa96b6850651e321282daa17fc9d6c8fbbee96ade005" default)))
|
||||||
'(package-selected-packages
|
'(package-selected-packages
|
||||||
(quote
|
(quote
|
||||||
(jdee web-mode use-package-chords use-package projectile pkg-info less-css-mode ghc fill-column-indicator evil-magit evil epl diminish dash counsel bind-chord base16-theme async all-the-icons))))
|
(jdee web-mode use-package-chords use-package projectile pkg-info less-css-mode ghc fill-column-indicator evil-magit evil epl diminish dash counsel bind-chord base16-theme async all-the-icons))))
|
||||||
|
|||||||
@@ -105,29 +105,25 @@ can be used to add a number of spaces to the front and back of the string."
|
|||||||
`(:background ,(evil-tag-color) :family ,(funcall (car result)))))))
|
`(:background ,(evil-tag-color) :family ,(funcall (car result)))))))
|
||||||
|
|
||||||
(defun custom-modeline-mode-icon ()
|
(defun custom-modeline-mode-icon ()
|
||||||
(let ((icon (all-the-icons-icon-for-buffer)))
|
(let ((icon (all-the-icons-icon-for-buffer)))
|
||||||
(if (not (symbolp icon)) ;; This implies it's the major mode
|
(if (not (symbolp icon)) ;; This implies it's the major mode
|
||||||
(format " %s"
|
(format " %s"
|
||||||
(propertize
|
(propertize
|
||||||
icon
|
(all-the-icons-icon-for-buffer)
|
||||||
'face
|
'face
|
||||||
`(:height 1.0 :family ,(all-the-icons-icon-family-for-buffer))
|
`(:family ,(all-the-icons-icon-family-for-buffer))
|
||||||
'display '(raise 0.0)))
|
'display '(raise 0.0)))
|
||||||
(format " %s"
|
(format " %s"
|
||||||
(propertize
|
(propertize
|
||||||
""
|
""
|
||||||
'face
|
'face
|
||||||
`(:height 1.0 :family ,(all-the-icons-faicon-family))
|
`(:family ,(all-the-icons-faicon-family))
|
||||||
'display '(raise 0.0))))))
|
'display '(raise 0.0))))))
|
||||||
|
|
||||||
(defun line-count-line ()
|
(defun line-count-line ()
|
||||||
(let* ((bg (time-tag-bg-color))
|
(let* ((bg (time-tag-bg-color))
|
||||||
(fg (time-tag-fg-color)))
|
(fg (time-tag-fg-color)))
|
||||||
(concat
|
(concat
|
||||||
;; (propertize
|
|
||||||
;; (all-the-icons-faicon "rebel")
|
|
||||||
;; 'face
|
|
||||||
;; `(:height 0.8 :background ,bg :foreground ,fg) 'display '(raise 0.2))
|
|
||||||
(propertize
|
(propertize
|
||||||
(format " %%l/%d "
|
(format " %%l/%d "
|
||||||
(count-lines (point-min) (point-max)))
|
(count-lines (point-min) (point-max)))
|
||||||
@@ -135,8 +131,6 @@ can be used to add a number of spaces to the front and back of the string."
|
|||||||
|
|
||||||
(defun powerline-time ()
|
(defun powerline-time ()
|
||||||
(let* ((hour (string-to-number (format-time-string "%I")))
|
(let* ((hour (string-to-number (format-time-string "%I")))
|
||||||
;; (icon (all-the-icons-wicon
|
|
||||||
;; (format "time-%s" hour) :height 1.0 :v-adjust 0.0))
|
|
||||||
(bg (time-tag-bg-color))
|
(bg (time-tag-bg-color))
|
||||||
(fg (time-tag-fg-color)))
|
(fg (time-tag-fg-color)))
|
||||||
(concat
|
(concat
|
||||||
@@ -144,24 +138,21 @@ can be used to add a number of spaces to the front and back of the string."
|
|||||||
(format-time-string " %H:%M ")
|
(format-time-string " %H:%M ")
|
||||||
'face
|
'face
|
||||||
`(:height 1.0 :background ,bg :foreground ,fg))
|
`(:height 1.0 :background ,bg :foreground ,fg))
|
||||||
;; (propertize
|
|
||||||
;; (format "%s" icon)
|
|
||||||
;; 'face
|
|
||||||
;; `(:height 1.0 :family "Weather Icons" :background ,bg :foreground ,fg)
|
|
||||||
;; 'display '(raise -0.0))
|
|
||||||
(propertize
|
(propertize
|
||||||
"·"
|
"·"
|
||||||
'face `(:height 1.0 :background ,bg :foreground ,fg)))))
|
'face `(:height 1.0 :background ,bg :foreground ,fg)))))
|
||||||
|
|
||||||
(defvar separator-left
|
(defvar separator-left "")
|
||||||
(propertize
|
(defvar separator-right "")
|
||||||
""
|
;; (defvar separator-left
|
||||||
'face `(:height 1.1 :foreground "#86261c") 'display '(raise -0.0)))
|
;; (propertize
|
||||||
|
;; ""
|
||||||
|
;; 'face `(:height 1.1 :foreground "#86261c") 'display '(raise -0.0)))
|
||||||
|
|
||||||
(defvar separator-right
|
;; (defvar separator-right
|
||||||
(propertize
|
;; (propertize
|
||||||
""
|
;; " "
|
||||||
'face `(:height 1.1 :foreground "#86261c") 'display '(raise -0.0)))
|
;; 'face `(:height 1.1 :foreground "#86261c") 'display '(raise -0.0)))
|
||||||
|
|
||||||
(setq-default mode-line-format
|
(setq-default mode-line-format
|
||||||
(list
|
(list
|
||||||
@@ -175,7 +166,7 @@ can be used to add a number of spaces to the front and back of the string."
|
|||||||
(custom-modeline-mode-icon) ;; %m
|
(custom-modeline-mode-icon) ;; %m
|
||||||
" %b "))
|
" %b "))
|
||||||
;;center
|
;;center
|
||||||
" "
|
""
|
||||||
;; right
|
;; right
|
||||||
(format-mode-line
|
(format-mode-line
|
||||||
(concat
|
(concat
|
||||||
|
|||||||
Reference in New Issue
Block a user