maxflow
maxflow

Reputation: 939

how to commit modified file into repository

I have a file in my repository that has been modified. i.e it shows 'M' next to the file when I hit 'svn st'. How do I get it to show an 'A' so I can svn commit it?

I've tried svn update "filename.c" and it doesn't do the trick.

thanks

Upvotes: 6

Views: 12543

Answers (2)

manojlds
manojlds

Reputation: 301527

You have to commit it. svn ci filename.c. You don't have to "add" an already tracked files. You have to do update when you want to get the latest version from repo. And add when you are adding a file for the first time to the repo.

Upvotes: 0

mu is too short
mu is too short

Reputation: 434945

The 'A' status means, more or less, "this is a new file that is not in the repository yet but will be added to the repository in the next commit". You're getting an 'M' status (modified locally) so you just need to svn commit filename.c to get your changes into the repository.

The fine manual has a full list of the status codes that svn status uses:

http://svnbook.red-bean.com/en/1.0/re26.html

Upvotes: 8

Related Questions