Add directory instead of files
Hi,
As far as I understand bzr, you can add individual files and those files will be version-controlled by bzr. I have to manually add and remove files. Thus, new files are only added if I give a bzr add command.
However, for a new project it would be easier to add a directory instead of individual files. This is not equal to adding all files individually; adding a directory would imply that all changes in the directory are automatically synchronized with bzr.
Thus, if a new file is created in that directory, that file would be added to the repo. Otherwise also: a deleted file is deleted in the repo.
Is this behavior possible with bzr? That would be great, as I have a program that automatically adds and removes files from a directory and I would love to automatically track those changes.
Thanks for your help,
Ernst
Question information
- Language:
- English Edit question
- Status:
- Answered
- For:
- Bazaar Edit question
- Assignee:
- No assignee Edit question
- Last query:
- 2012-12-16
- Last reply:
- 2012-12-17
John A Meinel (jameinel) said : | #1 |
I dont believe it is possible. However, if you set your ignores correctly,
a plain "bzr add" with no files will add all items that are currently
unknown. And if a file gets removed, "bzr commit" should notice. A bare
"bzr rm" might also work like "bzr add", but I think you can just use
commit.
Also, if you do "bzr commit --strict", bzr will refuse to commit if it sees
unknown files. So you can choose if you want to add, delete or ignore them.
John
=:->
On Dec 17, 2012 1:35 AM, "Ernst" <email address hidden>
wrote:
> New question #216964 on Bazaar:
> https:/
>
> Hi,
>
> As far as I understand bzr, you can add individual files and those files
> will be version-controlled by bzr. I have to manually add and remove
> files. Thus, new files are only added if I give a bzr add command.
>
> However, for a new project it would be easier to add a directory instead
> of individual files. This is not equal to adding all files individually;
> adding a directory would imply that all changes in the directory are
> automatically synchronized with bzr.
>
> Thus, if a new file is created in that directory, that file would be added
> to the repo. Otherwise also: a deleted file is deleted in the repo.
>
> Is this behavior possible with bzr? That would be great, as I have a
> program that automatically adds and removes files from a directory and I
> would love to automatically track those changes.
>
> Thanks for your help,
> Ernst
>
> --
> You received this question notification because you are an answer
> contact for Bazaar.
>
Can you help with this problem?
Provide an answer of your own, or ask Ernst for more information if necessary.