Team Ai
Datasetpublic

codekingpro/portable-devtools

sourceHugging Faceupdated 5mo agoView on Hugging Face
1likes14kdownloads
nanorc354 linesDownload Raw Back to etc
1## Sample initialization file for GNU nano.2##3## For the options that take parameters, the default value is shown.4## Other options are unset by default.  To make sure that an option5## is disabled, you can use "unset <option>".6##7## Characters that are special in a shell should not be escaped here.8## Inside string parameters, quotes should not be escaped -- the last9## double quote on the line will be seen as the closing quote.10 11## If you want ^F, ^B, M-F and M-B to do what they did before version 8.0:12# bind ^F forward main13# bind ^B back main14# bind M-F formatter main15# bind M-B linter main16 17## Make M-< and M-> switch between buffers, as they did before version 9.0:18# bind M-< prevbuf main19# bind M-> nextbuf main20 21## Make 'nextword' (Ctrl+Right) and 'chopwordright' (Ctrl+Delete)22## stop at word ends instead of at beginnings.23# set afterends24 25## When soft line wrapping is enabled, make it wrap lines at blanks26## (tabs and spaces) instead of always at the edge of the screen.27# set atblanks28 29## Automatically indent a newly created line to the same number of30## tabs and/or spaces as the preceding line -- or as the next line31## if the preceding line is the beginning of a paragraph.32# set autoindent33 34## Back up files to the current filename plus a tilde.35# set backup36 37## The directory to put unique backup files in.38# set backupdir ""39 40## Use bold text instead of reverse video text.41# set boldtext42 43## Treat any line with leading whitespace as the beginning of a paragraph.44# set bookstyle45 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## Automatically hard-wrap the current line when it becomes overlong.52# set breaklonglines53 54## Do case-sensitive searches by default.55# set casesensitive56 57## Interpret digits after a colon after a filename (on the command line)58## as the line number to go to in that file.59# set colonparsing60 61## Constantly report the cursor position, in the status bar or minibar.62# set constantshow63 64## Use cut-from-cursor-to-end-of-line by default.65# set cutfromcursor66 67## Do not use the line below the title bar, leaving it entirely blank.68# set emptyline69 70## Set the target width for automatic hard-wrapping and for justifying71## paragraphs.  If the specified value is 0 or less, the wrapping point72## will be the terminal's width minus this number.73# set fill -874 75## Draw a vertical stripe at the given column, to help judge text width.76## (This option does not have a default value.)77# set guidestripe 7578 79## Remember the used search/replace/command strings for the next session.80# set historylog81 82## Display a "scrollbar" on the righthand side of the edit window.83# set indicator84 85## Scroll the buffer contents per half-screen instead of per line.86# set jumpyscrolling87 88## Display line numbers to the left (and any anchors in the margin).89# set linenumbers90 91## Let other users (of nano or vim) know that you are editing the file92## they are trying to edit, and the other way around.93# set locking94 95## Fall back to slow libmagic to try and determine an applicable syntax.96# set magic97 98## The opening and closing brackets that are found by a matching-bracket99## search.  This may not contain blank characters.  The opening brackets100## must come before the closing ones, and they must be in the same order.101# set matchbrackets "(<[{)>]}"102 103## Suppress the title bar and show the filename plus a cursor-position104## percentage in the space of the status bar.105# set minibar106 107## Enable mouse support, if available for your system.  When enabled,108## mouse clicks can be used to place the cursor, set the mark (with109## two clicks), and execute shortcuts.  The mouse will work in the110## X Window System, and on the console when gpm is running.111# set mouse112 113## Switch on multiple file buffers (inserting a file will put it into114## a separate buffer).115# set multibuffer116 117## Don't convert files from DOS/Mac format.118# set noconvert119 120## Don't display the helpful shortcut lists at the bottom of the screen.121# set nohelp122 123## Don't automatically add a newline when a file does not end with one.124# set nonewlines125 126## Set operating directory.  nano will not read or write files outside127## this directory and its subdirectories.  Also, the current directory128## is changed to here, so any files are inserted from this dir.  A blank129## string means the operating-directory feature is turned off.130# set operatingdir ""131 132## Remember the position of cursor and anchors for the next editing session.133# set positionlog134 135## Preserve the XON and XOFF keys (^Q and ^S).136# set preserve137 138## The characters treated as closing punctuation when justifying paragraphs.139## This may not contain blank characters.  Only these terminating characters,140## optionally followed by closing brackets, can end sentences.141# set punct "!.?"142 143## Make status-bar messages disappear after 1 keystroke instead of after 20.144# set quickblank145 146## The regular expression that matches quoting characters in email147## or line-comment introducers in source code.  The default is:148# set quotestr "^([ 	]*([!#%:;>|}]|//))+"149 150## Try to work around a mismatching terminfo terminal description.151# set rawsequences152 153## Fix Backspace/Delete confusion problem.154# set rebinddelete155 156## Do regular-expression searches by default.157## Regular expressions are of the extended type (ERE).158# set regexp159 160## Save a changed buffer automatically on exit; don't prompt.161# set saveonexit162 163## Put the cursor on the highlighted item in the file browser, and164## show the cursor in the help viewer; useful for people who use a165## braille display and people with poor vision.166# set showcursor167 168## Make the Home key smarter: when Home is pressed anywhere but at the169## very beginning of non-whitespace characters on a line, the cursor170## will jump to that beginning (either forwards or backwards).  If the171## cursor is already at that position, it will jump to the true start172## of the line (the left edge).173# set smarthome174 175## Spread overlong lines over multiple screen lines.176# set softwrap177 178## Scroll only the current line sideways (instead of all lines).179# set solosidescroll180 181## Use this spelling checker instead of the internal one.  This option182## does not have a default value.183# set speller "aspell -x -c"184 185## Use the end of the title bar for some state flags: I = auto-indenting,186## M = mark, L = hard-wrapping long lines, R = recording, S = soft-wrapping.187# set stateflags188 189## Use this tab size instead of the default; it must be greater than 0.190# set tabsize 8191 192## Convert each typed tab to the fitting number of spaces.193# set tabstospaces194 195## Snip whitespace at the end of lines when justifying or hard-wrapping.196# set trimblanks197 198## Save files by default in Unix format (also when they were DOS or Mac).199# set unix200 201## The two single-column characters used to display the first characters202## of tabs and spaces.  187 in ISO 8859-1 (0000BB in Unicode) and 183 in203## ISO-8859-1 (0000B7 in Unicode) seem to be good values for these.204## The default when in a UTF-8 locale:205# set whitespace "»·"206## The default otherwise:207# set whitespace ">."208 209## Detect word boundaries differently by treating punctuation210## characters as parts of words.211# set wordbounds212 213## The characters (besides alphanumeric ones) that should be considered214## as parts of words.  This option does not have a default value.  When215## set, it overrides option 'set wordbounds'.216# set wordchars "<_>."217 218## Let an unmodified Backspace or Delete erase the marked region (instead219## of a single character, and without affecting the cutbuffer).220# set zap221 222## Hide the bars plus help lines and use the whole terminal as edit area.223# set zero224 225 226## Paint the interface elements of nano.  These are examples; there are227## no colors by default, except for errorcolor and spotlightcolor.228set titlecolor bold,white,blue229set promptcolor lightwhite,grey230set statuscolor bold,white,green231set errorcolor bold,white,red232set spotlightcolor black,lightyellow233set selectedcolor lightwhite,#804234set stripecolor ,#444235set scrollercolor slate,#222236set numbercolor cyan237set keycolor cyan238set functioncolor green239 240## In root's .nanorc you might want to use:241# set titlecolor bold,white,magenta242# set promptcolor black,yellow243# set statuscolor bold,white,magenta244# set errorcolor bold,white,red245# set spotlightcolor black,orange246# set selectedcolor lightwhite,cyan247# set stripecolor ,yellow248# set scrollercolor magenta249# set numbercolor magenta250# set keycolor lightmagenta251# set functioncolor magenta252 253 254## === Syntax coloring ===255## For all details, see 'man nanorc', section SYNTAX HIGHLIGHTING.256 257## To include most of the existing syntax definitions, you can do:258include /usr/share/nano/*.nanorc259 260## Or you can select just the ones you need.  For example:261# include /usr/share/nano/html.nanorc262# include /usr/share/nano/python.nanorc263# include /usr/share/nano/sh.nanorc264 265## In /usr/share/nano/extra/ you can find some syntaxes that are266## specific for certain distros or for some less common languages.267 268 269## If <Tab> should always produce four spaces when editing a Python file,270## independent of the settings of 'tabsize' and 'tabstospaces':271# extendsyntax python tabgives "    "272 273 274## === Key bindings ===275## For all details, see 'man nanorc', section REBINDING KEYS.276 277## If you want to suspend nano with one keystroke (instead of with ^T^Z):278# bind ^Z suspend main279 280## The <Ctrl+Delete> keystroke deletes the word to the right of the cursor.281## On some terminals the <Ctrl+Backspace> keystroke produces ^H, which is282## the ASCII character for backspace, so it is bound by default to the283## backspace function.  The <Backspace> key itself produces a different284## keycode, which is hard-bound to the backspace function.  So, if you285## normally use <Backspace> for backspacing and not ^H, you can make286## <Ctrl+Backspace> delete the word to the left of the cursor with:287# bind ^H chopwordleft main288 289## For a more mnemonic Comment keystroke (overriding Cut-from-cursor):290# bind M-K comment main291 292## If you want ^L to just refresh the screen and not center the cursor:293# bind ^L refresh main294 295## When you sometimes type M-J instead of M-K, or M-T instead of M-R:296# unbind M-J main297# unbind M-T main298## (Those functions are still accessible through ^T^J and ^T^V.)299 300## For quickly uppercasing or lowercasing the word that the cursor is on.301## (These effectively select a word and pipe it through a sed command.)302# bind Sh-M-U "{nextword}{mark}{prevword}{execute}| sed 's/.*/\U&/' {enter}" main303# bind Sh-M-L "{nextword}{mark}{prevword}{execute}| sed 's/.*/\L&/' {enter}" main304 305## For copying a marked region to the system clipboard:306# bind Sh-M-C "{execute}| xsel -ib {enter}{undo}" main307 308## For copying text to the local clipboard via OSC 52 (if terminal supports it):309# bind M-* "{execute}|| printf "\033]52;c;%s\007" "$(base64 | tr -d '\n')" {enter}{undo}" main310 311## For normalizing Unicode to precomposed characters:312# bind Sh-M-N "{execute}| uconv -x nfc {enter}" main313 314## For wiping all anchors in a buffer:315# bind Sh-M-W "{execute}| cat {enter}" main316 317## For snipping trailing blanks when you save a file:318# bind ^S "{execute}| sed 's/\s\+$//' {enter}{savefile}" main319 320## If you would like nano to have keybindings that are more "usual",321## such as ^O for Open, ^F for Find, ^H for Help, and ^Q for Quit,322## then uncomment these:323# bind ^X cut main324# bind ^C copy main325# bind ^V paste all326# bind ^Q exit all327# bind ^S savefile main328# bind ^W writeout main329# bind ^O insert main330# set multibuffer331# bind ^H help all332# bind ^H exit help333# bind ^F whereis all334# bind ^G findnext all335# bind ^B wherewas all336# bind ^D findprevious all337# bind ^R replace main338# unbind ^U all339# unbind ^N main340# unbind ^Y all341# unbind M-J main342# unbind M-T main343# bind ^A mark main344# bind ^P location main345# bind ^T gotoline main346# bind ^T gotodir browser347# bind ^T cutrestoffile execute348# bind ^L linter execute349# bind ^E execute main350# bind ^K "{mark}{end}{zap}" main351# bind ^U "{mark}{home}{zap}" main352# bind ^Z undo main353# bind ^Y redo main354 
codekingpro/portable-devtools · Team Ai