Skip to content

Commit

Permalink
Refactoring
Browse files Browse the repository at this point in the history
  • Loading branch information
ncaq committed Jan 13, 2014
1 parent cd41fcc commit 511b5b6
Show file tree
Hide file tree
Showing 30 changed files with 87 additions and 95 deletions.
2 changes: 1 addition & 1 deletion profile.d/00_disable.el
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
;;http://blog.goo.ne.jp/shihei_1951/e/cc8be74e8f330bb59539b30e4a234883
;; 起動時の画面はいらない
;;起動時の画面はいらない
(setq inhibit-startup-message t)

(add-hook 'after-find-file (lambda ()(abbrev-mode nil)));auto-complete.el使うからいらない
Expand Down
Binary file modified profile.d/00_disable.elc
Binary file not shown.
5 changes: 5 additions & 0 deletions profile.d/02_etc.el
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,12 @@
(fset 'yes-or-no-p 'y-or-n-p);"yes or no"を"y or n"に
(savehist-mode t);ミニバッファの履歴を保存する

(setq delete-by-moving-to-trash t);ごみ箱を有効
(setq history-length 5000);ミニバッファの履歴の保存数を増やす
(setq message-log-max 5000);ログの記録行数を増やす.
(setq next-line-add-newlines t);c-nした時に行を追加
(setq read-buffer-completion-ignore-case t) ;;大文字と小文字を区別しない バッファ名
(setq read-file-name-completion-ignore-case t) ;; ファイル名
(setq user-mail-address "nyrigadake38@gmail.com")
(setq x-select-enable-clipboard t);クリップボードをX11と共有
(setq-default indent-tabs-mode t);インデントをタブでする
Binary file modified profile.d/02_etc.elc
Binary file not shown.
27 changes: 27 additions & 0 deletions profile.d/10_buffer.el
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
;;フォント
(set-face-attribute 'default nil
:family "Ricty"
:height 180)

(auto-image-file-mode);画像表示

;;package-listのformat
(define-derived-mode package-menu-mode tabulated-list-mode "Package Menu"
"Major mode for browsing a list of packages.
Letters do not insert themselves; instead, they are commands.
\\<package-menu-mode-map>
\\{package-menu-mode-map}"
(setq tabulated-list-format [("Package" 35 package-menu--name-predicate)
("Version" 15 package-menu--version-predicate)
("Status" 10 package-menu--status-predicate)
("Description" 10 package-menu--description-predicate)])
(setq tabulated-list-padding 1)
(setq tabulated-list-sort-key (cons "Status" nil))
(tabulated-list-init-header))

;;ibufferのformat
(require 'ibuffer)
(setq ibuffer-formats
'((mark modified read-only " " (name 60 30)
" " (size 6 -1) " " (mode 16 16) " " filename)
(mark " " (name 60 -1) " " filename)))
Binary file renamed profile.d/10_ui.elc → profile.d/10_buffer.elc
Binary file not shown.
3 changes: 1 addition & 2 deletions profile.d/10_color.el
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
(global-font-lock-mode 1);syntax highlight有効
(show-paren-mode t);対応する括弧をハイライト

(require 'solarized-dark-theme)
(load-theme 'solarized-dark t)
Expand All @@ -17,8 +18,6 @@
(ad-enable-advice 'font-lock-mode 'before 'ncaq-font-lock-mode)
(ad-activate 'font-lock-mode)

(show-paren-mode t);対応する括弧をハイライト

(require 'rainbow-delimiters)
(global-rainbow-delimiters-mode t)
(custom-set-faces '(rainbow-delimiters-depth-1-face ((t (:foreground "#7f8c8d")))));文字列の色と被るため,変更
Binary file modified profile.d/10_color.elc
Binary file not shown.
29 changes: 29 additions & 0 deletions profile.d/10_toolkit.el
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
(menu-bar-mode 0);menu bar を表示させない
(tool-bar-mode 0);tool bar を表示させない
(setq frame-title-format (format "%%b"));タイトルバーにバッファ名を表示する

;;mode-lineに改行コードを表示
(setq eol-mnemonic-dos "(CRLF)")
(setq eol-mnemonic-mac "(CR)")
(setq eol-mnemonic-unix "(LF)")

;;フルパスを表示
(set-default 'mode-line-buffer-identification
'(buffer-file-name ("%f") ("%b")))

(require 'linum);;行番号を左に表示
(require 'auto-complete)
(global-linum-mode)
;;auto-complete時に崩れる問題を修正
(defadvice linum-update
(around tung/suppress-linum-update-when-popup activate)
(unless (ac-menu-live-p)
ad-do-it))
;;軽くする
;;http://d.hatena.ne.jp/daimatz/20120215/1329248780
(setq linum-delay t)
(defadvice linum-schedule (around my-linum-schedule () activate)
(run-with-idle-timer 0.2 nil #'linum-update-current))

(require 'uniquify);;バッファの名前がかぶったらディレクトリ名もつける
(setq uniquify-buffer-name-style 'forward)
Binary file added profile.d/10_toolkit.elc
Binary file not shown.
44 changes: 0 additions & 44 deletions profile.d/10_ui.el

This file was deleted.

1 change: 1 addition & 0 deletions profile.d/20_dired.el
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
(require 'dired)
(setq dired-listing-switches "-AFhvl");diredが使うlsオプションの設定

;;atoolの設定
Expand Down
Binary file modified profile.d/20_dired.elc
Binary file not shown.
12 changes: 0 additions & 12 deletions profile.d/20_file.el

This file was deleted.

Binary file removed profile.d/20_file.elc
Binary file not shown.
6 changes: 3 additions & 3 deletions profile.d/20_function.el
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
;;小さい自作関数
(fset 'through-newline
[end return])

(defun kill-all-buffers ()
"バッファ全部閉じる"
(interactive)
Expand Down Expand Up @@ -30,9 +33,6 @@
"*a.out*"
(concat current-dir "/a.out")))

(fset 'through-newline
[end return])

(require'text-adjust)
(defun text-adjust-selective ()
"text-adjustは色々やりすぎる"
Expand Down
Binary file modified profile.d/20_function.elc
Binary file not shown.
8 changes: 0 additions & 8 deletions profile.d/20_mode-line.el

This file was deleted.

Binary file removed profile.d/20_mode-line.elc
Binary file not shown.
9 changes: 9 additions & 0 deletions profile.d/22_key-bind.el
Original file line number Diff line number Diff line change
@@ -1,11 +1,15 @@
(global-set-key (kbd "C-+") 'text-scale-increase)
(global-set-key (kbd "C-,") 'helm-for-files);C-xC-bは頻繁に打つにしてはめんどくさい
(global-set-key (kbd "C--") 'text-scale-decrease)
(global-set-key (kbd "C-;") 'align-regexp);揃える(正規表現)
(global-set-key (kbd "C-^") 'dired-jump-to-current)
(global-set-key (kbd "C-a") 'vs-move-beginning-of-line);;Visual StdioライクなC-a
(global-set-key (kbd "C-h") 'backward-delete-char-untabify)
(global-set-key (kbd "C-j") 'helm-ag);インクリメント串刺し検索
(global-set-key (kbd "C-m") 'newline-and-indent);改行時にインデント
(global-set-key (kbd "C-o") 'helm-buffers-list)
(global-set-key (kbd "C-q") 'kill-buffer-and-window);バッファとウインドウ閉じる
(global-set-key (kbd "C-t") 'other-window)
(global-set-key (kbd "C-u") 'kill-whole-line);現在行を削除
(global-set-key (kbd "C-z") 'quoted-insert);C-qの本来の関数

Expand All @@ -28,6 +32,11 @@
(global-set-key (kbd "M-z") 'repeat)

(global-set-key (kbd "C-M-d") 'kill-sexp)
(global-set-key (kbd "C-M-n") 'scroll-up-1)
(global-set-key (kbd "C-M-p") 'scroll-down-1)
(global-set-key (kbd "C-M-q") 'kill-buffer);バッファ閉じる

(global-set-key (kbd "C-M-S-q") 'kill-all-buffers);バッファを全て閉じる. まともに動かなくなるのですぐに終了すること

(global-set-key (kbd "C-x C-e") 'flycheck-list-errors)
(global-set-key (kbd "C-x C-f") 'save-buffer)
Expand Down
Binary file modified profile.d/22_key-bind.elc
Binary file not shown.
20 changes: 0 additions & 20 deletions profile.d/22_keyjack.el

This file was deleted.

Binary file removed profile.d/22_keyjack.elc
Binary file not shown.
5 changes: 0 additions & 5 deletions profile.d/50_ibuffer.el

This file was deleted.

Binary file removed profile.d/50_ibuffer.elc
Binary file not shown.
8 changes: 8 additions & 0 deletions profile.d/70_ext.el
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
(add-to-list 'auto-mode-alist '("\\.license\\'" . conf-mode));portage
(add-to-list 'auto-mode-alist '("\\.mask\\'" . conf-mode));portage
(add-to-list 'auto-mode-alist '("\\.unmask\\'" . conf-mode));portage
(add-to-list 'auto-mode-alist '("\\.use\\'" . conf-mode));portage
(add-to-list 'auto-mode-alist '("\\.zsh\\'" . shell-script-mode));zshのシェルスクリプトに対応

(require 'hexl)
(define-key hexl-mode-map (kbd "C-q") nil)
Binary file added profile.d/70_ext.elc
Binary file not shown.
3 changes: 3 additions & 0 deletions profile.d/90_require.el
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@
(smooth-scroll-mode t)
(setq smooth-scroll/vscroll-step-size 5);;デフォルトだと重い

(require 'auto-save-buffers);;本当の自動保存
(run-with-idle-timer 30 t 'auto-save-buffers)

;;_人人人人人人_
;;> 突然の死 <
;; ̄YYYYYY ̄
Expand Down
Binary file modified profile.d/90_require.elc
Binary file not shown.
Binary file modified universe.d/dired-sort.elc
Binary file not shown.

0 comments on commit 511b5b6

Please sign in to comment.