diff --git a/Readme.rst b/Readme.rst index 61f3bfb..2958ca4 100644 --- a/Readme.rst +++ b/Readme.rst @@ -24,3 +24,7 @@ You can also append the contents of ``~/.nano/nanorc`` into your ``~/.nanorc`` to include all languages:: cat ~/.nano/nanorc >> ~/.nanorc + +Finally, you can run an automatic installer using the following code:: + + $ curl https://github.com/scopatz/nanorc/raw/installer.sh | sh diff --git a/install.sh b/install.sh new file mode 100755 index 0000000..6f3ba8e --- /dev/null +++ b/install.sh @@ -0,0 +1,20 @@ +wget -O /tmp/nanorc.zip https://github.com/scopatz/nanorc/archive/master.zip +if [ ! -d ~/.nano/ ] +then + mkdir ~/.nano/ +fi + +cd ~/.nano/ + +unzip -o "/tmp/nanorc.zip" +mv nanorc-master/* ./ +rm -rf nanorc-master + +if [ ! -f ~/.nanorc ] +then + touch ~/.nanorc +fi + +cat ~/.nano/nanorc >> ~/.nanorc +sort -u ~/.nanorc > /tmp/nanorc2 +cat /tmp/nanorc2 > ~/.nanorc diff --git a/nanorc b/nanorc index 2f028ec..864c92b 100644 --- a/nanorc +++ b/nanorc @@ -1,4 +1,5 @@ include ~/.nano/apacheconf.nanorc +include ~/.nano/arduino.nanorc include ~/.nano/asciidoc.nanorc include ~/.nano/asm.nanorc include ~/.nano/awk.nanorc @@ -41,6 +42,7 @@ include ~/.nano/mpdconf.nanorc include ~/.nano/mutt.nanorc include ~/.nano/nanorc.nanorc include ~/.nano/nginx.nanorc +include ~/.nano/ocaml.nanorc include ~/.nano/patch.nanorc include ~/.nano/peg.nanorc include ~/.nano/perl.nanorc @@ -54,6 +56,7 @@ include ~/.nano/python.nanorc include ~/.nano/reST.nanorc include ~/.nano/rpmspec.nanorc include ~/.nano/ruby.nanorc +include ~/.nano/rust.nanorc include ~/.nano/scala.nanorc include ~/.nano/sed.nanorc include ~/.nano/sh.nanorc diff --git a/ocaml.nanorc b/ocaml.nanorc new file mode 100644 index 0000000..6f9fc60 --- /dev/null +++ b/ocaml.nanorc @@ -0,0 +1,25 @@ +syntax "ocaml" "\.mli?$" +#uid +color red "\<[A-Z][0-9a-z_]{2,}\>" +#declarations +color green "\<(let|val|method|in|and|rec|private|virtual|constraint)\>" +#structure items +color red "\<(type|open|class|module|exception|external)\>" +#patterns +color blue "\<(fun|function|functor|match|try|with)\>" +#patterns-modifiers +color yellow "\<(as|when|of)\>" +#conditions +color cyan "\<(if|then|else)\>" +#blocs +color magenta "\<(begin|end|object|struct|sig|for|while|do|done|to|downto)\>" +#constantes +color green "\<(true|false)\>" +#modules/classes +color green "\<(include|inherit|initializer)\>" +#expr modifiers +color yellow "\<(new|ref|mutable|lazy|assert|raise)\>" +#comments +color white start="\(\*" end="\*\)" +#strings (no multiline handling yet) +color brightblack ""[^\"]*""