Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trial
Mohammed Ismail
7,190 Pointschmod +x diary.py
After doing chmod +x diary.py, I did ./diary.py, I threw me an error ": No such file or directory" Can someone help me with this.
I am using work spaces + windows
2 Answers
Steven Parker
243,318 PointsTwo possible issues come to mind:
- you may not have been working in the same folder where the file is located
- the file name might be spelled differently (including capitalization - "Diary.py" perhaps?)
If neither of those pan out, we can be more specific if you make a snapshot of your workspace and post the link to it here.
Mohammed Ismail
7,190 PointsSteven Parker Thanks! Do we have any course which covers related unix commands at Treehouse?
Steven Parker
243,318 PointsThe Console Foundations course would cover some basic ones.
Mohammed Ismail
7,190 PointsMohammed Ismail
7,190 PointsSteven Parker https://w.trhou.se/bj0t9xen6g
Steven Parker
243,318 PointsSteven Parker
243,318 PointsApparently the file format is not compatible with the command shell. The course may have some other way to deal with this (you didn't link to or mention the course). But here's one way to fix it:
These commands convert the line endings from DOS-style to UNIX-style by removing the carriage returns. Then you can run the file by name. It doesn't do anything interesting yet, but you won't get the error.