If you just use the ls command without any options the output will be displayed in one line,
Example:code2care@mac ~ % ls
Desktop Downloads Movies Pictures
Documents Library Music Public
If you want the output to be displayed one entry per line, use -1 (number 1) optional parameter with the ls command.
Example on macOS terminal:code2care@mac ~ % ls -1
Desktop
Documents
Downloads
Library
Movies
Music
Pictures
Public

If you want to see more details about the directories and files you can make use of ls -l (lowercase letter l) command,
Example:code2care@mac ~ % ls -l
total 0
drwx------+ 5 code2care staff 160 Jan 10 14:10 Desktop
drwx------+ 3 code2care staff 96 Jan 2 23:03 Documents
drwx------+ 3 code2care staff 96 Jan 2 23:03 Downloads
drwx------@ 68 code2care staff 2176 Jan 6 20:29 Library
drwx------ 4 code2care staff 128 Jan 2 23:33 Movies
drwx------+ 6 code2care staff 192 Jan 5 22:37 Music
drwx------+ 4 code2care staff 128 Jan 2 23:28 Pictures
drwxr-xr-x+ 4 code2care staff 128 Jan 2 23:03 Public

Provide Feedback For This Article
We take your feedback seriously and use it to improve our content. Thank you for helping us serve you better!
😊 Thanks for your time, your feedback has been registered!
Comments & Discussion
Facing issues? Have questions? Post them here! We're happy to help!