summaryrefslogtreecommitdiff
path: root/doc/bugs/when_syncing_a_direct_repository__44___git_annex_delete_non_annexed_new_git_files.mdwn
blob: ddb3f13999bc01ce8631615479e6fb8ecafd0651 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
### Please describe the problem.
I've a undirect repository that I sync with a direct one (that is on a
crippled filesystem). My repository contain tex file that are directly
in git, and binary file that are annexed. 

If I create or modify an standard git files in my undirect repository,
then sync it with the direct repository, the new file is not created
there, or the modified file is deleted there.


### What steps will reproduce the problem?

    $ cd direct
    $ echo foo > bar.tex
    $ git commit bar.tex -m "new tex file"
    $ git annex sync
    $ cd /media/direct-repo
    $ git annex sync
    $ ls bar.tex

There the bar.tex file don't exist, and the next `git annex sync` will
commit the change.

The problem exist for some time (I first believed I add a problem with
my usb stick), but now that direct repository are treated somewhat as
bare repository, I don't know of an easy fix.

### What version of git-annex are you using? On what operating system?

On Debian, since at least git annex 5.20131120 I believe.

### Please provide any additional information below.

[[!format sh """
# If you can, paste a complete transcript of the problem occurring here.
# If the problem is with the git-annex assistant, paste in .git/annex/daemon.log
mkdir direct
cd direct
git init && git annex init "direct"
git annex direct
cd ..
git clone direct indirect
cd indirect
git annex init "indirect"
echo bla > test.tex
git add test.tex
git commit -m "test"
git annex sync
cd ../direct
git annex sync
ls
# End of transcript or log.
"""]]