Project

General

Profile

Actions

Nano

Nano is a free text editor on Unix-like system, using a command line interface.
To configure nano as you want, edit .nanorc file in /usr/share/nano directory (all users) or in the home user (for one user only).

Note : if you are on MS Windows, you can get a MS Windows version. For that, go to the nano web site (see above) and select Download > Get nano.

Syntax highlighting

Edit the .nanorc file in /usr/share/nano directory (or create it, if any).
Add it these lines (you can adpat them at your convenience)

## Here is an example for Scol/Pkg.
##
syntax "scol" "\.pkg$" "\.scol$" 

## Types
color brightred "\<(typeof|var|typedef|defcom|defcomvar|struct|S|I|F|r1|r2|Chn|Srv|Env|Comm;;|;)\>" 

## Functions and instructions
color brightred "\<(fun|proto|exec|match|with|;|;;)\>" 

## Loops and conditions
color brightgreen "\<(if|then|else|while|do)\>" 

## Affectations
color brightcyan "\<(set|let|mutate|in|->|<-)\>" 

## Strings and numbers
color yellow "<[^=       ]*>" ""(\.|[^"])*"" 

##
## Launchers
color blue "[[:space:]]*_load[[:space:]]*" 

## Comment
color green "//.*" 
color green start="/\*" end="\*/

Updated by iri over 11 years ago · 1 revisions