ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* bug with --purgeall?
@ 2011-12-29  6:24 Pablo Rodríguez
  2011-12-29 15:01 ` Hans Hagen
  0 siblings, 1 reply; 6+ messages in thread
From: Pablo Rodríguez @ 2011-12-29  6:24 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Hi there,

yesterday I ran the following command:

context --purgeall --environment=mysecondstyle.tex --mode=myexample.xml

I know that the source file is missing (I discovered it later). This is
not my issue.

The problem is that the --purgeall option caused context to erase all
.log files contained in that directory. Instead of asking for a source
file name, it deleted all .log files.

I'm afraid this is a bug, at least it shouldn't erase files that context
didn't generate.

Thanks for your help,


Pablo
-- 
http://www.ousia.tk
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: bug with --purgeall?
  2011-12-29  6:24 bug with --purgeall? Pablo Rodríguez
@ 2011-12-29 15:01 ` Hans Hagen
  2011-12-29 16:12   ` Pablo Rodríguez
  0 siblings, 1 reply; 6+ messages in thread
From: Hans Hagen @ 2011-12-29 15:01 UTC (permalink / raw)
  To: mailing list for ConTeXt users; +Cc: Pablo Rodríguez

On 29-12-2011 07:24, Pablo Rodríguez wrote:
> Hi there,
>
> yesterday I ran the following command:
>
> context --purgeall --environment=mysecondstyle.tex --mode=myexample.xml
>
> I know that the source file is missing (I discovered it later). This is
> not my issue.
>
> The problem is that the --purgeall option caused context to erase all
> ..log files contained in that directory. Instead of asking for a source
> file name, it deleted all .log files.
>
> I'm afraid this is a bug, at least it shouldn't erase files that context
> didn't generate.

how should it know


-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
     tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
                                              | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: bug with --purgeall?
  2011-12-29 15:01 ` Hans Hagen
@ 2011-12-29 16:12   ` Pablo Rodríguez
  2011-12-29 18:49     ` Hans Hagen
  0 siblings, 1 reply; 6+ messages in thread
From: Pablo Rodríguez @ 2011-12-29 16:12 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On 12/29/2011 04:01 PM, Hans Hagen wrote:
> On 29-12-2011 07:24, Pablo Rodríguez wrote:
>> Hi there,
>>
>> yesterday I ran the following command:
>>
>> context --purgeall --environment=mysecondstyle.tex --mode=myexample.xml
>>
>> I know that the source file is missing (I discovered it later). This is
>> not my issue.
>>
>> The problem is that the --purgeall option caused context to erase all
>> ..log files contained in that directory. Instead of asking for a source
>> file name, it deleted all .log files.
>>
>> I'm afraid this is a bug, at least it shouldn't erase files that context
>> didn't generate.
> 
> how should it know?

By name and by modification date and time.

But in any case, the following command:

	context --purgeall

should give an error (missing document) before trying to purge all
documents.

Thanks for your help,


Pablo
-- 
http://www.ousia.tk
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: bug with --purgeall?
  2011-12-29 16:12   ` Pablo Rodríguez
@ 2011-12-29 18:49     ` Hans Hagen
  2011-12-29 20:35       ` Pablo Rodríguez
  0 siblings, 1 reply; 6+ messages in thread
From: Hans Hagen @ 2011-12-29 18:49 UTC (permalink / raw)
  To: mailing list for ConTeXt users; +Cc: Pablo Rodríguez

On 29-12-2011 17:12, Pablo Rodríguez wrote:
> On 12/29/2011 04:01 PM, Hans Hagen wrote:
>> On 29-12-2011 07:24, Pablo Rodríguez wrote:
>>> Hi there,
>>>
>>> yesterday I ran the following command:
>>>
>>> context --purgeall --environment=mysecondstyle.tex --mode=myexample.xml
>>>
>>> I know that the source file is missing (I discovered it later). This is
>>> not my issue.
>>>
>>> The problem is that the --purgeall option caused context to erase all
>>> ..log files contained in that directory. Instead of asking for a source
>>> file name, it deleted all .log files.
>>>
>>> I'm afraid this is a bug, at least it shouldn't erase files that context
>>> didn't generate.
>>
>> how should it know?
>
> By name and by modification date and time.
>
> But in any case, the following command:
>
> 	context --purgeall
>
> should give an error (missing document) before trying to purge all
> documents.

Well, I use it to really purge all those files, including logs (left 
overs from tests and such).

Hans


-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
     tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
                                              | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: bug with --purgeall?
  2011-12-29 18:49     ` Hans Hagen
@ 2011-12-29 20:35       ` Pablo Rodríguez
  2011-12-30 12:18         ` Hans Hagen
  0 siblings, 1 reply; 6+ messages in thread
From: Pablo Rodríguez @ 2011-12-29 20:35 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On 12/29/2011 07:49 PM, Hans Hagen wrote:
> On 29-12-2011 17:12, Pablo Rodríguez wrote:
>> On 12/29/2011 04:01 PM, Hans Hagen wrote:
>>> how should it know?
>>
>> By name and by modification date and time.
>>
>> But in any case, the following command:
>>
>> 	context --purgeall
>>
>> should give an error (missing document) before trying to purge all
>> documents.
> 
> Well, I use it to really purge all those files, including logs (left 
> overs from tests and such).

Thanks for your reply, Hans.

I'm not sure whether I got it right: do you use "context --purgeall"
instead of the Windows version of "rm *.log *.tuc" (and other file
extensions)? (Sorry, I'm not proficient at Windows shell :-().

I guess that "context --purgeall *" would be a better choice, since the
user explicitly asks to remove all files with the proper extensions.

Otherwise one might accidentally (as I did yesterday) end deleting log
files totally unrelated to ConTeXt or even TeX, such as log files,

Thanks for your help,


Pablo
-- 
http://www.ousia.tk
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: bug with --purgeall?
  2011-12-29 20:35       ` Pablo Rodríguez
@ 2011-12-30 12:18         ` Hans Hagen
  0 siblings, 0 replies; 6+ messages in thread
From: Hans Hagen @ 2011-12-30 12:18 UTC (permalink / raw)
  To: mailing list for ConTeXt users; +Cc: Pablo Rodríguez

On 29-12-2011 21:35, Pablo Rodríguez wrote:

> I'm not sure whether I got it right: do you use "context --purgeall"
> instead of the Windows version of "rm *.log *.tuc" (and other file
> extensions)? (Sorry, I'm not proficient at Windows shell :-().

indeed, which is quite ok as often tex jobs run on their own path

also, there is --purge (without all) that can be used

> I guess that "context --purgeall *" would be a better choice, since the
> user explicitly asks to remove all files with the proper extensions.

even then it would be --pattern="*" as you don't want shell expansion 
messing things up

> Otherwise one might accidentally (as I did yesterday) end deleting log
> files totally unrelated to ConTeXt or even TeX, such as log files,

sure, so don't use --purgeall then; it's quite unlikely that I will 
change this behaviour if only because I use it all over the place in scripts

Hans


-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
     tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
                                              | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2011-12-30 12:18 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-12-29  6:24 bug with --purgeall? Pablo Rodríguez
2011-12-29 15:01 ` Hans Hagen
2011-12-29 16:12   ` Pablo Rodríguez
2011-12-29 18:49     ` Hans Hagen
2011-12-29 20:35       ` Pablo Rodríguez
2011-12-30 12:18         ` Hans Hagen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).