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

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