LPI
101-500 · Question #274
You want to save vi changes to the file myfile with :w!, but vi complains it can not write to the file. Therefore, you want to check the write permissions on the file. To do this without leaving vi…
The correct answer is A. :!ls -l myfile. You've hit your Sonnet limit · resets Jun 8, 9am (UTC)
GNU and Unix Commands
Question
You want to save vi changes to the file myfile with :w!, but vi complains it can not write to the file. Therefore, you want to check the write permissions on the file. To do this without leaving vi, you type:
Options
- A:!ls -l myfile
- B:\ls -l myfile
- Cesc :ls -l myfile
- D:?ls -l myfile
How the community answered
(21 responses)- A90% (19)
- B5% (1)
- C5% (1)
Explanation
You've hit your Sonnet limit · resets Jun 8, 9am (UTC)
Topics
#vi editor#shell commands#file permissions#:! syntax
Community Discussion
No community discussion yet for this question.