Want to subscribe to topics you're interested in?
Become a Member

Extended Syntax Highlighting for Nano Editor

Discussion in 'Centmin Mod News' started by eva2000, Oct 24, 2016.

Thread Status:
Not open for further replies.
  1. eva2000

    eva2000 Administrator Staff Member

    55,223
    12,253
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,831
    Local Time:
    9:02 PM
    Nginx 1.27.x
    MariaDB 10.x/11.4+

    Centmin Mod 123.09beta01 Added Extended Syntax Highlighting for Nano Editor



    Just updated Centmin Mod 123.09beta01 branch code with a new tools/nano-syntax.sh script. Once you update 123.09beta01 via centmin.sh menu option 23 submenu option 2, you can run tools/nano-syntax.sh to enable and install extended syntax highlighting support for nano text editor beyond the native supported syntax highlighting that Centmin Mod 123.09beta01 already now enables :)

    The extended syntax highlighting support includes nginx, GO, ini, javascript, json, markdown, rpmspec, sql, systemd, yaml and yum syntaxes.

    Examples can be see at Which Linux Text Editor do you prefer nano or vim ?

     
  2. eva2000

    eva2000 Administrator Staff Member

    55,223
    12,253
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,831
    Local Time:
    9:02 PM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    More nano syntax highlighting examples after running tools/nano-syntax.sh in Centmin Mod 123.09beta01 branch

    nano-ini.png nano-go.png nano-json.png nano-css.png nano-nginx.png nano-markdown.png nano-sql.png nano-rpmspec.png nano-systemd.png nano-yum.png nano-yaml.png
     
  3. eva2000

    eva2000 Administrator Staff Member

    55,223
    12,253
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,831
    Local Time:
    9:02 PM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    Found a bug in nginx syntax highlighting it seems the curly {} braces color hides them in my SSH window :(

    So need to look into that. Updated 123.09beta01's tools/nano-syntax.sh to disable nginx syntax highlighting for now. So when you re-run tools/nano-syntax.sh it disables nginx syntax highlighting

    Code (Text):
    tools/nano-syntax.sh
    
    Setup Extended Syntax Highlighting for nano editor
    
    Cloning into 'nanorc'...
    remote: Counting objects: 90, done.
    remote: Compressing objects: 100% (83/83), done.
    remote: Total 90 (delta 0), reused 90 (delta 0), pack-reused 0
    Unpacking objects: 100% (90/90), done.
    Generated: build/awk.nanorc
    Generated: build/c.nanorc
    Generated: build/cmake.nanorc
    Generated: build/coffeescript.nanorc
    Generated: build/colortest.nanorc
    Generated: build/csharp.nanorc
    Generated: build/css.nanorc
    Generated: build/cython.nanorc
    Generated: build/default.nanorc
    Generated: build/dot.nanorc
    Generated: build/email.nanorc
    Generated: build/git.nanorc
    Generated: build/glsl.nanorc
    Generated: build/go.nanorc
    Generated: build/html.nanorc
    Generated: build/ini.nanorc
    Generated: build/inputrc.nanorc
    Generated: build/java.nanorc
    Generated: build/javascript.nanorc
    Generated: build/json.nanorc
    Generated: build/keymap.nanorc
    Generated: build/kickstart.nanorc
    Generated: build/ledger.nanorc
    Generated: build/lisp.nanorc
    Generated: build/lua.nanorc
    Generated: build/makefile.nanorc
    Generated: build/man.nanorc
    Generated: build/markdown.nanorc
    Generated: build/mpdconf.nanorc
    Generated: build/nanorc.nanorc
    Generated: build/nginx.nanorc
    Generated: build/patch.nanorc
    Generated: build/peg.nanorc
    Generated: build/php.nanorc
    Generated: build/pkgbuild.nanorc
    Generated: build/pkg-config.nanorc
    Generated: build/po.nanorc
    Generated: build/privoxy.nanorc
    Generated: build/properties.nanorc
    Generated: build/python.nanorc
    Generated: build/rpmspec.nanorc
    Generated: build/ruby.nanorc
    Generated: build/sed.nanorc
    Generated: build/shell.nanorc
    Generated: build/sql.nanorc
    Generated: build/systemd.nanorc
    Generated: build/tex.nanorc
    Generated: build/vala.nanorc
    Generated: build/vi.nanorc
    Generated: build/xml.nanorc
    Generated: build/xresources.nanorc
    Generated: build/yaml.nanorc
    Generated: build/yum.nanorc
    Generated: build/ALL.nanorc
    Installed: /usr/local/share/nano/*.nanorc
    disable nginx.nanorc syntax highlighting
    done...
    

    Looks like i missed a step GitHub - centminmod/nanorc: Improved syntax highlighting for GNU nano

     
    Last edited: Oct 25, 2016
  4. eva2000

    eva2000 Administrator Staff Member

    55,223
    12,253
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,831
    Local Time:
    9:02 PM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    Last edited: Oct 25, 2016
Thread Status:
Not open for further replies.