Browse Source

org-mode, agenda, and initial-frame

ubuntu
parent
commit
7496cfa714
1 changed files with 88 additions and 20 deletions
  1. +88
    -20
      .emacs

+ 88
- 20
.emacs View File

@ -8,6 +8,10 @@
(unless (package-installed-p 'use-package) (unless (package-installed-p 'use-package)
(package-refresh-contents) (package-refresh-contents)
(package-install 'use-package)) (package-install 'use-package))
;; frame size
(setq initial-frame-alist '((top . 10)(left . 20)
(width . 90)(height . 50)))
;; which-key: ;; which-key:
(use-package which-key (use-package which-key
:ensure t :ensure t
@ -16,12 +20,16 @@
(use-package doom-themes (use-package doom-themes
:ensure t :ensure t
:config :config
(load-theme 'doom-one t)
(setq doom-themes-enable-bold t ; if nil, bold is universally disabled
doom-themes-enable-italic t) ; if nil, italics is universally disabled
(load-theme ;'doom-one
'doom-tomorrow-day t)
;; Enable flashing mode-line on errors ;; Enable flashing mode-line on errors
(doom-themes-visual-bell-config) (doom-themes-visual-bell-config)
;; Enable custom neotree theme (all-the-icons must be installed!) ;; Enable custom neotree theme (all-the-icons must be installed!)
(doom-themes-neotree-config) (doom-themes-neotree-config)
;; or for treemacs users ;; or for treemacs users
(setq doom-themes-treemacs-theme "doom-colors") ; use the colorful treemacs theme (setq doom-themes-treemacs-theme "doom-colors") ; use the colorful treemacs theme
(doom-themes-treemacs-config) (doom-themes-treemacs-config)
;; Corrects (and improves) org-mode's native fontification. ;; Corrects (and improves) org-mode's native fontification.
@ -120,24 +128,20 @@
(setenv "PATH" (concat (getenv "PATH") ":/Library/TeX/texbin/")) (setenv "PATH" (concat (getenv "PATH") ":/Library/TeX/texbin/"))
(setq exec-path (append exec-path '("/Library/TeX/texbin/"))) (setq exec-path (append exec-path '("/Library/TeX/texbin/")))
;; Use pdf-tools to open PDF files ;; Use pdf-tools to open PDF files
;; (use-package pdf-tools
;; :ensure t
;; :pin melpa
;; :config
;; (custom-set-variables
;; '(pdf-tools-handle-upgrades nil)) ; Use brew upgrade pdf-tools instead.
;; (setq pdf-info-epdfinfo-program "/usr/local/bin/epdfinfo"))
(use-package doc-view
:defer t
:custom
;; Use MikTeX's utilities for PDF conversion and searching
(doc-view-pdf->png-converter-function 'doc-view-pdf->png-converter-ghostscript))
;; (setq TeX-view-program-selection '((output-pdf "Preview.app")))
(use-package pdf-tools
:ensure nil
:pin melpa
:config
(custom-set-variables
'(pdf-tools-handle-upgrades nil)) ; Use brew upgrade pdf-tools instead.
(setq pdf-info-epdfinfo-program "/usr/local/bin/epdfinfo"))
;; Use pdf-tools to open PDF files
(setq TeX-view-program-selection '((output-pdf "PDF Tools"))
TeX-source-correlate-start-server t)
(add-hook 'LaTeX-mode-hook 'pdf-view-mode)
;; Update PDF buffers after successful LaTeX runs ;; Update PDF buffers after successful LaTeX runs
;; (add-hook 'TeX-PDF-mode-hook 'pdf-view-mode)
;; (add-hook 'TeX-after-compilation-finished-functions
;; 'TeX-revert-document-buffer)
(add-hook 'TeX-after-compilation-finished-functions
#'TeX-revert-document-buffer)
;; flycheck ;; flycheck
(use-package flycheck (use-package flycheck
:ensure t :ensure t
@ -168,6 +172,63 @@
;; Set default font: ;; Set default font:
(add-to-list 'default-frame-alist (add-to-list 'default-frame-alist
'(font . "Source Code Pro-18")) '(font . "Source Code Pro-18"))
;; Activatiin ORG-mode
(global-set-key (kbd "C-c l") 'org-store-link)
(global-set-key (kbd "C-c a") 'org-agenda)
(global-set-key (kbd "C-c c") 'org-capture)
;;++++++++++
;; Todo states for ORG:
(setq org-todo-keywords
(quote
((sequence "TODO(t)" "PROGRESS(g)" "PAUSE(p)" "CHECK(k)" "|" "DONE(d)" "CANCELED(c)"))))
(setq org-todo-keyword-faces
'(("PROGRESS" . "orange") ("PAUSE" . "magenta") ("CHECK" . "purple") ("CANCELED" . "red") ("DONE" . "green")))
;; capture:
(setq org-capture-templates
(quote (
("a" ; hotkey
"Academia Todo" ; name
entry ; type
(file+headline "/Users/gmarx/beorg/academia.org" "Tasks") ;target
"* TODO [#B] %^{Task}" ; template
)
("t"
"Task PhD"
entry
(file+datetree "~/beorg/phd.org")
"* TODO [#A] %^{Task}")
("d"
"Students"
item
(file+datetree "~/beorg/students.org")
"- %U - %^{Activity}")
("r"
"to Read"
entry
(file+headline "~/beorg/inbox.org" "to read")
"* TODO %^{topic to read}\n%^{Why to read this?}"
)
("s"
"Schedule an event"
entry
(file+headline "~/beorg/inbox.org" "Scheduled events")
"* %^{Event}\nSCHEDULED: %^t"
)
("k"
"Task inbox"
entry
(file+headline "~/beorg/inbox.org" "Tasks")
"* TODO %^{Task} -> %^{move to}"
)
("c"
"Cheat-Sheet"
entry
(file+headline "~/beorg/cheatsheets.org" "Notes")
"* %^{what solves}\n%^{the commands are}"
)
)))
(custom-set-variables (custom-set-variables
;; custom-set-variables was added by Custom. ;; custom-set-variables was added by Custom.
;; 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.
@ -176,12 +237,19 @@
'(custom-safe-themes '(custom-safe-themes
(quote (quote
("2f1518e906a8b60fac943d02ad415f1d8b3933a5a7f75e307e6e9a26ef5bf570" "fe94e2e42ccaa9714dd0f83a5aa1efeef819e22c5774115a9984293af609fce7" default))) ("2f1518e906a8b60fac943d02ad415f1d8b3933a5a7f75e307e6e9a26ef5bf570" "fe94e2e42ccaa9714dd0f83a5aa1efeef819e22c5774115a9984293af609fce7" default)))
'(org-agenda-files
(quote
("~/beorg/students.org" "~/beorg/inbox.org" "~/beorg/academia.org")))
'(package-selected-packages '(package-selected-packages
(quote (quote
(company org-bullets expand-region flycheck treemacs-projectile treemacs magit auctex dashboard helm-projectile helm doom-modeline doom-themes which-key use-package projectile)))
(pdf-tools company org-bullets expand-region flycheck treemacs-projectile treemacs magit auctex dashboard helm-projectile helm doom-modeline doom-themes which-key use-package projectile)))
'(pdf-tools-handle-upgrades nil)
'(safe-local-variable-values '(safe-local-variable-values
(quote (quote
((pyvenv-workon . keesman_env)
((org-attach-directory . "students/")
(org-attach-use-inheritance . t)
(org-attach-preferred-new-method . ask)
(pyvenv-workon . keesman_env)
(org-edit-src-content . 0) (org-edit-src-content . 0)
(org-src-preserve-indentation . t))))) (org-src-preserve-indentation . t)))))
(custom-set-faces (custom-set-faces


Loading…
Cancel
Save