emacs.rst
author Oleksandr Gavenko <gavenkoa@gmail.com>
Sat, 10 Feb 2018 01:49:07 +0200
changeset 2230 9e6ad6607a9e
parent 2228 837f1337c59b
permissions -rw-r--r--
Fixed formatting.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     1
.. -*- coding: utf-8; -*-
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     2
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     3
========
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     4
 Emacs.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     5
========
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     6
.. contents::
1905
fba288d59662 Include only local subsections into TOC. This prevent duplication of
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1654
diff changeset
     7
   :local:
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     8
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
     9
About.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    10
======
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    11
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
    12
http://elpa.gnu.org/
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
    13
  Packages for Emacs.
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    14
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    15
Getting help.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    16
=============
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    17
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
    18
* http://news.gmane.org/gmane.emacs.help
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
    19
* http://news.gmane.org/gmane.emacs.announce
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
    20
* http://news.gmane.org/gmane.emacs.auctex.announce
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    21
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    22
Installing Emacs.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    23
=================
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    24
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
    25
http://ftp.gnu.org/gnu/emacs/windows/
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
    26
  Official build of GNU Emacs for Windows.
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
    27
http://alpha.gnu.org/gnu/emacs/windows/
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
    28
  Official alpha build of GNU Emacs.
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
    29
http://emacsformacosx.com/
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
    30
  Clean GNU Emacs for Mac OS X.
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    31
1652
a653ec78b1b8 Find variable/function/feature by name or value.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1477
diff changeset
    32
Development.
a653ec78b1b8 Find variable/function/feature by name or value.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1477
diff changeset
    33
============
a653ec78b1b8 Find variable/function/feature by name or value.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1477
diff changeset
    34
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    35
Variables.
1652
a653ec78b1b8 Find variable/function/feature by name or value.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1477
diff changeset
    36
----------
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    37
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    38
Select one of::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    39
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    40
  (set 'variable value)
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    41
  (setq variable value)
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    42
  (defvar variable value "documentation")
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    43
1652
a653ec78b1b8 Find variable/function/feature by name or value.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1477
diff changeset
    44
or file local::
a653ec78b1b8 Find variable/function/feature by name or value.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1477
diff changeset
    45
a653ec78b1b8 Find variable/function/feature by name or value.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1477
diff changeset
    46
  # Local variables:
a653ec78b1b8 Find variable/function/feature by name or value.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1477
diff changeset
    47
  # variable: value
a653ec78b1b8 Find variable/function/feature by name or value.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1477
diff changeset
    48
  # End:
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    49
1652
a653ec78b1b8 Find variable/function/feature by name or value.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1477
diff changeset
    50
Find variable/function/feature by name or value.
a653ec78b1b8 Find variable/function/feature by name or value.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1477
diff changeset
    51
------------------------------------------------
a653ec78b1b8 Find variable/function/feature by name or value.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1477
diff changeset
    52
::
a653ec78b1b8 Find variable/function/feature by name or value.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1477
diff changeset
    53
a653ec78b1b8 Find variable/function/feature by name or value.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1477
diff changeset
    54
  (apropos-value "PATT")
a653ec78b1b8 Find variable/function/feature by name or value.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1477
diff changeset
    55
  (apropos-variable "PATT")
a653ec78b1b8 Find variable/function/feature by name or value.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1477
diff changeset
    56
  (apropos-function "PATT")
a653ec78b1b8 Find variable/function/feature by name or value.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1477
diff changeset
    57
  (apropos-library "PATT")
a653ec78b1b8 Find variable/function/feature by name or value.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1477
diff changeset
    58
  (apropos-documentation "PATT")
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    59
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    60
Debugging.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    61
==========
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    62
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    63
Evaluating elisp expression on the fly.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    64
---------------------------------------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    65
1477
652e9d14c7cc Fix RST syntax.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1476
diff changeset
    66
Type ``M-:`` than lisp expression than type ``RET``.
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    67
1477
652e9d14c7cc Fix RST syntax.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1476
diff changeset
    68
Or in any buffer place point at the end of lisp expression and type ``C-x C-e``.
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    69
1477
652e9d14c7cc Fix RST syntax.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1476
diff changeset
    70
Or invoke elisp "shell" by ``M-x ielm``.
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    71
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    72
What functions and variables Emacs load and from which files?
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    73
-------------------------------------------------------------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    74
1189
78104ca7c163 symbol-file
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1143
diff changeset
    75
See value of variable ``load-history`` (by C-h v load-history RET)::
78104ca7c163 symbol-file
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1143
diff changeset
    76
1653
f9aae584ecb4 symbol-file, http://stackoverflow.com/a/27755252/173149
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1652
diff changeset
    77
  (symbol-file 'scheme 'provide)        ; Who provide feature.
f9aae584ecb4 symbol-file, http://stackoverflow.com/a/27755252/173149
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1652
diff changeset
    78
  (symbol-file 'nxml-mode-hook 'defvar) ; Where variable defined.
f9aae584ecb4 symbol-file, http://stackoverflow.com/a/27755252/173149
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1652
diff changeset
    79
  (symbol-file 'message-send 'defun)    ; Where function defined.
1654
f361c89e693f Look for symbol despite its type.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1653
diff changeset
    80
  (symbol-file 'scheme)  ; Look for symbol despite its type.
1476
f437a8297ba2 locate-library
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1420
diff changeset
    81
  load-history
f437a8297ba2 locate-library
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1420
diff changeset
    82
  (locate-library "gnus.el")
1653
f9aae584ecb4 symbol-file, http://stackoverflow.com/a/27755252/173149
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1652
diff changeset
    83
  (find-lisp-object-file-name 'c-mode (symbol-function 'c-mode))
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    84
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    85
Using edebug.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    86
-------------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    87
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    88
Execute ``M-x edebug-defun`` (also on ``C-u C-M-x``) on defun in source code to
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    89
enable debugging for desired function. When next time this function invoked
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    90
you entered to its debugging (jumped to its source code).
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    91
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    92
To start debug execute code which used debugged function.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    93
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    94
You can disable edebug on a function by evaluating the function again using
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    95
``C-M-x``.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    96
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    97
How debug func?
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    98
---------------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
    99
2125
754abf10c819 Fixed wording.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1952
diff changeset
   100
Use ``M-x debug-on-entry`` and ``M-x cancel-debug-on-entry`` to control which
754abf10c819 Fixed wording.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1952
diff changeset
   101
functions will enter the debugger when called. Next time that function loaded in
754abf10c819 Fixed wording.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1952
diff changeset
   102
debug-mode.
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   103
1274
3860a2e28d4d How to print a trace.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1266
diff changeset
   104
You can use ``(debug)`` in your function to automatically enter to debugger.
3860a2e28d4d How to print a trace.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1266
diff changeset
   105
3860a2e28d4d How to print a trace.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1266
diff changeset
   106
You can use ``(backtrace)`` to print a trace of Lisp function.
3860a2e28d4d How to print a trace.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1266
diff changeset
   107
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   108
How debug ini file?
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   109
-------------------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   110
1477
652e9d14c7cc Fix RST syntax.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1476
diff changeset
   111
When your ini has a bug, or when you load external files that cause errors, the
652e9d14c7cc Fix RST syntax.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1476
diff changeset
   112
bug is often hard to find, because the Emacs Lisp reader does not know about
652e9d14c7cc Fix RST syntax.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1476
diff changeset
   113
line numbers and files - it just knows an error happened, and that's it.
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   114
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   115
Try run Emacs with ``--debug-init`` to see backtrace.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   116
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   117
How debug long running command?
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   118
-------------------------------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   119
2125
754abf10c819 Fixed wording.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1952
diff changeset
   120
Remember Emacs elisp interpreter single threaded. To interrupt long running
754abf10c819 Fixed wording.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1952
diff changeset
   121
command press ``C-g``. Sometime it should be typed several times.
754abf10c819 Fixed wording.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1952
diff changeset
   122
754abf10c819 Fixed wording.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1952
diff changeset
   123
On ``toggle-debug-on-quit`` or ``M-x debug-on-quit RET`` on ``C-g`` Emacs enter
754abf10c819 Fixed wording.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1952
diff changeset
   124
to debug mode.
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   125
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   126
Check if bug in ini file not in Emacs itself.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   127
---------------------------------------------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   128
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   129
First run Emacs without loading anything::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   130
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   131
  $ emacs --no-init-file --no-site-file
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   132
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   133
or more shortly (as ``-Q`` imply ``-q``, ``--no-site-file``, and ``--no-splash``
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   134
together)::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   135
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   136
  $ emacs -Q
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   137
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   138
If bug not reproduced bug lies in ini files!
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   139
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   140
Debug by binary search.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   141
-----------------------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   143
Select half of the file in a region, and M-x eval-region. Depending on whether
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   144
that causes the error or not, split this half or the other half again, and
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   145
repeat.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   146
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   147
Simplified Binary Search.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   148
~~~~~~~~~~~~~~~~~~~~~~~~~
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   149
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   150
Add (error ``No error until here``) in the middle of your file. If you get the
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   151
error ``No error until here`` when reloading the file, move the expression
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   152
towards the back of the file, otherwise towards the front of the file.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   153
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   154
Elisp debug tips.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   155
-----------------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   156
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   157
* Use a keyboard macro that moves forward one expression (sexp) and evaluates it.
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   158
* Try C-x check-parens.
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   159
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   160
Enable debug mode (also on loading).
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   161
------------------------------------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   162
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   163
Set in source::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   164
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   165
  (setq debug-on-error t)
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   166
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   167
or invoke Emacs like::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   168
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   169
  $ emacs --debug-init
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   170
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   171
where ``--debug-init`` binds ``debug-on-error`` to ``t`` while loading the init
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   172
file, and bypasses the ``condition-case`` which normally catches errors in the
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   173
init file.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   174
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   175
Call tree.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   176
----------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   177
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   178
Before byte compiling file execute::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   179
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   180
  (setq byte-compile-generate-call-tree t)
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   181
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   182
Veiw buffer local variables.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   183
----------------------------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   184
::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   185
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   186
  (pp (buffer-local-variables))
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   187
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   188
Emacs profiling.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   189
================
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   190
1952
b01bfc6caae7 Emacs profiling with edebug.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1945
diff changeset
   191
edebug
b01bfc6caae7 Emacs profiling with edebug.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1945
diff changeset
   192
------
b01bfc6caae7 Emacs profiling with edebug.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1945
diff changeset
   193
b01bfc6caae7 Emacs profiling with edebug.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1945
diff changeset
   194
``edebug`` allow save execution statistic on per line basis. As usual evaluate
b01bfc6caae7 Emacs profiling with edebug.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1945
diff changeset
   195
``C-u M-S-x`` (or ``M-x edebug-defun``) on top lovel functional form. Call code
b01bfc6caae7 Emacs profiling with edebug.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1945
diff changeset
   196
that uses examined function. On entry to ``edebug`` type ``c``
b01bfc6caae7 Emacs profiling with edebug.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1945
diff changeset
   197
(``edebug-continue-mode``). After finishing evaluation place cursor to examined
b01bfc6caae7 Emacs profiling with edebug.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1945
diff changeset
   198
function form and evaluate ``M-x edebug-display-freq-count``. Function be
b01bfc6caae7 Emacs profiling with edebug.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1945
diff changeset
   199
annotated with evaluation counts per line.
b01bfc6caae7 Emacs profiling with edebug.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1945
diff changeset
   200
b01bfc6caae7 Emacs profiling with edebug.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1945
diff changeset
   201
benchmark.el
b01bfc6caae7 Emacs profiling with edebug.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1945
diff changeset
   202
------------
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   203
::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   204
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   205
  (benchmark-run 1 (revert-buffer))
1207
b014c71fdb7d benchmark.el
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1189
diff changeset
   206
  (benchmark-run-compiled 1 (hi-lock-face-phrase-buffer "hello" 'hi-yellow))
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   207
1952
b01bfc6caae7 Emacs profiling with edebug.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1945
diff changeset
   208
elp.el
b01bfc6caae7 Emacs profiling with edebug.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1945
diff changeset
   209
------
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   210
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   211
Enter a prefix for ``M-x elp-instrument-package``, perform action and see result
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   212
by ``M-x elp-results``. To perform new measurement don't forget to run
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   213
``M-x elp-reset-all``.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   214
1945
dbcf75d07a68 Validating Elisp code
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1912
diff changeset
   215
Validating Elisp code
dbcf75d07a68 Validating Elisp code
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1912
diff changeset
   216
=====================
dbcf75d07a68 Validating Elisp code
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1912
diff changeset
   217
::
dbcf75d07a68 Validating Elisp code
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1912
diff changeset
   218
dbcf75d07a68 Validating Elisp code
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1912
diff changeset
   219
   (checkdoc)
dbcf75d07a68 Validating Elisp code
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1912
diff changeset
   220
   (byte-compile-file (buffer-file-name))
dbcf75d07a68 Validating Elisp code
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1912
diff changeset
   221
   (package-buffer-info)
dbcf75d07a68 Validating Elisp code
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1912
diff changeset
   222
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   223
WWW.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   224
====
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   225
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   226
Text based WWW browser.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   227
-----------------------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   228
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   229
* http://en.wikipedia.org/wiki/W3m
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   230
* http://emacs-w3m.namazu.org/
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   231
* http://www.gnu.org/software/w3/
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   232
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   233
Tricks.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   234
=======
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   235
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   236
Sort and uniquify lines.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   237
------------------------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   238
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   239
Select region, type ``C-u M-| sort -u RET``.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   240
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   241
With transient-mark-mode and delete-selection-mode enabled: select region,
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   242
type M-| sort -u RET to replace selection with sorted and uniquified lines.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   243
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   244
Determining running environment/platform.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   245
=========================================
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   246
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   247
Check variables::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   248
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   249
  emacs-major-version
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   250
  emacs-minor-version
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   251
  window-system             - ``nil`` if in terminal, ``w32`` if native Windows build, ``x`` if under X Window
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   252
  window-system-version     - for windows only
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   253
  window-size-fixed
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   254
  operating-system-release  - release of the operating system Emacs is running on
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   255
  system-configuration      - like configuration triplet: cpu-manufacturer-os
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   256
  system-configuration-options
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   257
  system-name               - host name of the machine you are running on
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   258
  system-time-locale
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   259
  system-type               - indicating the type of operating system you are using:
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   260
                              ``gnu`` (GNU Hurd),
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   261
                              ``gnu/linux``,
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   262
                              ``gnu/kfreebsd``, ``berkeley-unix`` for (FreeBSD),
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   263
                              ``darwin`` (GNU-Darwin, Mac OS X),
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   264
                              ``ms-dos``,
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   265
                              ``windows-nt``,
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   266
                              ``cygwin``
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   267
  system-uses-terminfo
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   268
  dynamic-library-alist or deprecated image-library-alist
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   269
                            - alist of image types vs external libraries needed to display them
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   270
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   271
and check functions::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   272
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   273
  (fboundp ...)             - return t if SYMBOL's function definition is not void
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   274
  (featurep ...)            - returns t if FEATURE is present in this Emacs
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   275
  (display-graphic-p)       - return non-nil if DISPLAY is a graphic display; graphical
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   276
                              displays are those which are capable of displaying several
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   277
                              frames and several different fonts at once
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   278
  (display-multi-font-p)    - same as ``display-graphic-p``
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   279
  (display-multi-frame-p)   - same as ``display-graphic-p``
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   280
  (display-color-p)         - return t if DISPLAY supports color
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   281
  (display-images-p)        - return non-nil if DISPLAY can display images
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   282
  (display-grayscale-p)     - return non-nil if frames on DISPLAY can display shades of gray
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   283
  (display-mouse-p)         - return non-nil if DISPLAY has a mouse available
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   284
  (display-popup-menus-p)   - return non-nil if popup menus are supported on DISPLAY
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   285
  (display-selections-p)    - return non-nil if DISPLAY supports selections
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   286
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   287
Run those checks as below::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   288
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   289
  (when window-system ...)
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   290
  (when (eq window-system 'x) ...)
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   291
  (when (>= emacs-major-version 22) ...)
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   292
  (when (fboundp '...) ...)
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   293
  (when (featurep '...) ...)
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   294
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   295
Compiling emacs.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   296
================
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   297
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   298
Windows.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   299
--------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   300
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   301
Get MSYS for POSIX shell and utilities . Get MinGW for GCC. Get Gnuwin32 for
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   302
jpeg, ungif, tiff, xpm, png, zlib libraries.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   303
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   304
Read emacs/nt/INSTALL::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   305
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   306
  $ cmd
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   307
  $ cd emacs\nt
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   308
  $ configure.bat --prefix %INST_ROOT% --with-gcc --cflags -I%GNUWIN32_ROOT%/include --ldflags -L%GNUWIN32_ROOT%/lib  --ldflags -lregex
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   309
  $ make bootstrap
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   310
  $ make info
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   311
  $ make install
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   312
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   313
Documentation.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   314
==============
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   315
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   316
Elisp documentation.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   317
--------------------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   318
::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   319
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   320
  ;;; <file-name>.el --- <one-line-description>
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   321
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   322
  ;; Copyright (C) <years> <person>
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   323
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   324
  ;; Author: <person> <mail>
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   325
  ;; Maintainer: <person> <mail>
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   326
  ;; Created: <date>
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   327
  ;; Version: <version>
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   328
  ;; Keywords: <look for ``finder-by-keyword`` output, separate by comma>
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   329
  ;; URL: <file-location>
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   330
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   331
  ;;; Commentary:
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   332
  <bla-bla-bla>
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   333
  ;;; Code:
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   334
  <lisp-code>
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   335
  ;;; <file-name> ends here
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   336
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   337
See
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   338
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   339
* http://www.gnu.org/software/emacs/elisp-manual/html_node/Library-Headers.html
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   340
* http://www.emacswiki.org/cgi-bin/wiki/ElispAreaConventions
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   341
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   342
CheckDoc.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   343
---------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   344
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   345
CheckDoc checks your EmacsLisp code for errors in documentation and style.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   346
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   347
http://cedet.sourceforge.net/checkdoc.shtml
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   348
  home page before including it into GNU Emacs
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   349
http://www.emacswiki.org/emacs/CheckDoc
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   350
  CheckDoc
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   351
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   352
Installing Emacs.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   353
=================
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   354
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   355
From sources.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   356
-------------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   357
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   358
* http://ftp.gnu.org/pub/gnu/emacs
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   359
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   360
Windows.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   361
--------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   362
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   363
http://ftp.gnu.org/pub/gnu/emacs/windows
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   364
  Releases for Windows.
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   365
http://alpha.gnu.org/gnu/emacs/windows
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   366
  Beta releases for Windows.
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   367
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   368
Debian.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   369
-------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   370
::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   371
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   372
  $ apt-get install emacs
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   373
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   374
Emacs paths.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   375
============
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   376
::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   377
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   378
  source-directory data-directory doc-directory exec-directory
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   379
  invocation-directory trash-directory tutorial-directory user-emacs-directory
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   380
  widget-image-directory
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   381
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   382
Emacs games.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   383
============
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   384
::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   385
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   386
  hanoi hanoi-unix life pong tetris gomoku
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   387
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   388
Long lines.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   389
===========
1477
652e9d14c7cc Fix RST syntax.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1476
diff changeset
   390
::
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   391
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   392
  (setq longlines-show-hard-newlines t)
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   393
  (setq longlines-wrap-follows-window-size t)
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   394
  (longlines-mode 1)
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   395
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   396
Printing Emacs structures.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   397
==========================
1477
652e9d14c7cc Fix RST syntax.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1476
diff changeset
   398
::
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   399
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   400
  (message "%S" '(a b 123 "hello" 'set))
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   401
  (pp '(a b 123 "hello" 'set))
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   402
  (prin1-to-string '(1 2))
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   403
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   404
  (symbol-name 'f)
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   405
  (symbol-value 'f)
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   406
  (symbol-function 'f)
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   407
  (symbol-plist 'f)
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   408
1143
3a3389b22964 (local-variable-p var buffer)
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1142
diff changeset
   409
  (local-variable-p var buffer)
3a3389b22964 (local-variable-p var buffer)
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1142
diff changeset
   410
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   411
File manager.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   412
=============
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   413
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   414
* http://www.emacswiki.org/emacs/Sunrise_Commander
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   415
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   416
Semantic.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   417
=========
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   418
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   419
semantic-lex-spp-describe
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   420
  Describe the current list of spp macros.
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   421
semantic-lex-c-preprocessor-symbol-file
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   422
  List of C/C++ files that contain preprocessor macros for the C lexer.
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   423
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   424
Debugging C code.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   425
=================
1477
652e9d14c7cc Fix RST syntax.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1476
diff changeset
   426
::
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   427
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   428
  -*- mode: grep; mode: auto-revert-tail; default-directory: "~/devel/proj" -*-
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   429
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   430
XML modes.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   431
==========
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   432
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   433
XSLT-process.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   434
-------------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   435
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   436
XSLT-process is a minor mode for GNU Emacs/XEmacs which transforms it into a powerful editor with
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   437
XSLT processing and debugging capabilities.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   438
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   439
The mode currently supports two Java XSLT processors:
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   440
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   441
* Saxon - fully supported, including debugging capabilities.
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   442
* Xalan - fully supported, including debugging capabilities.
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   443
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   444
http://xslt-process.sourceforge.net/
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   445
  home page
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   446
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   447
Useful program logging.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   448
=======================
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   449
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   450
Put first line to your log file, you must replace ``default-directory`` to dir where you build
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   451
program::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   452
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   453
  -*- mode: compilation-minor; mode: auto-revert-tail; default-directory: "~/devel/proj" -*-
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   454
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   455
Program must use one of supported by ``compilation-minor-mode`` (see
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   456
``compilation-error-regexp-alist``), like::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   457
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   458
  printf(__FILE__ ":%d: %s\n", __LINE__, msg);  /* msg - user defined string */
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   459
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   460
or in second form (in this case line number included in format string, so easy searchable in
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   461
debugger)::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   462
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   463
  #define NUM2STR(x) STR(x)
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   464
  #define STR(x) #x
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   465
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   466
  printf(__FILE__ ":" NUM2STR(__LINE__) ": %s\n", msg);
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   467
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   468
Or some faster use ``grep-mode``, but you restricted with GNU like error format::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   469
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   470
  -*- mode: grep; mode: auto-revert-tail; default-directory: "~/devel/proj" -*-
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   471
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   472
Edit HTML.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   473
==========
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   474
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   475
* psgml-mode
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   476
* nxml-mode
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   477
* sgml-mode
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   478
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   479
html-helper-mode.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   480
-----------------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   481
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   482
Highlighting, autocompletion, and auto-insertion of closing tags.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   483
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   484
* http://www.emacswiki.org/emacs/HtmlHelperMode
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   485
* http://savannah.nongnu.org/projects/baol-hth/
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   486
* http://www.nongnu.org/baol-hth/
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   487
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   488
Source.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   489
=======
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   490
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   491
Get main development sources::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   492
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   493
  $ bzr init-repo --2a emacs
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   494
  $ cd emacs
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   495
  $ bzr branch http://bzr.savannah.gnu.org/r/emacs/trunk trunk
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   496
  $ cd trunk
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   497
  $ bzr bind http://bzr.savannah.gnu.org/r/emacs/trunk
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   498
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   499
To update with latest changes::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   500
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   501
  $ cd emacs/trunk
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   502
  $ bzr update
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   503
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   504
See:
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   505
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   506
* http://www.emacswiki.org/emacs/BzrForEmacsDevs
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   507
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   508
Emacs Git mirror.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   509
-----------------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   510
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   511
* http://www.emacswiki.org/emacs/EmacsFromGit
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   512
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   513
Patch.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   514
======
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   515
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   516
http://debbugs.gnu.org/cgi/bugreport.cgi?bug=5719
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   517
  [patch] fix bat-generic-mode highlighting pattern for CLI switch.
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   518
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   519
How report bug.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   520
===============
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   521
1477
652e9d14c7cc Fix RST syntax.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 1476
diff changeset
   522
Visit http://debbugs.gnu.org or ``M-x report-emacs-bug``.
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   523
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   524
Finding emacs packages.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   525
=======================
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   526
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   527
* http://anc.ed.ac.uk/~stephen/emacs/ell.html
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   528
* http://www.emacswiki.org/emacs/WikifiedEmacsLispList
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   529
* http://www.emacswiki.org/emacs/RationalElispPackaging
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   530
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   531
http://tromey.com/elpa/index.html
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   532
  Emacs Lisp Package Archive
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   533
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   534
EPLA.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   535
-----
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   536
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   537
ELPA goal is to make it simple to install, use, and upgrade Emacs Lisp packages.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   538
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   539
Currently (2011-02-15) available such sources::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   540
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   541
  (setq package-archives '(("ELPA" . "http://tromey.com/elpa/")
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   542
                           ("gnu" . "http://elpa.gnu.org/packages/")
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   543
                           ("marmalade" . "http://marmalade-repo.org/packages/")
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   544
                           ))
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   545
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   546
* http://www.emacswiki.org/emacs/ELPA
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   547
* http://marmalade-repo.org/
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   548
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   549
http://elpa.gnu.org/
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   550
  official GNU Emacs Lisp Package Archive
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   551
http://tromey.com/elpa/
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   552
  old Emacs Lisp Package Archive home page
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   553
http://tromey.com/elpa/upload.html
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   554
  how to contribute
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   555
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   556
Emacswiki.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   557
----------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   558
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   559
* http://www.emacswiki.org/emacs/ElispArea
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   560
* http://www.emacswiki.org/emacs/WikifiedEmacsLispList
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   561
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   562
emacsmirror.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   563
------------
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   564
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   565
* https://github.com/emacsmirror/p/wiki
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   566
* http://www.emacsmirror.org/
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   567
* http://www.emacswiki.org/emacs/Emacsmirror
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   568
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   569
Funny Emacs modes.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   570
==================
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   571
2228
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   572
glasses
837f1337c59b Removed indentation that compiled into <blockquote>.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents: 2125
diff changeset
   573
  Minor mode for making identifiers likeThis readable.
1142
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   574
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   575
Useful commands.
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   576
================
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   577
::
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   578
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   579
  flush-lines keep-lines
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   580
  align-regexp
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   581
  C-x C-o
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   582
  M-PageUp/M-PageDown
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   583
  command-history
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   584
  M-=
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   585
  C-x l
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   586
  locate-library find-library
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   587
  features load-history
3059b0c6c39a symbol-plist
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
diff changeset
   588