With this, everything is just simple. There are versions of GNU / Linux, FreeBSD, AIX 4.3.3 and higher, Mac OS X, MS DOS, MS Windows, NetBSD, OpenBSD, Solaris, SunOS, Ultrix.
For every taste and color.
The main configuration file .emacs. And he is, or should be, in the home directory. / home / username or C: \ Documents and Settings \ username \ Application Data, or ...
In the same place,it is necessaryI prefer to create the .emacs.d directory for storing the extension files.
We need to work with these two chips.
Rule .emacs(add-to-list 'load-path "~/.emacs.d/") ;;
(custom-set-variables
'(column-number-mode t) ;;
'(default-input-method "russian-computer") ;;
'(display-time-mode t) ;;.. ,
'(tool-bar-mode nil)) ;;
(setq inhibit-startup-message t) ;;
(fset 'yes-or-no-p 'y-or-np) ;; yes
(setq default-tab-width 4) ;;
We take archive here we unpack in ~ / .emacs.d /
Rule .emacs like this:(require 'color-theme) ;; " "
(color-theme-initialize) ;;
(color-theme-arjen) ;;
You can view all the schemes in the following way: in Emacs, click Mx (Alt-x) and write color-theme-select. I do not want to choose.
Now we need to make Emacs understand php better.
We take here ( UPD: and here ), we rule like this:(require 'php-mode) ;; php
(require 'php-electric) ;; autocompletion
Next, my favorite "cuts mode". With it, you can reduce the number of strokes on the buttons of the keyboard.(require 'msf-abbrev) ;; " "
(setq-default abbrev-mode t) ;;
(setq save-abbrevs nil) ;;
(setq msf-abbrev-root "~/.emacs.d/abb") ;;
(global-set-key (kbd "Cc a") 'msf-abbrev-define-new-abbrev-this-mode) ;;(Ctrl-c a)
(msf-abbrev-load) ;; :)
And now, if we need to reduce the hateful if () {} else {} blah blah
Press (Cc a) enter a name for the abbreviation, in our case, if and writeif (<field "what">) {
<field "do it">
}
else {
<field "else do it">
}
, if , TAB field.
, , - .
msf-abbrev.el
(global-set-key [? \ Cz] 'shell) ;; well ... shell
(global-set-key [? \ Cx? \ Cg] 'goto-line) ;; here, too, everything is clear ... sort of
(global-set-key [? \ Cx? \ Cb] 'ibuffer) ;; more convenient buffer switch
Source: https://habr.com/ru/post/25854/
All Articles