summaryrefslogtreecommitdiffstats
path: root/jeschli/2configs
diff options
context:
space:
mode:
authorJeschli <jeschli@gmail.com>2019-09-24 15:57:55 +0200
committerJeschli <jeschli@gmail.com>2019-09-24 15:57:55 +0200
commit4d5b849d6ad8993e311ab5b91d177b44adfc89ba (patch)
treee49056dbe1da26bb90c994136ef7b0924c3267a9 /jeschli/2configs
parent122bd770673f69d2268a83457d9d3440030eea24 (diff)
j emacs: set up function key binding section
Diffstat (limited to 'jeschli/2configs')
-rw-r--r--jeschli/2configs/emacs.nix22
1 files changed, 18 insertions, 4 deletions
diff --git a/jeschli/2configs/emacs.nix b/jeschli/2configs/emacs.nix
index 396cf241d..bc9cfdb4b 100644
--- a/jeschli/2configs/emacs.nix
+++ b/jeschli/2configs/emacs.nix
@@ -127,12 +127,26 @@ let
(global-set-key "\C-x\ \C-r" 'recentf-open-files)
'';
- killActualBuffer = ''
+ myFunctionKeys = ''
(fset 'kill-actual-buffer
[?\C-x ?k return])
- (global-set-key (kbd "<f5>") 'kill-actual-buffer)
+
+ (defun mh/open-term-and-rename (name)
+ "open a new bash and rename it"
+ (interactive "sName of new terminal: ")
+ (term "/run/current-system/sw/bin/bash")
+ (rename-buffer name)
+ )
+ (global-set-key (kbd "M-<f8>") 'kill-actual-buffer)
+
+ (global-set-key (kbd "<f5>") 'mh/open-term-and-rename)
+ (global-set-key (kbd "<f6>") 'other-window)
+ (global-set-key (kbd "<f7>") 'split-window-right)
+ (global-set-key (kbd "<f8>") 'delete-other-windows)
'';
+
+
dotEmacs = pkgs.writeText "dot-emacs" ''
${packageRepos}
@@ -147,7 +161,7 @@ let
${windowCosmetics}
${orgAgendaView}
- ${killActualBuffer}
+ ${myFunctionKeys}
'';
emacsWithCustomPackages = (pkgs.emacsPackagesNgGen pkgs.emacs).emacsWithPackages (epkgs: [
@@ -181,7 +195,7 @@ let
epkgs.melpaPackages.smex
epkgs.melpaPackages.org-mime
- epkgs.melpaPackages.which-key
+ epkgs.elpaPackages.which-key
]);
myEmacs = pkgs.writeDashBin "my-emacs" ''