This question already has an answer here:
- Import users from CSV file 6 answers
I have a file containing a list of users and information, each line is a separate user written like so:
I want to grab the names only from the list so I can create a user for them.
Once I have the names I can simply use a for loop and echo useradd with each of the usernames then simply copy and paste the text. How do I approach grabbing the characters before the first comma?