I am trying to generate a random text file on my macbook from terminal. What I am trying is that:
tr -dc A-Za-z0-9 < /dev/urandom | head -c100 > RandomFile.txt
but im getting
tr: Illegal byte sequence
What am i doing wrong?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Set this environment variable and you should be good to go:
The answer for which I found on this page.
And with that environment variable in place, I see a nicely formatted output: