summaryrefslogtreecommitdiffstats
path: root/.config/emacs/jd-emacs/jd-emacs-apps.el
blob: 628039de1e40f7e5aa4bdc3c89261649d6fecc2e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
;;; Dotfiles --- Jakub Dlugosz emacs config
;;; Commentary:

;;; Code:

(defun jd/open-new-vterm (&optional jd/vterm-buffer-name)
  (interactive)
  (let ((buffer-name (generate-new-buffer-name vterm-buffer-name)))
    (when jd/vterm-buffer-name
      (setq buffer-name jd/vterm-buffer-name))
    (switch-to-buffer buffer-name)
    (vterm-mode)))


(use-package vterm
  :init
  (add-to-list 'project-switch-commands     '(project-vterm "Vterm") t)
  (add-to-list 'project-kill-buffer-conditions  '(major-mode . vterm-mode))
  (setq vterm-copy-exclude-prompt t)
  :config
  (setq vterm-buffer-name "vterm")
  (evil-set-initial-state 'vterm-mode 'emacs)
  (setq vterm-tramp-shells (append  '(("ssh" "/bin/bash")) vterm-tramp-shells)))

(jd/leader-key-def
  "ot" '(jd/open-new-vterm :which-key "Open terminal in current window"))

(use-package all-the-icons-dired
  :hook (dired-mode . all-the-icons-dired-mode))

(use-package dired-ranger)

(use-package dired
  :ensure nil
  :commands (dired dired-jump)
  :custom ((dired-listing-switches "-agho --group-directories-first"))
  :config
  (evil-collection-define-key 'normal 'dired-mode-map
    "y" 'dired-ranger-copy
    "p" 'dired-ranger-paste
    "X" 'dired-ranger-move
    "h" 'dired-up-directory
    "t" 'dired-create-empty-file
    "T" 'dired-toggle-marks
    "l" 'dired-find-file)
  (setq dired-kill-when-opening-new-dired-buffer t)
  (evil-define-key 'normal dired-mode-map (kbd "q") 'kill-current-buffer))

(use-package emms
  :config
  (require 'emms-setup)
  (emms-all)
  (emms-standard)
  (emms-default-players)
  (emms-mode-line-disable)
                                        ; (setq emms-info-functions '(emms-info-tinytag))
  (setq emms-browser-covers 'emms-browser-cache-thumbnail-async)
  ;; (setq emms-lyrics-dir "~/Documents/music/lyrics")
  (emms-add-directory-tree "~/Documents/Music/"))

(use-package pdf-tools)

(require 'jd-mu4e)

(use-package elfeed
  :config
  (setq elfeed-feeds
        '(("https://www.reddit.com/r/emacs.rss" emacs)
          ("https://www.reddit.com/r/gnu.rss" gnu)
          ("https://stallman.org/rss/rss.xml" stallman))))

(use-package langtool
  :config
  (setq langtool-language-tool-jar "/home/jakub/Documents/LanguageTool-6.0/languagetool-commandline.jar")
  (setq langtool-default-language "pl-PL"))

(jd/leader-key-def
  "l"  '(:ignore t :which-key "langtool")
  "lc" 'langtool-check-buffer
  "ld" 'langtool-check-done
  "li" 'langtool-interactive-correction)

(use-package mastodon
  :config
  (setq mastodon-active-user "jdlugosz963"
	mastodon-instance-url "https://fosstodon.org/"))

;;; jd-apps.el ends here