Monday, April 29, 2024
10
rated 0 times [  10] [ 0]  / answers: 1 / hits: 12580  / 1 Year ago, wed, may 3, 2023, 10:43:33

To indent a whole block of code in nano, after selecting it with alt+a, I have to press alt+{, which doesn't work on my german layout macintosh keyboard (and would be pretty annoying even if it did).



How do I change and customize nano's keyboard shortcuts?


More From » command-line

 Answers
7

The file /etc/nanorc contains some options that should allow you to customize the shortcuts used on the editor. Please note that this is a global config file and will modify the options for all users on your system.



Further details on the available options are given on the man nanorc page (the list is just too big to reproduce here):



enter image description here



It should be possible to keep the options localized only to your user by copying the system configuration file in to your user's home directory with



cp /etc/nanorc ~/.nanorc


and doing the modifications necessary there.



The configuration file on your home directory will prevail over the global settings one.


[#33389] Wednesday, May 3, 2023, 1 Year  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
ingsta

Total Points: 391
Total Questions: 103
Total Answers: 124

Location: Bonaire
Member since Wed, Mar 29, 2023
1 Year ago
ingsta questions
Sun, Oct 23, 22, 01:42, 2 Years ago
Sat, Oct 30, 21, 11:27, 3 Years ago
Sun, Nov 28, 21, 12:49, 2 Years ago
;