Commit graph

21 commits

Author SHA1 Message Date
Joey Hess
8bcdf42b99 annex.diskreserve can be given in arbitrary units (ie "0.5 gigabytes") 2011-03-26 14:37:39 -04:00
Joey Hess
68d90b3328 allow force overriding the disk space check 2011-03-23 12:45:34 -04:00
Joey Hess
b0eccb003a improve free space needed display 2011-03-23 10:52:40 -04:00
Joey Hess
1161fa8bdf add units to disk size check message 2011-03-23 01:06:14 -04:00
Joey Hess
368e20eb84 diskreserve setting
Add annex.diskreserve config setting, to control how much free space to
reserve for other purposes and avoid using (defaults to 1 mb).
2011-03-22 17:53:40 -04:00
Joey Hess
aa2d8e33df free space checking
Free space checking is now done, for transfers of data for keys that have free space metadata.
(Notably, not for SHA* keys generated with git-annex 0.24 or earlier.)

The code is believed to work on Linux, FreeBSD, and OSX; check compile-time
messages to see if it is not enabled for your OS.
2011-03-22 17:27:04 -04:00
Joey Hess
8ad3fd2657 remove debugging 2011-03-16 16:07:28 -04:00
Joey Hess
744638197f fix getKeyspresent to work with hashed dirs 2011-03-16 11:27:29 -04:00
Joey Hess
9d49fe2c17 first pass at using new keys
It compiles. It sorta works. Several subcommands are FIXME marked and
broken, because things that used to accept separate --backend and --key
params need to be changed to accept just a --key that encodes all the key
info, now that there is metadata in keys.
2011-03-15 21:34:13 -04:00
Joey Hess
175d055d4d Add Suggests on graphviz. Closes: #618039 2011-03-13 14:25:32 -04:00
Joey Hess
72d2684016 Rethink filename encoding handling for display. Since filename encoding may or may not match locale settings, any attempt to decode filenames will fail for some files. So instead, do all output in binary mode. 2011-03-12 15:30:17 -04:00
Joey Hess
bc2df77642 Bugfix: When fsck detected and moved away corrupt file content, it did not update the location log. 2011-03-03 21:34:30 -04:00
Joey Hess
9f20aee219 avoid logging to location log when in a bare repo
This assumes that changes to content in bare repos are made from some
non-bare repo, and that the location log is updated on that side.

That's true for move --from and move --to.

It's *not* true for dropkey and setkey and recvkey. But those are plumbing
level commands, so I guess it's ok to assume that someone running those
in a bare repo knows what they're doing. And git-annex-shell is used to
run those, and if the bare repo is non-local, it needs to be able to use
them even though they cannot update the location log. So this seems
unavoidable.
2011-03-03 15:22:53 -04:00
Joey Hess
d651d4985b some initial support for local bare repos
This relies on git-annex's behavior of reading the config of local repos.
That allows repoIsLocalBare to examine the git config for core.bare.

Hopefully, gitAnnexLocation, gitAnnexDir, and gitAnnexObjectDir
are only used on local repos. But, I have not audited fully, since
they're probably not (see for example copyToRemote). And so,
the functions fall back to their old non-bare-aware behavior for
non-local repos.
2011-03-03 14:51:57 -04:00
Joey Hess
fcdc4797a9 use ShellParam type
So, I have a type checked safe handling of filenames starting with dashes,
throughout the code.
2011-02-28 16:18:55 -04:00
Joey Hess
5a50a7cf13 update unicode FilePath handling
Based on http://hackage.haskell.org/trac/ghc/ticket/3307 ,
whether FilePath contains decoded unicode varies by OS.
So, add a configure check for it.

Also, renamed showFile to filePathToString
2011-02-11 15:37:37 -04:00
Michael Kenney
285fb2bb08 Fixed missing import of Messages module 2011-02-10 21:06:00 -04:00
Joey Hess
fe55b4644e Fix display of unicode filenames.
Internally, the filenames are stored as un-decoded unicode.
I tried decoding them, but then haskell tries to access the wrong files.
Hmm.

So, I've unhappily chosen option "B", which is to decode filenames before
they are displayed.
2011-02-10 14:21:44 -04:00
Joey Hess
e6da7eb177 Improved temp file handling
* Improved temp file handling. Transfers of content can now be resumed
  from temp files later; the resume does not have to be the immediate
  next git-annex run.
* unused: Include partially transferred content in the list.
2011-01-28 14:10:50 -04:00
Joey Hess
167523f09d better directory handling
Rename Locations functions for better consitency, and make their values
more consistent too.

Used </> rather than manually building paths. There are still more places
that manually do so, but are tricky, due to the behavior of </> when
the second FilePath is absolute. So I only changed places where
it obviously was relative.
2011-01-27 17:00:32 -04:00
Joey Hess
e7b557ef5d got rid of Core module
Most of it was to do with managing annexed Content, so put there
2011-01-16 16:05:05 -04:00
Renamed from Core.hs (Browse further)