bugGNU nano - Bugs: bug #48555, Rust syntax file reports an error...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #48555: Rust syntax file reports an error in nano 2.5 or older

Submitter:  Thomas W. Holleis <twh>
Submitted:  Mon 18 Jul 2016 09:09:00 PM UTC
   
 
Severity:  2 - Minor Status:  Wont Fix
Assigned to:  bens Open/Closed:  Closed

Sat 23 Jul 2016 09:09:05 AM UTC, comment #2: 

Should be marked as "Cant Fix", but Savannah doesn't know that status.

Benno Schulenberg <bens>
Group administrator
Wed 20 Jul 2016 11:56:51 AM UTC, comment #1: 


> It would be very helpful if also older nano versions prior 2.6.1
> can support Rust syntax highlighting out of the box; interesting
> especially for LTS distros.


Are you suggesting that rust.nanorc be added retroactively to all the older tarballs of nano?  If so, this will not happen.  Those things are frozen; they stay what they are.

If you wish distros to include rust.nanorc by default even for nano's before 2.6.1, you should file a request with each of those distros.  (They are unlikely to honor it, though, because the user can easily install the file himself/herself.  If it were something that the user could not fix...)

That older nanos report an error for the comment command, that is to be expected, so it's not a bug.

Benno Schulenberg <bens>
Group administrator
Mon 18 Jul 2016 09:09:00 PM UTC, original submission:  

Since nano 2.6.1 there exists a build-in Rust syntax highlighting (rust.nanorc). Prior 2.6.1 a Rust developer had downloaded the syntax highlighting file from https://github.com/rust-lang/nano-config/blob/master/rust.nanorc and installed it manually.
The problem here is that since 28.06.2016 this file no longer exists because it was moved (and updated) to the nano project http://git.savannah.gnu.org/cgit/nano.git/plain/doc/syntax/rust.nanorc. When try to use this official nano file with an older nano version e.g. 2.5.3 or 2.2.6, following error message will be show during nano startup.

Error in /usr/share/nano/rust.nanorc on line 8: Command "comment" not understood.

This error occur because the new syntax highlighting command "comment" was added to the rust.nanorc file but this command is only supported in nano 2.6.0 or newer.

It would be very helpful if also older nano versions prior 2.6.1 can support Rust syntax highlighting out of the box; interesting especially for LTS distros. This also has the advantage that the workaround to suppress the error messages, using the 'set quiet' option, can be avoided.

See attachments 'rust.nanorc' and 'rust.nanorc.patch' which works for nano 2.2 or higher and was tested with:
nano 2.2.6 on Debian 8.5 (Jessie) and Ubuntu 14.04.4. (Trusty).
nano 2.5.3 on Ubuntu 16.04. (Xenial).

Thomas W. Holleis <twh>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attached Files
file #37942:  rust.nanorc added by twh (1KiB - application/octet-stream)
file #37943:  rust.nanorc.patch added by twh (337B - text/x-diff)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by bens (Posted a comment)
  • -email is unavailable- added by twh (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

     

    Follow 7 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2016-08-29 bens Open/ClosedOpen Closed
    2016-07-23 bens StatusNone Wont Fix
        Assigned toNone bens
    2016-07-20 bens Severity3 - Normal 2 - Minor
        SummaryRust syntax highlighting file raise an error in nano 2.5 or older Rust syntax file reports an error in nano 2.5 or older
    2016-07-18 twh Attached File- Added rust.nanorc, #37942
        Attached File- Added rust.nanorc.patch, #37943

    Back to the top

    Powered by Savane 3.13-02a9.
    Corresponding source code