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

Development Tools Git Basics Getting Started With Git Committing Changes

challenge of committing new file addition to repository

I seem stuck: I have typed: git commit README.md git commit ~a ~m README.md git commit ~m "README.md"

git commit

I have rewaatched the video and am still struggling- please help...

this is challenge 2 after the committing changes video

5 Answers

Michael Mangan
Michael Mangan
9,164 Points

did you run git add first to stage the files. git only commits staged files

yes the first challenge was to add it to the repository: My answer for challenge one was successfully: git add README.md

I figured it out- I used the "~" instead of the "-"... thanks for your help

San Francisco
San Francisco
28,373 Points

can you post what worked please I am using your solution but its not passing

sure:

git commit -m "added new file"

hope this helps!