192 |
- |
1 |
## This is a system-wide configuration file for the nano editor.
|
|
|
2 |
##
|
|
|
3 |
## Each user can save his own configuration to ~/.nanorc
|
|
|
4 |
##
|
|
|
5 |
## See the nanorc(5) man page for details.
|
|
|
6 |
|
|
|
7 |
## Sample initialization file for GNU nano.
|
|
|
8 |
##
|
|
|
9 |
## Please note that you must have configured nano with --enable-nanorc
|
|
|
10 |
## for this file to be read! Also note that this file should not be in
|
|
|
11 |
## DOS or Mac format, and that characters specially interpreted by the
|
|
|
12 |
## shell should not be escaped here.
|
|
|
13 |
##
|
|
|
14 |
## To make sure an option is disabled, use "unset <option>".
|
|
|
15 |
##
|
|
|
16 |
## For the options that take parameters, the default value is given.
|
|
|
17 |
## Other options are unset by default.
|
|
|
18 |
##
|
|
|
19 |
## Quotes inside string parameters don't have to be escaped with
|
|
|
20 |
## backslashes. The last double quote in the string will be treated as
|
|
|
21 |
## its end. For example, for the "brackets" option, ""')>]}" will match
|
|
|
22 |
## ", ', ), >, ], and }.
|
|
|
23 |
|
|
|
24 |
## Make the 'nextword' function (Ctrl+Right) stop at word ends
|
|
|
25 |
## instead of at beginnings.
|
|
|
26 |
# set afterends
|
|
|
27 |
|
|
|
28 |
## When soft line wrapping is enabled, make it wrap lines at blanks
|
|
|
29 |
## (tabs and spaces) instead of always at the edge of the screen.
|
|
|
30 |
# set atblanks
|
|
|
31 |
|
|
|
32 |
## Automatically indent a newly created line to the same number of
|
|
|
33 |
## tabs and/or spaces as the preceding line -- or as the next line
|
|
|
34 |
## if the preceding line is the beginning of a paragraph.
|
|
|
35 |
# set autoindent
|
|
|
36 |
|
|
|
37 |
## Back up files to the current filename plus a tilde.
|
|
|
38 |
# set backup
|
|
|
39 |
|
|
|
40 |
## The directory to put unique backup files in.
|
|
|
41 |
# set backupdir ""
|
|
|
42 |
|
|
|
43 |
## Use bold text instead of reverse video text.
|
|
|
44 |
# set boldtext
|
|
|
45 |
|
|
|
46 |
## The characters treated as closing brackets when justifying paragraphs.
|
|
|
47 |
## This may not include any blank characters. Only closing punctuation,
|
|
|
48 |
## optionally followed by these closing brackets, can end sentences.
|
|
|
49 |
# set brackets ""')>]}"
|
|
|
50 |
|
|
|
51 |
## Do case-sensitive searches by default.
|
|
|
52 |
# set casesensitive
|
|
|
53 |
|
|
|
54 |
## Constantly display the cursor position in the status bar. Note that
|
|
|
55 |
## this overrides "quickblank".
|
|
|
56 |
# set constantshow
|
|
|
57 |
|
|
|
58 |
## Use cut-from-cursor-to-end-of-line by default.
|
|
|
59 |
# set cutfromcursor
|
|
|
60 |
## (The old form, 'cut', is deprecated.)
|
|
|
61 |
|
|
|
62 |
## Set the line length for wrapping text and justifying paragraphs.
|
|
|
63 |
## If the value is 0 or less, the wrapping point will be the screen
|
|
|
64 |
## width less this number.
|
|
|
65 |
# set fill -8
|
|
|
66 |
|
|
|
67 |
## Remember the used search/replace strings for the next session.
|
|
|
68 |
# set historylog
|
|
|
69 |
|
|
|
70 |
## Display line numbers to the left of the text.
|
|
|
71 |
# set linenumbers
|
|
|
72 |
|
|
|
73 |
## Enable vim-style lock-files. This is just to let a vim user know you
|
|
|
74 |
## are editing a file [s]he is trying to edit and vice versa. There are
|
|
|
75 |
## no plans to implement vim-style undo state in these files.
|
|
|
76 |
# set locking
|
|
|
77 |
|
|
|
78 |
## The opening and closing brackets that can be found by bracket
|
|
|
79 |
## searches. They cannot contain blank characters. The former set must
|
|
|
80 |
## come before the latter set, and both must be in the same order.
|
|
|
81 |
# set matchbrackets "(<[{)>]}"
|
|
|
82 |
|
|
|
83 |
## Use the blank line below the title bar as extra editing space.
|
|
|
84 |
# set morespace
|
|
|
85 |
|
|
|
86 |
## Enable mouse support, if available for your system. When enabled,
|
|
|
87 |
## mouse clicks can be used to place the cursor, set the mark (with a
|
|
|
88 |
## double click), and execute shortcuts. The mouse will work in the X
|
|
|
89 |
## Window System, and on the console when gpm is running.
|
|
|
90 |
# set mouse
|
|
|
91 |
|
|
|
92 |
## Switch on multiple file buffers (inserting a file will put it into
|
|
|
93 |
## a separate buffer).
|
|
|
94 |
# set multibuffer
|
|
|
95 |
|
|
|
96 |
## Don't convert files from DOS/Mac format.
|
|
|
97 |
# set noconvert
|
|
|
98 |
|
|
|
99 |
## Don't display the helpful shortcut lists at the bottom of the screen.
|
|
|
100 |
# set nohelp
|
|
|
101 |
|
|
|
102 |
## Don't automatically add a newline when a file does not end with one.
|
|
|
103 |
# set nonewlines
|
|
|
104 |
|
|
|
105 |
## Don't pause between warnings at startup. Which means that only the
|
|
|
106 |
## last one will be readable (when there are multiple ones).
|
|
|
107 |
# set nopauses
|
|
|
108 |
|
|
|
109 |
## Don't wrap text at all.
|
|
|
110 |
set nowrap
|
|
|
111 |
|
|
|
112 |
## Set operating directory. nano will not read or write files outside
|
|
|
113 |
## this directory and its subdirectories. Also, the current directory
|
|
|
114 |
## is changed to here, so any files are inserted from this dir. A blank
|
|
|
115 |
## string means the operating-directory feature is turned off.
|
|
|
116 |
# set operatingdir ""
|
|
|
117 |
|
|
|
118 |
## Remember the cursor position in each file for the next editing session.
|
|
|
119 |
# set positionlog
|
|
|
120 |
|
|
|
121 |
## Preserve the XON and XOFF keys (^Q and ^S).
|
|
|
122 |
# set preserve
|
|
|
123 |
|
|
|
124 |
## The characters treated as closing punctuation when justifying
|
|
|
125 |
## paragraphs. They cannot contain blank characters. Only closing
|
|
|
126 |
## punctuation, optionally followed by closing brackets, can end
|
|
|
127 |
## sentences.
|
|
|
128 |
# set punct "!.?"
|
|
|
129 |
|
|
|
130 |
## Do quick status-bar blanking. Status-bar messages will disappear after
|
|
|
131 |
## 1 keystroke instead of 26. Note that "constantshow" overrides this.
|
|
|
132 |
# set quickblank
|
|
|
133 |
|
|
|
134 |
## The email-quote string, used to justify email-quoted paragraphs.
|
|
|
135 |
## This is an extended regular expression. The default is:
|
|
|
136 |
# set quotestr "^([ ]*([#:>|}]|//))+"
|
|
|
137 |
|
|
|
138 |
## Fix Backspace/Delete confusion problem.
|
|
|
139 |
# set rebinddelete
|
|
|
140 |
|
|
|
141 |
## Fix numeric keypad key confusion problem.
|
|
|
142 |
# set rebindkeypad
|
|
|
143 |
|
|
|
144 |
## Do extended regular expression searches by default.
|
|
|
145 |
# set regexp
|
|
|
146 |
|
|
|
147 |
## Put the cursor on the highlighted item in the file browser;
|
|
|
148 |
## useful for people who use a braille display.
|
|
|
149 |
# set showcursor
|
|
|
150 |
|
|
|
151 |
## Make the Home key smarter. When Home is pressed anywhere but at the
|
|
|
152 |
## very beginning of non-whitespace characters on a line, the cursor
|
|
|
153 |
## will jump to that beginning (either forwards or backwards). If the
|
|
|
154 |
## cursor is already at that position, it will jump to the true
|
|
|
155 |
## beginning of the line.
|
|
|
156 |
# set smarthome
|
|
|
157 |
|
|
|
158 |
## Use smooth scrolling as the default.
|
|
|
159 |
# set smooth
|
|
|
160 |
|
|
|
161 |
## Enable soft line wrapping (AKA full-line display).
|
|
|
162 |
# set softwrap
|
|
|
163 |
|
|
|
164 |
## Use this spelling checker instead of the internal one. This option
|
|
|
165 |
## does not have a default value.
|
|
|
166 |
set speller "hunspell"
|
|
|
167 |
|
|
|
168 |
## Allow nano to be suspended.
|
|
|
169 |
# set suspend
|
|
|
170 |
|
|
|
171 |
## Use this tab size instead of the default; it must be greater than 0.
|
|
|
172 |
# set tabsize 8
|
|
|
173 |
|
|
|
174 |
## Convert typed tabs to spaces.
|
|
|
175 |
# set tabstospaces
|
|
|
176 |
|
|
|
177 |
## Save automatically on exit; don't prompt.
|
|
|
178 |
# set tempfile
|
|
|
179 |
|
|
|
180 |
## Snip whitespace at the end of lines when justifying or hard-wrapping.
|
|
|
181 |
# set trimblanks
|
|
|
182 |
## (The old form, 'justifytrim', is deprecated.)
|
|
|
183 |
|
|
|
184 |
## Disallow file modification. Why would you want this in an rcfile? ;)
|
|
|
185 |
# set view
|
|
|
186 |
|
|
|
187 |
## The two single-column characters used to display the first characters
|
|
|
188 |
## of tabs and spaces. 187 in ISO 8859-1 (0000BB in Unicode) and 183 in
|
|
|
189 |
## ISO-8859-1 (0000B7 in Unicode) seem to be good values for these.
|
|
|
190 |
## The default when in a UTF-8 locale:
|
|
|
191 |
# set whitespace "»·"
|
|
|
192 |
## The default otherwise:
|
|
|
193 |
# set whitespace ">."
|
|
|
194 |
|
|
|
195 |
## Detect word boundaries differently by treating punctuation
|
|
|
196 |
## characters as parts of words.
|
|
|
197 |
# set wordbounds
|
|
|
198 |
|
|
|
199 |
## The characters (besides alphanumeric ones) that should be considered
|
|
|
200 |
## as parts of words. This option does not have a default value. When
|
|
|
201 |
## set, it overrides option 'set wordbounds'.
|
|
|
202 |
# set wordchars "<_>."
|
|
|
203 |
|
|
|
204 |
|
|
|
205 |
## Paint the interface elements of nano. These are examples;
|
|
|
206 |
## by default there are no colors, except for errorcolor.
|
|
|
207 |
# set titlecolor brightwhite,blue
|
|
|
208 |
# set statuscolor brightwhite,green
|
|
|
209 |
# set errorcolor brightwhite,red
|
|
|
210 |
# set selectedcolor brightwhite,magenta
|
|
|
211 |
# set numbercolor cyan
|
|
|
212 |
# set keycolor cyan
|
|
|
213 |
# set functioncolor green
|
|
|
214 |
## In root's .nanorc you might want to use:
|
|
|
215 |
# set titlecolor brightwhite,magenta
|
|
|
216 |
# set statuscolor brightwhite,magenta
|
|
|
217 |
# set errorcolor brightwhite,red
|
|
|
218 |
# set selectedcolor brightwhite,cyan
|
|
|
219 |
# set numbercolor magenta
|
|
|
220 |
# set keycolor brightmagenta
|
|
|
221 |
# set functioncolor magenta
|
|
|
222 |
|
|
|
223 |
|
|
|
224 |
## Setup of syntax coloring.
|
|
|
225 |
##
|
|
|
226 |
## Format:
|
|
|
227 |
##
|
|
|
228 |
## syntax "short description" ["filename regex" ...]
|
|
|
229 |
##
|
|
|
230 |
## The "none" syntax is reserved; specifying it on the command line is
|
|
|
231 |
## the same as not having a syntax at all. The "default" syntax is
|
|
|
232 |
## special: it takes no filename regexes, and applies to files that
|
|
|
233 |
## don't match any other syntax's filename regexes.
|
|
|
234 |
##
|
|
|
235 |
## color foreground,background "regex" ["regex"...]
|
|
|
236 |
## or
|
|
|
237 |
## icolor foreground,background "regex" ["regex"...]
|
|
|
238 |
##
|
|
|
239 |
## "color" will do case-sensitive matches, while "icolor" will do
|
|
|
240 |
## case-insensitive matches.
|
|
|
241 |
##
|
|
|
242 |
## Valid colors: white, black, red, blue, green, yellow, magenta, cyan.
|
|
|
243 |
## For foreground colors, you may use the prefix "bright" to get a
|
|
|
244 |
## stronger highlight.
|
|
|
245 |
##
|
|
|
246 |
## To use multi-line regexes, use the start="regex" end="regex"
|
|
|
247 |
## [start="regex" end="regex"...] format.
|
|
|
248 |
##
|
|
|
249 |
## If your system supports transparency, not specifying a background
|
|
|
250 |
## color will use a transparent color. If you don't want this, be sure
|
|
|
251 |
## to set the background color to black or white.
|
|
|
252 |
##
|
|
|
253 |
## All regexes should be extended regular expressions.
|
|
|
254 |
##
|
|
|
255 |
## If you wish, you may put your syntax definitions in separate files.
|
|
|
256 |
## You can make use of such files as follows:
|
|
|
257 |
##
|
|
|
258 |
## include "/path/to/syntax_file.nanorc"
|
|
|
259 |
##
|
|
|
260 |
## Unless otherwise noted, the name of the syntax file (without the
|
|
|
261 |
## ".nanorc" extension) should be the same as the "short description"
|
|
|
262 |
## name inside that file. These names are kept fairly short to make
|
|
|
263 |
## them easier to remember and faster to type using nano's -Y option.
|
|
|
264 |
##
|
|
|
265 |
## To include all existing syntax definitions, you can do:
|
|
|
266 |
include "/usr/share/nano/*.nanorc"
|
|
|
267 |
|
|
|
268 |
|
|
|
269 |
## Key bindings.
|
|
|
270 |
## See nanorc(5) (section REBINDING KEYS) for more details on this.
|
|
|
271 |
##
|
|
|
272 |
## The following two functions are not bound to any key by default.
|
|
|
273 |
## You may wish to choose other keys than the ones suggested here.
|
|
|
274 |
# bind M-B cutwordleft main
|
|
|
275 |
# bind M-N cutwordright main
|
|
|
276 |
|
|
|
277 |
## Set this if your Backspace key sends Del most of the time.
|
|
|
278 |
# bind Del backspace all
|