summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--emacs/inits/20-programming.el61
-rw-r--r--i3/config17
2 files changed, 48 insertions, 30 deletions
diff --git a/emacs/inits/20-programming.el b/emacs/inits/20-programming.el
index 1ca76e0..72241b6 100644
--- a/emacs/inits/20-programming.el
+++ b/emacs/inits/20-programming.el
@@ -1,4 +1,4 @@
-;; Time-stamp: <2020-04-25 21:17:05 (tslil@bison)>
+;; Time-stamp: <2020-05-17 10:51:43 (tslil@forfeit)>
;; -----------------------------------------------------------------------------
;; General setup
@@ -22,7 +22,8 @@
(if (fboundp 'display-line-numbers-mode)
(display-line-numbers-mode)
(linum-mode))
- (setq auto-hscroll-mode t))
+ (setq auto-hscroll-mode t)
+ (yas-minor-mode-on))
(add-hook 'prog-mode-hook #'programming-setup)
@@ -45,7 +46,8 @@
(use-package yasnippet
:ensure t
- :defer t)
+ :defer t
+ :commands yas-minor-mode-on)
(use-package elec-pair
:defer t
@@ -149,6 +151,34 @@
(c-toggle-electric-state 1)
(c-toggle-syntactic-indentation 1)))
+(use-package verilog-mode
+ :ensure t
+ :defer t
+ :mode "\\.vl$"
+ :hook (verilog-mode . (lambda ()
+ (setq verilog-tool 'verilog-compiler)
+ (verilog-set-compile-command)))
+ :config
+ (setq verilog-compiler "iverilog"
+ verilog-tool 'verilog-compiler))
+
+(use-package gforth
+ :commands forth-mode
+ :mode (("\\.fs$" . forth-mode)
+ ("\\.fb$" . forth-block-mode)
+ ("\\.4th$" . forth-mode)))
+
+;; -----------------------------------------------------------------------------
+;; Rust
+
+(use-package lsp-mode
+ :ensure t
+ :defer t)
+
+(use-package cargo
+ :ensure t
+ :defer t)
+
(use-package flycheck-rust
:after flycheck
:ensure t
@@ -166,32 +196,19 @@
("C-c C-c" . rust-compile)
("C-c C-r" . rust-run))
:hook (rust-mode . (lambda ()
+ (cargo-minor-mode)
;; For some reason this is not automatic
(setq-local electric-pair-pairs
(cons '(?' . ?') electric-pair-pairs))
;; Pair {} in rust format strings ... ?
(setq-local electric-pair-text-pairs
(cons '(?{ . ?}) electric-pair-pairs))
- (flycheck-rust-setup)))
+ (flycheck-rust-setup)
+ (lsp)))
:config
(setq rust-indent-offset 4
rust-indent-method-chain t
rust-indent-where-clause t
- rust-format-on-save t))
-
-(use-package verilog-mode
- :ensure t
- :defer t
- :mode "\\.vl$"
- :hook (verilog-mode . (lambda ()
- (setq verilog-tool 'verilog-compiler)
- (verilog-set-compile-command)))
- :config
- (setq verilog-compiler "iverilog"
- verilog-tool 'verilog-compiler))
-
-(use-package gforth
- :commands forth-mode
- :mode (("\\.fs$" . forth-mode)
- ("\\.fb$" . forth-block-mode)
- ("\\.4th$" . forth-mode)))
+ rust-format-on-save t)
+ (setq lsp-rust-server 'rust-analyzer
+ lsp-rust-analyzer-call-info-full nil))
diff --git a/i3/config b/i3/config
index 5af11f3..1940109 100644
--- a/i3/config
+++ b/i3/config
@@ -1,4 +1,4 @@
-# Time-stamp: <2020-05-09 14:37:02 (tslil@forfeit)>
+# Time-stamp: <2020-05-11 15:50:40 (tslil@forfeit)>
set $mod Mod4
@@ -33,11 +33,12 @@ bindsym XF86AudioMicMute exec --no-startup-id pactl set-source-mute @DEFAULT_SOU
floating_modifier $mod
-bindsym $mod+c exec i3-sensible-terminal
+bindsym $mod+Return exec i3-sensible-terminal
bindsym $mod+Shift+k kill
-bindsym $mod+space exec dmenu_run
+bindsym $mod+p exec rofi -show window
+bindsym $mod+space exec rofi -show run
bindsym $mod+q exec firefox
-bindsym $mod+p exec emacs
+bindsym $mod+d exec emacs
# -----------------------------------------------------------------------------
# Focus
@@ -88,7 +89,7 @@ bindsym $mod+a mode "resize"
bindsym $mod+h split h
bindsym $mod+v split v
-bindsym $mod+Return fullscreen toggle
+bindsym $mod+Shift+f fullscreen toggle
bindsym $mod+s layout stacking
bindsym $mod+t layout tabbed
@@ -103,9 +104,9 @@ bindsym $mod+Shift+u focus child
# -----------------------------------------------------------------------------
# Workspaces
-set $ws1 "1"
-set $ws2 "2"
-set $ws3 "3"
+set $ws1 "1 : default"
+set $ws2 "2 : work"
+set $ws3 "3 : game"
set $ws4 "4"
set $ws5 "5"
set $ws6 "6"