You are not logged in.
Pages: 1
Hi!
I try to edit the /etc/sudoers file, so i type in the command:
visudo
And i get the file opened via vi, which is by the way the crappiest
text editor i have ever encountered. I cant even add in the line:
ziga ALL=(ALL) ALL
Thats all i want to do and i can't do it as vi oviously has problems
with synchronisation or what the ****. My keyboard doesn't even listen
to me. This are the problems i encounter:
1st) When i press enter sometimes i get the new line and sometimes i don't
2nd) I can't insert capital letters like in "ADD" as nothing is written in file when i press
a combination of keyboard keys "SHIFT + A", i get "a".
3rd) I can't produce a ")" as it is the same as with capital letters. I get notthing when i
press key combination SHIFT + 9.
Last edited by 71GA (2012-09-16 14:56:01)
C, ARM, ARM assembly, HTML, CSS, JS, Linux
Offline
Maybe nano would be easier for you to use.
# EDITOR=/usr/bin/nano visudo
Just because you don't know how to use it, doesn't make vi crappy btw.
Last edited by WorMzy (2012-09-16 14:08:03)
Sakura:-
Mobo: MSI MAG X570S TORPEDO MAX // Processor: AMD Ryzen 9 5950X @4.9GHz // GFX: AMD Radeon RX 5700 XT // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 6x 1TB SSD, 2x 120GB SSD, 1x 275GB M2 SSD
Making lemonade from lemons since 2015.
Online
I already used nano but Arch Wiki explicitly sugests to use vi.
Just because you don't know how to use it, doesn't make vi crappy btw.
I can't agree with that as good program is allways intuitive. And vi is not.
C, ARM, ARM assembly, HTML, CSS, JS, Linux
Offline
good program is allways intuitive. And vi is not.
OT: I don't need an intuitive (easy to use) app, I need a fast one. That's why I use vim.
Offline
I already used nano but Arch Wiki explicitly sugests to use vi.
Even if it does, that should only be interpreted as a suggestion. The internet police won't come and arrest you because you don't use a specific editor.
Seriously, just use what feels easiest for you. If you want to learn how to use vi though, I suggest installing vim, and running the "vimtutor" program. The stuff in that tutorial will help you understand the basics on how to use both vi and vim.
Last edited by WorMzy (2012-09-16 14:18:15)
Sakura:-
Mobo: MSI MAG X570S TORPEDO MAX // Processor: AMD Ryzen 9 5950X @4.9GHz // GFX: AMD Radeon RX 5700 XT // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 6x 1TB SSD, 2x 120GB SSD, 1x 275GB M2 SSD
Making lemonade from lemons since 2015.
Online
# pacman -Rcunss vi
Offline
I don't understand vi or vim so just use nano instead.
EDITOR=nano visudo
You can also define a default editor in your bashrc
export EDITOR=/usr/bin/nano
and then use
sudo -E visudo
Rauchen verboten
Offline
I don't understand vi or vim so just use nano instead.
EDITOR=nano visudo
You can also define a default editor in your bashrc
export EDITOR=/usr/bin/nano
and then use
sudo -E visudo
In addition to this, you can also specify an editor in the sudoers Defaults.
From man sudoers:
editor A colon (‘:’) separated list of editors allowed to be
used with visudo. visudo will choose the editor that
matches the user's EDITOR environment variable if pos‐
sible, or the first editor in the list that exists and
is executable. The default is /usr/bin/vi.
Sakura:-
Mobo: MSI MAG X570S TORPEDO MAX // Processor: AMD Ryzen 9 5950X @4.9GHz // GFX: AMD Radeon RX 5700 XT // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 6x 1TB SSD, 2x 120GB SSD, 1x 275GB M2 SSD
Making lemonade from lemons since 2015.
Online
Thank you all!
Maybe vi is fast, but it doesnt suit me. I appologize if i accidently insulted anyone but i am a noob please forgive me.
I'll just reconfigure nano to be my default editor.
Cheers
C, ARM, ARM assembly, HTML, CSS, JS, Linux
Offline
I don't think there's any need to export it. Run:
$ sudo EDITOR=nano visudo
Add this to the first line:
Defaults editor=/usr/bin/nano
Now you can just run:
$ sudo visudo
Problem solved.
This is how I keep it, by the way.
Last edited by DSpider (2012-09-16 14:51:10)
I have made a personal commitment not to reply in topics that start with a lowercase letter. Proper grammar and punctuation is a sign of respect, and if you do not show any, you will NOT receive any help (at least not from me).
Offline
Pages: 1