Skip to content

Commit

Permalink
feat: initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
hhirsch committed Nov 25, 2023
0 parents commit 4fca372
Show file tree
Hide file tree
Showing 2 changed files with 124 additions and 0 deletions.
95 changes: 95 additions & 0 deletions init.el
Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
(require 'package)
(add-to-list 'package-archives '("melpa" . "https://melpa.org/packages/"))

(unless (package-installed-p 'use-package)
(package-refresh-contents)
(package-install 'use-package))

(eval-when-compile
(require 'use-package))

(tool-bar-mode -1)
(menu-bar-mode -1)
(gcmh-mode 1)
(global-linum-mode 1)
(ido-mode 1)
(set-face-attribute 'default nil :height 150)

(setq-default indent-tabs-mode nil)
(setq-default tab-width 2)
(setq indent-line-function 'insert-tab)

(setq backup-directory-alist
`((".*" . "~/.saves")))
(setq auto-save-file-name-transforms
`((".*" "~/.saves" t)))

(use-package server
:config
(unless (server-running-p)
(server-start)))

(use-package dashboard
:ensure t
:config
(dashboard-setup-startup-hook)
(setq dashboard-set-footer nil)
(setq dashboard-startup-banner "~/.emacs.d/logo.svg")
(setq dashboard-banner-logo-title "MeMacs")
(setq dashboard-init-info "Keep things light"))

(use-package lsp-mode
:ensure t
:config
(add-hook 'php-mode-hook #'lsp)
(add-hook 'c-mode-hook #'lsp)
(add-hook 'c++-mode-hook #'lsp)
(add-hook 'js-mode-hook #'lsp)
)

(use-package dap-php
:config
)

(use-package doom-themes
:ensure t
:config
;; Global settings (defaults)
(setq doom-themes-enable-bold t ; if nil, bold is universally disabled
doom-themes-enable-italic t) ; if nil, italics is universally disabled
(load-theme 'doom-one t)
;; Enable flashing mode-line on errors
(doom-themes-visual-bell-config)
;; Enable custom neotree theme (all-the-icons must be installed!)
(doom-themes-neotree-config)
;; or for treemacs users
(setq doom-themes-treemacs-theme "doom-atom") ; use "doom-colors" for less minimal icon theme
(doom-themes-treemacs-config)
;; Corrects (and improves) org-mode's native fontification.
(doom-themes-org-config))



(defun autocompile nil
"compile itself if init file"
(interactive)
(require 'bytecomp)
(let ((dotemacs (file-truename user-init-file)))
(if (string= (buffer-file-name) (file-chase-links dotemacs))
(byte-compile-file dotemacs))))

(add-hook 'after-save-hook 'autocompile)

(custom-set-variables
;; custom-set-variables was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
'(package-selected-packages
'(nerd-icons all-the-icons dap-mode php-mode company lsp-mode dashboard)))
(custom-set-faces
;; custom-set-faces was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
)
29 changes: 29 additions & 0 deletions logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 4fca372

Please sign in to comment.