For C/C++ programmers Emacs is a very useful environment. But for beginners it seems to be difficult to select the right (and most useful) packages and commands. Therefore i want to present my initialization file default.el
and the associated key bindings as a PDF. The initialization file should work with Emacs 23.x and 24.x under Linux and Windows.
There are some additional (sub-) initialization files, which are loaded by default.el
(but only if found in load-path
):
init-custom.el
,init-locale.el
(for German language),rho-theme.el
,init-site.el
(loaded last).
In my Emacs setup the file ~/.emacs
is only a simple stub, which ensures loading of default.el
. It looks like that piece of code:
;; -*- mode: emacs-lisp; coding: utf-8-emacs -*- ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; ;; Emacs start-up file ~/.emacs ;; Copyright (C) 2020 Ralf Hoppe <ralf@dfcgen.de> ;; ;; NOTE: This file is only a simple stub, which sets the `load-path' and some ;; start-up variables. I use default.el as the user's initialization file. ;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; (setq inhibit-splash-screen t inhibit-default-init nil) ; process default.el (anywhere in `load-path') ;; EMACSLOADPATH="$HOME/<path-to-default-el>:" (push "~/<path-to-default-el>" load-path)
There are some (main) principles i follow in default.el
:
For C/C++ software development i use the following features/modes (aside of CC Mode):
Last a screenshot of my (default) theme rho
: