1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
  2;;;;
  3;;;;           use packages
  4;;;;
  5;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
  6
  7(require 'package)
  8(setq package-check-signature nil)
  9(add-to-list 'package-archives
 10             '("melpa" . "https://melpa.org/packages/") t)
 11(package-initialize)
 12
 13(eval-when-compile
 14  (require 'use-package))
 15
 16;; (use-package package
 17;;   :init
 18;;   (add-to-list 'package-archives '("melpa" . "http://melpa.org/packages/"))
 19;;   :config
 20;;   (package-initialize))
 21
 22(use-package magit
 23  :init
 24  (setq magit-git-executable "c:/Program Files/Git/bin/git.exe"))
 25
 26(use-package exec-path-from-shell
 27  :config
 28  (when (memq window-system '(mac ns x))
 29    (exec-path-from-shell-initialize)))
 30
 31;; (setq shell-file-name "c:/prgms/msys2/mingw64.exe")
 32;; (setq explicit-bash-args '("--login"))
 33
 34(use-package company
 35  :init
 36  (setq company-minimum-prefix-length 3
 37	company-text-icons-add-background t
 38	company-tooltip-idle-delay 10
 39	company-tooltip-minimum-width 40
 40	company-tooltip-minimum 4
 41	company-show-numbers t
 42	company-idle-delay 0
 43	completion-ignore-case nil
 44	company-dabbrev-downcase nil
 45	company-text-face-extra-attributes '(:weight bold :slant italic)
 46	company-format-margin-function 'company-text-icons-margin)
 47  :config
 48  (global-company-mode)
 49  (define-key company-active-map (kbd "<tab>") #'company-complete-selection)
 50  (define-key company-active-map (kbd "C-n") #'company-select-next-or-abort)
 51  (define-key company-active-map (kbd "C-p") #'company-select-previous-or-abort))
 52
 53(use-package company-posframe
 54  :config
 55  (company-posframe-mode 1))
 56
 57;; (use-package company-box
 58;;   :no-require t
 59;;   :diminish company-box-mode
 60;;   :commands company-box-mode
 61;;   :custom-face
 62;;   :init
 63;;   (add-hook 'company-mode-hook 'company-box-mode))
 64
 65(use-package aggressive-indent
 66  :config
 67  (add-hook 'emacs-lisp-mode-hook #'aggressive-indent-mode))
 68
 69;; (add-hook 'dired-mode-hook 'all-the-icons-dired-mode)
 70;;(setq dired-mode-hook nil)
 71
 72(use-package ivy-prescient
 73  :config
 74  (setq prescient-history-length 30)
 75  (setq prescient-aggressive-file-save t)
 76  )
 77
 78(use-package auto-complete
 79  :init
 80  (setq ac-use-menu-map t)
 81  (setq ac-ignore-case t)
 82  (setq ac-auto-start 3)
 83  :config
 84  (define-key ac-completing-map "\C-n" 'ac-next)
 85  (define-key ac-completing-map "\C-p" 'ac-previous)
 86  (when (file-remote-p default-directory) (auto-complete-mode))
 87  (ac-linum-workaround))
 88
 89(use-package undo-tree
 90  :init
 91  (setq undo-tree-auto-save-history nil)
 92  (setq undo-tree-history-directory-alist '(("." . "~/.emacs.d/undo")))
 93  :config
 94  (global-undo-tree-mode))
 95
 96(use-package evil
 97  :init
 98  (setq evil-emacs-state-cursor '("black" box)
 99	evil-normal-state-cursor '("purple" box)
100	evil-visual-state-cursor '("orange" box)
101	evil-insert-state-cursor '("magenta" bar))
102  :config
103  (evil-mode 1)
104  (evil-set-initial-state 'magit-diff-mode 'motion)
105  (evil-set-undo-system 'undo-tree)
106  (define-key evil-normal-state-map (kbd "SPC") 'avy-goto-char-2)
107  (setq evil-emacs-state-modes (delq 'ibuffer-mode evil-emacs-state-modes))
108  (evil-define-key 'normal org-mode-map (kbd "<tab>") #'org-cycle))
109
110(use-package swiper
111  :init
112  (global-set-key "\C-s" 'swiper))
113
114(use-package counsel
115  :init
116  (global-set-key (kbd "C-x C-f") 'counsel-find-file)
117  (global-set-key (kbd "C-x C-r") 'counsel-recentf)
118  (global-set-key (kbd "M-x") 'counsel-M-x)
119  :config
120  (counsel-mode))
121
122(use-package ivy
123  :init
124  (setq ivy-count-format "(%d/%d) ")
125  (setq ivy-use-virtual-buffers t)
126  (setq ivy-extra-directories nil)
127  (setq ivy-height 10)
128  :config
129  (setq enable-recursive-minibuffers t)
130  (ivy-mode 1)
131  (global-set-key (kbd "C-x b") 'ivy-switch-buffer))
132
133;; (defun ivy-call-second-action ()
134;;   "Execute second action."
135;;   (interactive)
136;;   (let ((actions (cdr (ivy-state-action ivy-last))))
137;;     (if (<= (length actions) 1)
138;;         (error "Can't run second action, only %d actions available"
139;;                (length actions))
140;;       (ivy-exit-with-action
141;;        (nth 1 (nth 1 actions))))))
142
143;; (define-key ivy-minibuffer-map (kbd "<f2>") 'ivy-call-second-action)
144
145(use-package avy
146  :init
147  (setq avy-background t)
148  (setq avy-orders-alist
149	'((avy-goto-char . avy-order-closest)
150	  (avy-goto-word-0 . avy-order-closest))))
151
152(use-package helm
153  ;;:disabled
154  :no-require t
155  :init
156  (setq helm-recentf-fuzzy-match t)
157  (setq helm-buffers-fuzzy-matching t)
158  :config
159  ;; (global-set-key (kbd "C-x C-f") 'helm-find-files)
160  ;; (global-set-key (kbd "C-x C-r") 'helm-recentf)
161  ;; (global-set-key (kbd "M-x") 'helm-M-x)
162
163  ;;(global-set-key (kbd "C-x C-r") 'helm-recentf)
164  ;;(define-key helm-map (kbd "<tab>") 'helm-execute-persistent-action)
165  )
166
167(use-package rainbow-delimiters
168  :commands rainbow-delimiters-mode
169  :init
170  (add-hook 'prog-mode-hook #'rainbow-delimiters-mode))
171
172(use-package telephone-line
173  :init
174  (setq telephone-line-lhs
175		'((evil   . (telephone-line-evil-tag-segment))
176		  (accent . (telephone-line-vc-segment
177					 telephone-line-erc-modified-channels-segment
178					 telephone-line-process-segment))
179		  (nil    . (telephone-line-minor-mode-segment
180					 telephone-line-buffer-segment))))
181  (setq telephone-line-rhs
182		'((nil    . (telephone-line-misc-info-segment))
183		  (accent . (telephone-line-major-mode-segment))
184		  (evil   . (telephone-line-airline-position-segment))))
185
186  :config
187  (telephone-line-evil-config))
188
189
190(use-package org-superstar
191  :commands org-superstar-mode
192  :hook
193  (add-hook 'org-mode-hook org-superstar-mode))
194;;(add-hook 'org-mode-hook (lambda () (org-superstar-mode 1)))
195
196
197(use-package projectile
198  :config
199  (projectile-mode +1)
200  (define-key projectile-mode-map (kbd "C-c p") 'projectile-command-map))
201
202(use-package anzu
203  :config
204  (global-anzu-mode +1))
205
206(use-package org-tempo)
207
208(use-package sql-indent
209  :config
210  ;;(define-key map (kbd "M-=") #'align))
211  )
212
213
214(use-package diminish
215  :config
216  (diminish 'auto-fill-function)
217  (diminish 'projectile-mode)
218  (diminish 'company-mode)
219  (diminish 'company-posframe-mode)
220  (diminish 'ivy-mode)
221  (diminish 'eldoc-mode)
222  (diminish 'undo-tree-mode)
223  (diminish 'anzu-mode)
224  (diminish 'flyspell-mode)
225  (diminish 'counsel-mode)
226  (diminish 'company-box-mode)
227  (diminish 'sqlind-minor-mode)
228  (diminish 'auto-complete-mode))
229
230
231(use-package deft
232  ;; https://github.com/jrblevin/deft
233  ;; c-l
234  ;; c-c c-t toggle search
235  ;; c-c c-c to clear filter
236  ;; c-c c-l filter
237  ;; c-c c-g refresh deft
238  :bind ("<f8>" . deft)
239  :commands (deft)
240  :config
241  (setq deft-file-naming-rules
242	'((noslash . "-")
243	  (nospace . "-")
244	  (case-fn . upcase)))
245
246  (setq deft-extensions '("org" "md")
247	deft-directory "c:/Users/hzhang/notes/"
248	deft-use-filename-as-title t
249	deft-time-format " %Y-%m-%d %H:%M"
250	deft-recursive t)
251  (setq deft-window-width 70)
252
253  (setq deft-ignore-file-regexp "\\(tmp\\|prep-debrief\\|cheetsheet\\|readme\\)")
254
255  ;;(add-hook 'deft-mode-hook (lambda() (display-line-numbers-mode -1)))
256  )
257
258;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
259;;;;
260;;;;          end of use packages
261;;;;
262;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
263
264(use-package hz-mode
265  :load-path "~/.emacs.d/hz-mode/"
266  :config
267  (hz-mode 1))
268
269;;(require 'tramp)
270(use-package tramp
271  :config
272  (add-to-list 'tramp-remote-path 'tramp-own-remote-path)
273  (add-to-list 'tramp-remote-path "/usr/bin"))
274
275(use-package recentf
276  :init
277  (setq recentf-save-file "~/.emacs.d/.recentf")
278  (setq recentf-auto-cleanup 'never)
279  :config
280  (setq recentf-max-saved-items 100)
281  (recentf-mode 1)
282  (run-at-time nil (* 25 60) 'recentf-save-list))
283
284
285
286;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
287;;;;
288;;;;          some org mode setting
289;;;;
290;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
291
292
293(use-package org
294  :config
295  (setq org-agenda-deadline '((t (:foreground "red" :weight bold :background "yellow"))))
296  (setq org-agenda-scheduled '((t (:foreground "blue" :weight bold :background "yellow"))))
297  (setq org-agenda-deadline-today '((t (:foreground "red" :weight bold :background "yellow"))))
298  (setq org-agenda-scheduled-today '((t (:foreground "blue" :weight bold :background "yellow"))))
299  (setq org-agenda-deadline-future '((t (:foreground "red" :weight bold :background "yellow"))))
300  (setq org-agenda-scheduled-future '((t (:foreground "blue" :weight bold :background "yellow")))))
301
302
303(defun my/org-priority-faces-box ()
304  "Set custom faces for Org mode priorities."
305  (setq org-priority-faces '((?A . (:background "yellow" :foreground "red" :weight bold))
306                             (?B . (:background "lightgray" :foreground "black"))
307                             (?C . (:background "darkgray" :foreground "black")))))
308
309
310;; (defun my/org-priority-faces ()
311;;   "Set custom faces for Org mode priorities."
312;;   (font-lock-add-keywords
313;;    'org-mode
314;;    '(("^\\*+.*\\(\\[#A\\]\\).*"
315;;       (0 (progn (add-text-properties (match-beginning 0) (match-end 0)
316;;                                      '(face (:background "yellow" :foreground "black" :weight bold)))
317;;                 nil))))))
318
319;; (add-hook 'org-mode-hook 'my/org-priority-faces)
320
321(add-hook 'org-mode-hook 'my/org-priority-faces-box)
322
323(setq org-todo-keywords
324      '((sequence "IN-PRG" "TODO" "SHRE" "|" "PAUSE" "DONE")))
325
326(setq org-todo-keyword-faces
327      '(("IN-PRG" . "orange") ("SHRE" . "#0000ff") ("PAUSE" . "#6600ff")))
328
329;; (add-to-list 'org-agenda-custom-commands
330;; 	     '("w" "week-span"
331;;                ((agenda "" ))
332;;                (
333;; 		(org-agenda-overriding-header "My Week")
334;; 		(org-agenda-start-on-weekday nil)
335;; 		(org-agenda-span 10)
336;; 		(org-agenda-start-day "-3d")
337;; 		)) t)
338
339(setq org-agenda-custom-commands
340      '(("w" "hz-week-agenda"
341         ((agenda)
342          (tags "Today"
343		((org-agenda-sorting-strategy '(priority-up))))
344	  )
345	 ((org-agenda-overriding-header "*My week")
346	  (org-agenda-start-on-weekday nil)
347	  (org-agenda-span 15)
348	  (org-agenda-start-day "-3d"))
349         ((org-agenda-sorting-strategy '(priority-down))))))
350
351
352(defun my/modify-org-done-face ()
353  (setq org-fontify-done-headline t)
354  (set-face-attribute 'org-done nil :strike-through t)
355  (set-face-attribute 'org-headline-done nil
356                      :strike-through t
357                      :foreground "light gray"))
358
359
360(setq org-use-sub-superscripts nil)
361
362(setq org-auto-align-tags nil
363      org-tags-column 0
364      org-catch-invisible-edits 'show-and-error
365      org-special-ctrl-a/e t
366      org-insert-heading-respect-content t
367
368      ;; Org styling, hide markup etc.
369      org-hide-emphasis-markers t
370      org-pretty-entities t
371
372      org-export-with-sub-superscripts nil
373      )
374
375(eval-after-load "org"
376  (add-hook 'org-add-hook 'my/modify-org-done-face))
377
378(add-to-list 'org-emphasis-alist
379	     '("=" (:foreground "red")))
380
381;; (setq org-agenda-files (append '(list "~/notes/by-product/PAF.org"
382;; 				      "~/notes/by-product/boatYacht.org"
383;; 				      "~/notes/by-product/landlord.org"
384;; 				      "~/notes/by-product/umbrella.org"
385;; 				      "~/notes/tmp/default_notes.org")
386;; 			       (file-expand-wildcards "~/notes/*.org")))
387
388;; (setq org-agenda-files
389;;       (append '(list "~/notes/todo.org"
390;; 		     "~/notes/meeting-notes/specialty-team.org")
391;; 	      (file-expand-wildcards "~/notes/plan/*.org")))
392
393(setq org-agenda-files
394      '(list "~/notes/todo.org"
395	     "~/notes/meeting-notes/specialty-team.org"))
396
397
398
399(setq org-default-notes-file "~/notes/tmp/default_notes.org")
400(setq org-archive-location "~/notes/archive/archive_%s::")
401
402(global-set-key "\C-cc" 'org-capture)
403(global-set-key "\C-ca" 'org-agenda)
404
405
406
407;; code to add create timestamp to a TODO
408
409(defun set-creation-date-heading-property ()
410  (save-excursion
411    (org-back-to-heading)
412    (org-set-property "CREATED" (format-time-string "[%Y-%m-%d %a %H:%M]"))))
413
414(defun my-org-mode-date-heading-on ()
415  "Turn on heading creation date property"
416  (interactive)
417  (add-hook 'org-insert-heading-hook #'set-creation-date-heading-property))
418
419(defun my-org-mode-date-heading-off ()
420  "Turn off heading creation date property"
421  (interactive)
422  (remove-hook 'org-insert-heading-hook #'set-creation-date-heading-property))
423
424(defun my-org-mode-date-heading-toggle ()
425  "Toggle on/off heading creation date property"
426  (interactive)
427  (if (memq #'set-creation-date-heading-property org-insert-heading-hook)
428      (progn
429        (my-org-mode-date-heading-off)
430        (message "off - heading creation date"))
431    (progn
432      (my-org-mode-date-heading-on)
433      (message "on - heading creation date"))))
434
435
436
437(setq org-capture-templates
438      '(
439	("n" "Note" entry (file org-default-notes-file) "* %? %i\n%U\tFile:%F" :empty-lines 1)
440	("t" "TODO" entry (file org-default-notes-file) "* TODO %? %i\n%U\tFile:%F" :empty-lines 1)))
441
442(setq org-image-actual-width nil)
443(setq org-descriptive-links nil)
444
445
446(defun my-org-screenshot ()
447  "Take a screenshot into a time stamped unique-named file in the
448same directory as the org-buffer and insert a link to this file."
449  (interactive)
450  (setq $fileprefix (car (last (split-string (buffer-file-name) "/"))))
451  (setq filename
452        (concat
453         (make-temp-name
454          (concat "C:/Users/hzhang/notes/assets/"
455		  $fileprefix
456                  "_"
457                  (format-time-string "%Y%m%d_%H%M%S_")) ) ".png"))
458  (shell-command "snippingtool /clip")
459  (shell-command (concat "powershell -command \"Add-Type -AssemblyName System.Windows.Forms;if ($([System.Windows.Forms.Clipboard]::ContainsImage())) {$image = [System.Windows.Forms.Clipboard]::GetImage();[System.Drawing.Bitmap]$image.Save('" filename "',[System.Drawing.Imaging.ImageFormat]::Png); Write-Output 'clipboard content saved as file'} else {Write-Output 'clipboard does not contain image data'}\""))
460  (insert (concat "[[file:" filename "]]"))
461  (org-display-inline-images))
462
463;;(global-set-key "\C-cs" 'my-org-screenshot)
464
465
466(setq fill-column 80)
467(add-hook 'org-mode-hook #'(lambda () (setq fill-column 80)))
468(add-hook 'org-log-buffer-setup-hook #'my-set-fill-column)
469(defun my-set-fill-column () (setq-local fill-column 80))
470(add-hook 'org-mode-hook 'turn-on-auto-fill)
471(add-hook 'org-mode-hook 'my-org-mode-date-heading-on)
472(add-hook 'org-mode-hook
473          (lambda ()
474            (font-lock-add-keywords
475             nil
476             '(("^-\\{5,\\}"  0 '(:foreground "magenta" :weight bold))))))
477
478
479(setq org-blank-before-new-entry '((heading . t) (plain-list-item . auto)))
480
481
482(setq org-clock-auto-clockout-timer 3600)
483(org-clock-auto-clockout-insinuate)
484
485(setq org-clock-report-include-clocking-task 1)
486
487(setq org-clock-mode-line-total 'current)
488
489
490;;(evil-set-initial-state 'org-agenda-mode 'motion)
491
492;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
493;;;;
494;;;;          end of org mode setting
495;;;;
496;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
497
498
499
500
501(setq ispell-program-name "c:/prgms/msys2/mingw64/bin/hunspell.exe")
502(setenv "DICTIONARY" "en_US")
503(setenv "DICPATH" "c:/prgms/msys2/mingw64/share/hunspell")
504;;(add-hook 'org-mode-hook 'flyspell-mode)
505
506
507
508(defun my-underscore-funcs ()
509  (lambda () (modify-syntax-entry ?_ "w")))
510
511(use-package emacs
512  :init
513  (add-to-list 'exec-path "C:/Program Files/Git/bin/")
514  ;;it will impact cpg error saying key no found
515  (add-to-list 'exec-path "c:/prgms/msys2/usr/bin/")
516
517  (add-to-list 'exec-path "C:/prgms/msys2/mingw64/bin/")
518
519  (add-to-list 'exec-path "c:/prgms/msys2/usr/bin/")
520
521  (add-to-list 'exec-path "c:/Program Files/condaplus/")
522
523
524  ;; back ups
525  (setq backup-by-copying t
526	backup-directory-alist
527	'(("." . "~/.saves"))
528	delete-old-versions t
529	kept-new-versions 6
530	kept-old-versions 2
531	version-control t)
532
533  (setq visible-bell t)
534
535
536  :config
537  (global-hl-line-mode -1)
538  ;; (set-face-background 'hl-line "#32a8a4")
539  ;; (set-face-foreground 'highlight nil)
540  (setq find-program "c:/prgms/msys2/usr/bin/find.exe")
541  (setq grep-program "c:/prgms/msys2/usr/bin/grep.exe")
542
543  (ivy-prescient-mode 1)
544  (prescient-persist-mode 1)
545
546  (setq prescient-save-file "c:/Users/hzhang/.emacs.d/var/prescient-save.el")
547
548  (blink-cursor-mode -1)
549  (tool-bar-mode -1)
550  (scroll-bar-mode 1)
551  (menu-bar-mode -1)
552  (column-number-mode 1)
553  (global-linum-mode t)
554  (put 'upcase-region 'disabled nil)
555  (set-language-environment "UTF-8")
556  ;;(set-background-color "#FFFDE9")
557  (global-auto-revert-mode t)
558  (setq inhibit-splash-screen t)
559  (setq dired-listing-switches "-alh")
560  (setq scroll-conservatively 101)
561  (setq whitespace-display-mappings '((space-mark 32 [?ยท])))
562  (setq tab-width 4)
563  (setq tab-stop-list (number-sequence 4 200 4))
564  (setq delete-trailing-lines nil)
565  (global-set-key "\C-x\ \C-b" 'ibuffer)
566
567  ;;(global-display-fill-column-indicator-mode t)
568  (setq display-fill-column-indicator-column 80)
569
570  (add-hook 'prog-mode-hook 'display-fill-column-indicator-mode)
571
572  ;;; paren
573  (setq blink-matching-paren 'jump)
574  (setq blink-matching-delay .2)
575  (show-paren-mode 1)
576  (electric-pair-mode 1)
577  (electric-indent-mode 1)
578
579  ;;; load themes
580  ;;(load-theme 'dracula t)
581  ;;(load-theme 'whiteboard t)
582  (load-theme 'modus-operandi t)
583
584  ;;(executable-find "ros")
585  (load (expand-file-name "~/.roswell/helper.el"))
586  (setq inferior-lisp-program "ros -Q run")
587
588  ;;;
589  (modify-syntax-entry ?_ "w" sql-mode-syntax-table)
590  (add-hook 'python-mode-hook #'(lambda ()(modify-syntax-entry ?_ "w")))
591  (add-hook 'sql-mode-hook #'sqlind-minor-mode)
592
593  ;;(add-hook 'org-mode-hook #'(lambda () (setq-default truncate-lines nil)))
594
595  (setq-default truncate-lines nil)
596  (setq org-log-done 'time)
597
598  ;;
599  (setq ls-lisp-format-time-list  '("%Y-%m-%d %H:%M" "%Y-%m-%d %H:%M")
600	ls-lisp-use-localized-time-format t)
601  (setq dired-listing-switches "-alht --group-directories-first")
602  ;;;
603  ;;;
604  (add-hook 'before-save-hook 'delete-trailing-whitespace))
605
606;; ibuffer
607(setq ibuffer-formats
608      '((mark modified read-only " "
609	      (name 35 35 :left :elide) " "
610	      (mode 16 16 :left :elide) " "
611	      filename-and-process)))
612
613;; add group filter for ibuffer-mode
614(setq ibuffer-saved-filter-groups
615      (quote (("default"
616			   ("org" (mode . org-mode))
617			   ("sql" (mode . sql-mode))
618			   ("stat" (filename . ".sas"))
619			   ("python" (mode . python-mode))
620			   ("sas-log" (filename . ".log"))
621			   ("sas-lst" (filename . ".lst"))
622			   ("dired" (mode . dired-mode))
623			   ("markdown" (filename . ".md"))
624			   ("el" (mode . emacs-lisp-mode))
625			   ("bookmark" (name . "*bookmark list*"))
626			   ("sh" (mode . sh-mode))))))
627
628(setq ibuffer-show-empty-filter-groups nil)
629
630(add-hook 'ibuffer-mode-hook
631	  (lambda ()
632	    (ibuffer-switch-to-saved-filter-groups "default")))
633
634
635
636(defun my-remote-mode-setup-function ()
637  (when (and (fboundp 'company-mode)
638             (file-remote-p default-directory))
639    (progn
640      (company-mode -1)
641      (company-posframe-mode -1)
642      (auto-complete-mode 1))))
643
644(add-hook 'find-file-hook 'my-remote-mode-setup-function)
645
646;; run server automatically
647(require 'server)
648(unless (server-running-p)
649  (server-start))
650
651(custom-set-variables
652 ;; custom-set-variables was added by Custom.
653 ;; If you edit it by hand, you could mess it up, so be careful.
654 ;; Your init file should contain only one such instance.
655 ;; If there is more than one, they won't work right.
656 '(blink-cursor-mode nil)
657 '(column-number-mode t)
658 '(custom-safe-themes
659   '("8d146df8bd640320d5ca94d2913392bc6f763d5bc2bb47bed8e14975017eea91" "1594eb8fc081be254c7df7b2a37e9808f79c94863366da6d34bbe735519a30f5" "99d1e29934b9e712651d29735dd8dcd431a651dfbe039df158aa973461af003e" "372905daccda4574b28e5d5b64d5a4059da9e3c5548abc274af04fe63adc1372" "e410458d3e769c33e0865971deb6e8422457fad02bf51f7862fa180ccc42c032" "9a977ddae55e0e91c09952e96d614ae0be69727ea78ca145beea1aae01ac78d2" "1436985fac77baf06193993d88fa7d6b358ad7d600c1e52d12e64a2f07f07176" "00445e6f15d31e9afaa23ed0d765850e9cd5e929be5e8e63b114a3346236c44c" "bffa9739ce0752a37d9b1eee78fc00ba159748f50dc328af4be661484848e476" default))
660 '(fill-column 80)
661 '(global-display-line-numbers-mode nil)
662 '(org-agenda-files
663   '("c:/Users/hzhang/notes/todo.org" "c:/Users/hzhang/notes/meeting-notes/specialty-team.org"))
664 '(org-agenda-weekend-days nil)
665 '(org-tags-column -81)
666 '(package-selected-packages
667   '(telephone-line ivy-prescient all-the-icons modus-themes org-modern deft compat go-mode eval-in-repl slime sql-indent aggressive-indent company-posframe company-box markdown-mode ess auctex org-download anzu avy helm beacon company exec-path-from-shell auto-complete undo-tree diminish org-superstar projectile magit rainbow-delimiters counsel ivy evil))
668 '(tool-bar-mode nil)
669 '(warning-suppress-types '((comp) (comp))))
670(custom-set-faces
671 ;; custom-set-faces was added by Custom.
672 ;; If you edit it by hand, you could mess it up, so be careful.
673 ;; Your init file should contain only one such instance.
674 ;; If there is more than one, they won't work right.
675 '(default ((t (:family "Fira Code" :foundry "outline" :slant normal :weight normal :height 143 :width normal))))
676 '(org-agenda-deadline ((t (:foreground "red" :weight bold :background "yellow"))))
677 '(org-agenda-deadline-future ((t (:foreground "red" :weight bold :background "yellow"))))
678 '(org-agenda-deadline-today ((t (:foreground "red" :weight bold :background "yellow"))))
679 '(org-agenda-scheduled ((t (:foreground "blue" :weight bold :background "yellow"))))
680 '(org-agenda-scheduled-future ((t (:foreground "blue" :weight bold :background "yellow"))))
681 '(org-agenda-scheduled-today ((t (:foreground "blue" :weight bold :background "yellow"))))
682 '(show-paren-match ((t (:background "black" :foreground "#8be9fd" :weight bold)))))
683
684
685;; (setq-default global-mode-string
686;; 	      (if (string-match-p (regexp-quote "/plink*") default-directory) "remote" "local"))
687;;(when (not (string-match-p (regexp-quote "/plink*") default-directory)) (company-mode))
688;; (file-remote-p default-directory)
689;; (eval default-directory)
690
691;;(when (not (file-remote-p default-directory)) (company-mode))
692;;(when (not (string-match-p (regexp-quote "/plink*") default-directory)) (company-mode))
693
694
695;; (defun myfile-remote-p ()
696;;   (when (file-remote-p default-directory)
697;;     (setq-default global-mode-string "remote")))
698;; (add-hook 'find-file-hook #'myfile-remote-p)
699