bugGNU nano - Bugs: bug #57547, [Request] add an option to read...

 
 

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

bug #57547: [Request] add an option to read the nanorc file from a custom path

Submitted by:  Saagar Jha <saagarjha>
Submitted on:  Tue 07 Jan 2020 03:34:27 AM UTC  
 
Severity:  1 - Wish Status:  Fixed
Assigned to:  Benno Schulenberg <bens> Open/Closed:  Closed

( Jump to the original submission)

Sun 09 Feb 2020 10:26:35 AM UTC, comment #8: 

The --rcfile feature has been released in version 4.8.  Thanks for posting.

Benno Schulenberg <bens>
Project AdministratorIn charge of this item.
Fri 17 Jan 2020 03:58:41 PM UTC, comment #7: 

(Oh, it still needs the documentation.  I'll do that later.)

Benno Schulenberg <bens>
Project AdministratorIn charge of this item.
Fri 17 Jan 2020 03:57:24 PM UTC, comment #6: 

The patch has been pushed to master, commit 343f97b3.  Thanks for testing.

Benno Schulenberg <bens>
Project AdministratorIn charge of this item.
Fri 17 Jan 2020 09:40:41 AM UTC, comment #5: 

The new patch looks good to me. Thanks for working on this!

Saagar Jha <saagarjha>
Thu 16 Jan 2020 01:04:12 PM UTC, comment #4: 

(Patches on a mailing list tend to acquire DOS line endings, so you first have to strip those \r codes, for example with nano: open the patch, then ^O M-D <Enter> ^X).

Benno Schulenberg <bens>
Project AdministratorIn charge of this item.
Thu 16 Jan 2020 12:51:44 PM UTC, comment #3: 

Thanks for the feedback.  Attached is an improved version, with an error message for a non-existent file.  I've chosen to let it die when the specified rcfile does not exist, similar to when a specified operating dir or backup dir does not exist.

(file #48238)

Benno Schulenberg <bens>
Project AdministratorIn charge of this item.
Wed 15 Jan 2020 08:39:49 PM UTC, comment #2: 

I couldn't figure out how to apply the patch in the email you sent yesterday, but the one here applied cleanly so I took it for a spin. It works great, but on thing I noticed is that it won't warn you if you pass in a file that doesn't exist: it'll just silently start up without reading anything. Maybe it should show an error in the status bar, similar to the one you'd get if there are errors in the nanorc file?

Saagar Jha <saagarjha>
Wed 15 Jan 2020 06:03:37 PM UTC, comment #1: 

Attached patch allows using -f somenanorcfile or --rcfile=somenanorcfile to load a custom nanorc file and skip the loading of /etc/nanorc and ~/.nanorc.  Please test and/or comment.

(file #48235)

Benno Schulenberg <bens>
Project AdministratorIn charge of this item.
Tue 07 Jan 2020 03:34:27 AM UTC, original submission:  

It would be nice if it was possible to have nano load the nanorc file from a custom path specified via a command line option. Some additional side effects beyond the obvious ones would be making it possible to prevent the default loading of /etc/nanorc, or allow for dynamically swapping between multiple configurations.

Saagar Jha <saagarjha>

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by bens (Updated the item)
  • -email is unavailable- added by saagarjha (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

     

     

    Follow 8 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2020-02-09 bens Open/ClosedOpen => Closed
    2020-01-17 bens StatusIn Progress => Fixed
    2020-01-16 bens Attached File- => Added 0001-new-feature-allow-specifying-a-custom-nanorc-file-on.patch, #48238
    2020-01-15 bens Attached File- => Added 0001-new-feature-allow-specifying-a-custom-nanorc-file-on.patch, #48235
        Severity3 - Normal => 1 - Wish
        StatusNone => In Progress
        Assigned toNone => bens
        Summary[Request] Add an option to read the nanorc file from a custom path => [Request] add an option to read the nanorc file from a custom path

    Back to the top


    Powered by Savane 3.5