[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Orgmode] Re: MORE: Using git via USB for personal org dir and other
From: |
Sebastian Rose |
Subject: |
Re: [Orgmode] Re: MORE: Using git via USB for personal org dir and other data files |
Date: |
Sun, 01 Mar 2009 16:07:41 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.0.91 (gnu/linux) |
Bernt Hansen <address@hidden> writes:
>> $ git clone -l --no-hardlinks --bare . /path/to/usb/stick
>
> I've never used -l --no-hardlinks when creating repos on my usb stuck.
> vfat filesystems don't support hard links and you can't make use of
> hard links across filesystems.
That's true :)
I just copy this from my every-day-git.org. Everything I don't work on
anymore goes there to keep the number of workspaces at a minimum. I tend
to start a lot of little projects as test balloons (or just out of
curiousity) and keep them for reference. I'm always afraid to lose some
trick I found and that does not make it into one of my real projects :)
But even then, --no-hardlinks is not needed. It's a bad habbit even, since
I waste disk space that way. Removing .git in my workspace will never
remove any of the cloned (local, on same filesystem) repos, since files
_are_ hard links, and the data is reachable as long, as at least one
hard link exists (that's the difference between hard links and symbolic
links).
At least that's how I understand hard links on Linux.
`du' does take that into account:
$ mkdir test
$ cd test
$ touch file.c
$ cat /some/file > link.c
$ du -h
16K .
$ ln file.c link.c
$ du -h
16K .
$ ln link.c link2.c
$ du -h
16K .
$ ls -l
insgesamt 36
-rw-r--r-- 3 sebastian sebastian 8988 1. Mär 16:02 file.c
-rw-r--r-- 3 sebastian sebastian 8988 1. Mär 16:02 link2.c
-rw-r--r-- 3 sebastian sebastian 8988 1. Mär 16:02 link.c
No matter how many hard links I add: the disk usage stays the
same. One more point for git!
OK, I'll adjust my habbits :)
Best,
--
Sebastian Rose, EMMA STIL - mediendesign, Niemeyerstr.6, 30449 Hannover
Tel.: +49 (0)511 - 36 58 472
Fax: +49 (0)1805 - 233633 - 11044
mobil: +49 (0)173 - 83 93 417
Http: www.emma-stil.de
- Re: [Orgmode] Re: MORE: Using git via USB for personal org dir and other data files,
Sebastian Rose <=