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 Looking Back on What We've Done

Jimmy Names
Jimmy Names
10,371 Points

On task 5 of 6 (of the last challenge) why not use '-a' to commit all changes?

answer was;

git commit -m "blah blah blah"

But if we're asked to "commit /all/ changes" why not use the -a shortcut?

Thanks

1 Answer

William Li
PLUS
William Li
Courses Plus Student 26,868 Points

Hi there.

Because the works you've done in the previous part 1-4 of the challenge have put all the changed file on the current git directory into the tracked staging, therefore, the use of -a flag is not needed.

Cheers :)

Craig Curtis
Craig Curtis
19,985 Points

Not needed, but perhaps it could not show an error to be more helpful...