[prev in list] [next in list] [prev in thread] [next in thread] 

List:       mercurial
Subject:    Re: largefiles: no hg addremove, and warning about largefiles in hg add
From:       rupert THURNER <rupert.thurner () gmail ! com>
Date:       2012-04-14 15:36:12
Message-ID: CAJs9aZ9Hb_v9mAKnKPr_PeYeSdTjLuEiQ3ZjvsJQNbpDGch1EA () mail ! gmail ! com
[Download RAW message or body]

hi,

now, with mercurial-2.1.2, still "hg add" "hg rm" "hg mv" behave
differently than "hg addremove", concerning largefiles. "hg addrem"
always says:
abort: minimum size for largefiles must be specified

mercurial.ini contains:
[largefiles]
minsize=1

hg help addrem says nothing about a largefile option, as well does not
say anythong about global options.

rupert.

On Wed, Nov 30, 2011 at 16:03, Na'Tosha Bard <natosha@unity3d.com> wrote:
> 2011/11/29 rupert THURNER <rupert.thurner@gmail.com>
>>
>>
>> On Nov 29, 2011 4:32 PM, "Na&apos;Tosha Bard" <natosha@unity3d.com> wrote:
>> >
>> > 2011/11/29 Na'Tosha Bard <natosha@unity3d.com>
>> >>
>> >> 2011/11/29 rupert.thurner <rupert.thurner@gmail.com>
>> >>>
>> >>> hi,
>> >>>
>> >>> we appreciate the largefiles extension a lot, as we have quite some
>> >>> binary files. the following seem to be a little confusing though:
>> >>>
>> >>> 1.      hg addremove does not work
>> >>> we do not use add any more, but only “hg addremove --similarity 80” to
>> >>> not bother people with registering and deregistering files with
>> >>> mercurial. but it says:
>> >>> $ hg addre --large
>> >>> hg addremove: option --large not recognized
>> >>> $ hg addrem
>> >>> abort: addremove cannot be run on a repo with largefiles
>> >>>
>> >>> 2.      hg add displays a warning
>> >>> while “hg help largefiles” says:
>> >>> In repositories that already have largefiles in them, any new file
>> >>> over 10MB will automatically be added as a largefile. “hg add” then
>> >>> says:
>> >>> my/largefile.rpm: up to 51 MB of RAM may be required to manage this
>> >>> file
>> >>> (use 'hg revert my/largefile.rpm ' to cancel the pending addition)
>> >>>
>> >>> is there a special reason why hg behaves like this, other than nobody
>> >>> had the pain/time to adjust it?
>> >>
>> >>
>> >> I believe that addremove is in fact not implemented for largefiles.
>> >> Only because no one has done it; there is no technical reason why it could
>> >> not be (as far as I am aware).
>> >>
>> >> I think the second issue is bad documentation; only files larger than
>> >> 10 MB will be added as largefiles if you have set the msize (I think it's
>> >> called) value in your .hgrc to 10.0 MB.
>> >>
>> >> Both of these would make good issues in our issue tracker:
>> >> http://mercurial.selenic.com/bts
>> >
>> >
>> > A bit more looking shows that there is already an issue about addremove
>> > not working (I have assigned the issue to myself):
>> > http://mercurial.selenic.com/bts/issue3064
>> >
>> > I will also verify that you have to have msize set in order to get any
>> > files automatically added, and if it does prove to be true, I'll submit a
>> > patch to fix the documentation.
>> >
>>
>> I find the documentation very appealing, saying it is sufficient to switch
>> on the extension and add one file explicitly to make it add large files
>> automatically. I d even more appreciate, if it would not be necessary to add
>> a file explicitly.
>
> So I just did a test and it does appear that the documentation is correct.
> When I add a small text file with "--large" to the repo, I can then add an
> 11 MB file and I get "adding <filename> as largefile", without having set
> any value for msize in my .hgrc.
>
> I am not sure why you are not seeing this behavior.
>
> Regarding having to add the first largefile explicitly, I think that is
> pretty important -- otherwise all repos that may have a 10.1 MB text file
> added will automatically become largefiles repos -- a use case that many
> users might not want.  Having to add the first largefile explicitly ensures
> the user is aware he is turning the repo into a largefiles repo.  I think
> this is important.
>
> Cheers,
> Na'Tosha
>
> --
> Na'Tosha Bard
> Build & Infrastructure Developer | Unity Technologies
>
> E-Mail: natosha@unity3d.com
> Skype: natosha.bard
>
_______________________________________________
Mercurial mailing list
Mercurial@selenic.com
http://selenic.com/mailman/listinfo/mercurial

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic