Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@rkitover
Copy link

@rkitover rkitover commented Jul 27, 2022

Fix #43

For non-elevated users, search for the config file in this order:

  1. %ALLUSERSPROFILE%\nano\nanorc (global)
  2. %SystemRoot%\nanorc (global, for backcompat, should be removed in the future)
  3. %USERPROFILE%.nanorc
  4. %APPDATA%\nano\nanorc

For elevated users, the order is:

  1. %ALLUSERSPROFILE%\nano\elevated_nanorc
  2. %ALLUSERSPROFILE%\nanorc (for backcompat, should be removed later)

Signed-off-by: Rafael Kitover [email protected]

@rkitover rkitover force-pushed the config-updates-again branch from 43908cb to bd6de61 Compare July 27, 2022 04:56
Fix lhmouse#43

For non-elevated users, search for the config file in this order:

1. %ALLUSERSPROFILE%\nano\nanorc (global)
2. %SystemRoot%\nanorc (global, for backcompat, should be removed in the
   future)
3. %USERPROFILE%\.nanorc
4. %APPDATA%\nano\nanorc

For elevated users, the order is:

1. %ALLUSERSPROFILE%\nano\elevated_nanorc
2. %ALLUSERSPROFILE%\nanorc (for backcompat, should be removed later)

Signed-off-by: Rafael Kitover <[email protected]>
@rkitover rkitover force-pushed the config-updates-again branch from bd6de61 to c382f04 Compare July 28, 2022 03:53
@rkitover
Copy link
Author

The logic of the function is a bit disjointed because I tried to keep the original structure, but I can rewrite it if you want.

Also when elevated the global config locations are not checked, they were previously, but I thought if your intent is to separate elevated and non-elevated configs they shouldn't be.

@lhmouse
Copy link
Owner

lhmouse commented Jul 29, 2022

I will have a look a couple of days later.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

discuss config file location improvements

4 participants