summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoroskar <[email protected]>2024-05-22 19:45:16 +0200
committeroskar <[email protected]>2024-05-22 19:45:16 +0200
commite15ea0314ec24b96a926e7f0db69f3963438fbce (patch)
tree49b6d32a7bb8887d16ec795773909ae0c866cba8
parentde01077bfb714d824830108f6659a0608f4c3654 (diff)
fixed .emacs to emacs
-rw-r--r--.emacs33
-rw-r--r--README1
-rw-r--r--emacs6
3 files changed, 7 insertions, 33 deletions
diff --git a/.emacs b/.emacs
deleted file mode 100644
index 4b400ee..0000000
--- a/.emacs
+++ /dev/null
@@ -1,33 +0,0 @@
-
-(setq inhibit-startup-message t)
-(setq visible-bell t)
-
-;; The menu bar and its configurations
-(menu-bar-mode 1) ;; This one is very useful to leave on actually
-(tool-bar-mode -1) ;; No tool bar
-(scroll-bar-mode -1) ;; No scroll bars
-(global-display-line-numbers-mode 1) ;; Show line numbers
-(column-number-mode 1) ;; Show column numbers as well
-(load-theme 'adwaita t) ;; My preffered themes
- ;; 'wombat' for dark, 'adwaita' for light
-(set-face-attribute 'default nil :height 125) ;; Text size
-;;(setq make-backup-files nil) ;; Prevent backup file from cluttering
-(setq lock-file-name-transforms
- '(("\\`/.*/\\([^/]+\\)\\'" "~/.emacs.d/aux/\\1" t)))
-(setq auto-save-file-name-transforms
- '(("\\`/.*/\\([^/]+\\)\\'" "~/.emacs.d/aux/\\1" t)))
-(setq backup-directory-alist
- '((".*" . "~/.emacs.d/aux/")))
-(display-battery-mode 1)
-
-;; From how i understand it, these variables are supposed to make tab and indentation be 4 in width?
-(setq-default tab-width 4) ; Tab width (duh)
-(setq c-basic-offset 4) ; Tab width (but for C?)
-(find-file "/home/oskar/doc/how2emacs.txt")
-(switch-to-buffer "*scratch*")
-
-(defun lmid ()
- ;;Move cursor to the middle of the current line
- (interactive)
- (let ((line-length (- (line-end-position) (line-beginning-position))))
- (goto-char (+ (line-beginning-position) (/ line-length 2)))))
diff --git a/README b/README
new file mode 100644
index 0000000..6cfd8ec
--- /dev/null
+++ b/README
@@ -0,0 +1 @@
+My emacs config
diff --git a/emacs b/emacs
index a99359d..4b400ee 100644
--- a/emacs
+++ b/emacs
@@ -25,3 +25,9 @@
(setq c-basic-offset 4) ; Tab width (but for C?)
(find-file "/home/oskar/doc/how2emacs.txt")
(switch-to-buffer "*scratch*")
+
+(defun lmid ()
+ ;;Move cursor to the middle of the current line
+ (interactive)
+ (let ((line-length (- (line-end-position) (line-beginning-position))))
+ (goto-char (+ (line-beginning-position) (/ line-length 2)))))