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 trialMax Pedersen
7,196 PointsCan you combine flags using Git?
Tommy has used "-a -m" separately in his commits in his past few videos. Are you allowed to combine these two flags into "-am"? It seems to work in the Treehouse Console, but I'm curious if there is a reason why I shouldn't combine them.
Vinnie Dauer
12,824 PointsYes, you can combine them. "-am" for commits is common. It is wise, however, to make sure you want to add all the files in the directory before your commit.
1 Answer
Andi Wilkinson
26,822 Pointsyou seem to be able to - New to GIt but adding git commit -a -m "message" is combining two flags
Roger Nordqvist
7,007 PointsRoger Nordqvist
7,007 PointsHi Max ...
I am used to -am to. It is now difference, But in the assignments here at treehouse, you cant put them together. I tried and got "wrong answer" :)