-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathosx.el
41 lines (30 loc) · 1.19 KB
/
osx.el
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
;;; osx.el --- macOS related configuration -*- lexical-binding: t; -*-
;;; Commentary:
;; macOS related configurations
;;; Code:
(setq
ns-use-mwheel-momentum t
ns-use-mwheel-acceleration t
ns-function-modifier 'hyper
mac-command-modifier 'meta
mac-option-modifier 'super
trash-directory "~/.Trash/emacs")
;; Fix macos titlebar
(add-to-list 'default-frame-alist '(ns-transparent-titlebar . t))
(add-to-list 'default-frame-alist '(ns-appearance . dark))
(setq dired-use-ls-dired t
insert-directory-program "/opt/homebrew/bin/gls"
dired-listing-switches "-aBhl --group-directories-first")
;; Map æøå keys to macOS using non-Norwegian keymap
(define-key key-translation-map (kbd "s-a") "å")
(define-key key-translation-map (kbd "s-'") "æ")
(define-key key-translation-map (kbd "s-o") "ø")
(define-key key-translation-map (kbd "s-A") "Å")
(define-key key-translation-map (kbd "s-\"") "Æ")
(define-key key-translation-map (kbd "s-O") "Ø")
(define-key (current-global-map) (kbd "s-p") nil)
(define-key (current-global-map) (kbd "s-o") nil)
(define-key (current-global-map) (kbd "s-t") nil)
(use-package exec-path-from-shell
:init (exec-path-from-shell-initialize))
;;; osx.el ends here