It seems like my shell is taking way too long to start up. Is there any way to profile it so I can figure out what’s slowing it down so much?
Share
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.
Try adding this at the beginning of the file:
and this at the end:
And you should get a detailed log showing the epoch_second.nanosecond time of the execution of each line. Note that GNU
date(and OS support) is required to have nanosecond output.Edit:
added comments
Edit 2:
If you have zsh 4.3.12 or later, you should be able to set
PS4like this instead of using thedatecommand:which should work on both Linux and OS X to give you nanosecond precision.