[squeak-dev] Re: [Squeak 4.0] Anyone know much about the format of the sources/changes files?

Levente Uzonyi leves at elte.hu
Thu Feb 25 22:40:15 UTC 2010


On Thu, 25 Feb 2010, Ronald Spengler wrote:

> I have a change in place for condenseSources   My question was really
> about how to put the license at the top in a way that can be written.
>
> I want to be sure though, is there a particular method which should be
> called within condenseSources to add comment text to the top?
>
> My (perhaps naive) implementation is doing something like:
>
> f nextPutall: license

AFAIK the sources and the changes file are both a series of chunks, so 
#nextChunkPut: is the method you're looking for.


Levente

>
> On Thursday, February 25, 2010, Bert Freudenberg <bert at freudenbergs.de> wrote:
>> On 25.02.2010, at 02:38, Randal L. Schwartz wrote:
>>>
>>>>>>>> "Ronald" == Ronald Spengler <ron.spengler at gmail.com> writes:
>>>
>>> Ronald> Good people of Squeak,
>>> Ronald> We need to have a license statement at the top of our sources file for
>>> Ronald> the 4.0 release. I've been futsing with it without success.
>>>
>>> Ronald> I've tried:
>>>
>>> Ronald> 'foo'!
>>> Ronald> 'foo'!!
>>> Ronald> !'foo'!
>>>
>>> (I think) The sources file is always accessed according to byte offsets.  Look
>>> at the code for #condenseSources, and make sure the first thing it does is
>>> write the license before rewriting everything else.
>>
>> Randal is right. You can not just add something at the beginning of the sources or changes file. These are *NOT* text files but databases, the offsets are held in the image (each method knows the file position of its source code). The normal way to put a license in the beginning would be via #condenseSources - which we need to do anyway to purge all older versions of methods.
>>
>> - Bert -
>>
>>
>>
>>
>
> -- 
> Ron
>
>


More information about the Squeak-dev mailing list