Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

Ruby Build a Todo List Application with Rails 4 Build a Todo List Application with Rails 4 Write Our First Tests

Thomas Grzesiakowski
Thomas Grzesiakowski
5,180 Points

mkdir -p spec/features/todo_lists is incorrect syntax (Windows CMD prompt)

Whenever I type the "mkdir -p spec/features/todo_lists" in Windows cmd prompt I get a message saying the syntax is incorrect.

1 Answer

Chris McKnight
Chris McKnight
11,045 Points

The -p flag is invalid on Windows. The instructors in the videos usually use Mac OS X which uses different commands than the Windows command prompt (DOS commands). You can use commands similar to those in the videos on Windows by installing Cygwin (not recommended; huge installation), git bash, git shell (GitHub app), or in the Windows 10 summer update announced at build.

Alternatively, you can create the directory structure in Explorer or just remove the -p flag from the command. Remember to use backslashes when using command prompt as well.

command prompt example: mkdir \a\b\c\d