Skip to content

Commit 0a4620a

Browse files
committed
Improve the suggested rsync command for updates
When migrating or updating an existing project, it is important not to overwrite the git files. Signed-off-by: Leandro Lucarella <[email protected]>
1 parent 7ecfec9 commit 0a4620a

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

README.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ the files in your existing project by using `rsync` or similar tools:
7171
```sh
7272
cd /tmp
7373
cookiecutter gh:frequenz-floss/frequenz-repo-config-python --directory=cookiecutter
74-
rsync -r new-project/ /path/to/existing/project
74+
rsync -vr --exclude=.git/ new-project/ /path/to/existing/project
7575
cd /path/to/existing/project
7676
git diff
7777
# Fix all the `TODO`s and cleanup the generated files
@@ -83,6 +83,9 @@ git commit -a
8383
The trailing slash in `new-project/` and the lack of it in
8484
`/path/to/existing/project` are meaningful to `rsync`.
8585

86+
Also make sure to **exclude** the `.git/` directory to avoid messing up
87+
with your local git repository.
88+
8689
## Update an existing project
8790

8891
To update an existing project you can use the [Cookiecutter *replay

0 commit comments

Comments
 (0)