Greetings.
While I've programmed for some time, I am new to Squeak. I was wondering how I diff or compare two images that are largely similar (such as, say, Scratch vs Scratch For Second Life).
In other environments, I'd run the source trees for each project/variation through a recursive diff tool -- Beyond Compare, Changes.app, Kompare, or even `diff` from the command line. How do I do something similar in Squeak?
Cheers, Clinton Blackmore
_______________________________________________ Beginners mailing list [hidden email] http://lists.squeakfoundation.org/mailman/listinfo/beginners |
On Saturday, May 22, 2010 09:05:14 am Clinton Blackmore wrote:
> While I've programmed for some time, I am new to Squeak. I was wondering > how I diff or compare two images that are largely similar (such as, say, > Scratch vs Scratch For Second Life). An image is not a source code but a snapshot of a state. It is a virtual machine suspended in time. It cannot be compared or diff-ed, AFAIK. Subbu _______________________________________________ Beginners mailing list [hidden email] http://lists.squeakfoundation.org/mailman/listinfo/beginners |
In reply to this post by Clinton Blackmore
On Saturday, May 22, 2010 09:05:14 am Clinton Blackmore wrote:
> While I've programmed for some time, I am new to Squeak. I was wondering > how I diff or compare two images that are largely similar (such as, say, > Scratch vs Scratch For Second Life). An image is not a source code but a snapshot of a state. It is a virtual machine suspended in time. It cannot be compared or diff-ed, AFAIK. Subbu _______________________________________________ Beginners mailing list [hidden email] http://lists.squeakfoundation.org/mailman/listinfo/beginners |
If you want to compare source code only, you can file it out. You could
also write some code in both images, and ask them to do comparisons (use sockets of fifos, or similar mechanisms for IPC). _______________________________________________ Beginners mailing list [hidden email] http://lists.squeakfoundation.org/mailman/listinfo/beginners |
Yes, I suppose an image is a virtual machine suspended in time. I hadn't even considered comparing things other than the source code. I'd wondered about filing everything out. That sounds like the way to go. Having the two images talk to each other and run comparisons also sounds very interesting -- but sounds rather difficult (although, perhaps it is not and it is just my lack of understanding of squeak that makes it seem so).
Clinton On Sat, May 22, 2010 at 4:07 AM, Mateusz Grotek <[hidden email]> wrote: If you want to compare source code only, you can file it out. You could _______________________________________________ Beginners mailing list [hidden email] http://lists.squeakfoundation.org/mailman/listinfo/beginners |
People have certainly built tools that do image archeology but they
have tended to be more academic than practical. Outside of Squeak, imagine writing a tool to look at two WMware VMDK files onto which two different people had installed Windows, Firefox, and various other tools. It might be theoretically possible to write a program that would look at two VMDKs and tell you about the different versions of programs that are installed, but it is practically very difficult. It would be much easier to start both machines on the network and have them inventory their programs and then compare. If you are interested in having two (running) Squeaks talk to one another, you might want to look at Magma. Magma can store just about any Squeak object in an object database that multiple Squeaks can connect. Magma's remote framework can be used outside of Magma. It is available as "Ma client server" See this page for details and usage: http://wiki.squeak.org/squeak/2978 On Sat, May 22, 2010 at 8:24 AM, Clinton Blackmore <[hidden email]> wrote: > Yes, I suppose an image is a virtual machine suspended in time. I hadn't > even considered comparing things other than the source code. > I'd wondered about filing everything out. That sounds like the way to go. > Having the two images talk to each other and run comparisons also sounds > very interesting -- but sounds rather difficult (although, perhaps it is not > and it is just my lack of understanding of squeak that makes it seem so). > Clinton > > On Sat, May 22, 2010 at 4:07 AM, Mateusz Grotek <[hidden email]> > wrote: >> >> If you want to compare source code only, you can file it out. You could >> also write some code in both images, and ask them to do comparisons (use >> sockets of fifos, or similar mechanisms for IPC). >> _______________________________________________ >> Beginners mailing list >> [hidden email] >> http://lists.squeakfoundation.org/mailman/listinfo/beginners > > > _______________________________________________ > Beginners mailing list > [hidden email] > http://lists.squeakfoundation.org/mailman/listinfo/beginners > > Beginners mailing list [hidden email] http://lists.squeakfoundation.org/mailman/listinfo/beginners |
I can install a library and start communicating over sockets with one line of code?! That's incredible.
[Incidentally, as a system administrator, I did ask about diffing two filesystems: http://serverfault.com/questions/10424/diffing-two-filesystems . (grin)]
Clinton
On Sat, May 22, 2010 at 7:59 AM, David Mitchell <[hidden email]> wrote: People have certainly built tools that do image archeology but they _______________________________________________ Beginners mailing list [hidden email] http://lists.squeakfoundation.org/mailman/listinfo/beginners |
Sorry for the noise, I don't know if this is what you are looking for, but just because it hasn't been mentioned in this thread I have to suggest it: have you looked at Monticello and Metacello?
Monticello is the similar to a cvs repository merged with aptitude. And it has it's own diffing tools to compare and merge sources. And Metacello defines dependencies between packages and it's versions. Cheers, Mariano. On Sat, May 22, 2010 at 11:38 AM, Clinton Blackmore <[hidden email]> wrote: I can install a library and start communicating over sockets with one line of code?! That's incredible. _______________________________________________ Beginners mailing list [hidden email] http://lists.squeakfoundation.org/mailman/listinfo/beginners |
I have heard of Monticello. (I may need to re-read the chapter on it in Squeak By Example). I've used other version control systems, and understand how to use them, but I don't know of any that let you diff source trees that aren't in the same version control system, so I have no reason to expect that Monticello would do that, either.
Still, I suppose I could try to leverage off of the diffing tools and change the way that it gets its input data. My biggest hang-up is that I am, well, a beginner with Squeak. Thank you,
Clinton On Thu, May 27, 2010 at 8:25 AM, Mariano Abel Coca <[hidden email]> wrote: Sorry for the noise, I don't know if this is what you are looking for, but just because it hasn't been mentioned in this thread I have to suggest it: have you looked at Monticello and Metacello? _______________________________________________ Beginners mailing list [hidden email] http://lists.squeakfoundation.org/mailman/listinfo/beginners |
Basically with monticello you can set up a unique repository and then commit there the baseline and changes from both images. Once there you can merge differences easily.
Cheers, Mariano. On Thu, May 27, 2010 at 11:34 AM, Clinton Blackmore <[hidden email]> wrote: I have heard of Monticello. (I may need to re-read the chapter on it in Squeak By Example). I've used other version control systems, and understand how to use them, but I don't know of any that let you diff source trees that aren't in the same version control system, so I have no reason to expect that Monticello would do that, either. _______________________________________________ Beginners mailing list [hidden email] http://lists.squeakfoundation.org/mailman/listinfo/beginners |
In reply to this post by Clinton Blackmore
On 27.05.2010, at 16:34, Clinton Blackmore wrote: I have heard of Monticello. (I may need to re-read the chapter on it in Squeak By Example). I've used other version control systems, and understand how to use them, but I don't know of any that let you diff source trees that aren't in the same version control system, so I have no reason to expect that Monticello would do that, either. You could make a single Monticello package with all code in an image, save that, and compare it to the same package in another image. E.g., install the attached file and save the "All" package, you get an MCZ of about 10 MB. Also, having that allows fun queries: (PackageInfo named: 'All') linesOfCode - Bert - _______________________________________________ Beginners mailing list [hidden email] http://lists.squeakfoundation.org/mailman/listinfo/beginners All-Info.st (1K) Download Attachment |
Thank you! I'll have to give that a try. Clinton On Thu, May 27, 2010 at 4:43 PM, Bert Freudenberg <[hidden email]> wrote:
_______________________________________________ Beginners mailing list [hidden email] http://lists.squeakfoundation.org/mailman/listinfo/beginners |
In reply to this post by Clinton Blackmore
At Fri, 21 May 2010 21:35:14 -0600,
Clinton Blackmore wrote: > > Greetings. > > While I've programmed for some time, I am new to Squeak. I was wondering how I diff or compare two images that are > largely similar (such as, say, Scratch vs Scratch For Second Life). > > In other environments, I'd run the source trees for each project/variation through a recursive diff tool -- Beyond > Compare, Changes.app, Kompare, or even `diff` from the command line. How do I do something similar in Squeak? I made "ImageBrowser" while ago. (It'd require a little bit of adjustments for Scratch Images.) http://map.squeak.org/package/92e8f376-ba20-4c38-8b3a-abfb2bf24624 It traverses from the Smalltal dictionary in anoother image and fetch the method source and read methods from other .changes file. Then you can remove all identical methods. So, it is basically a browser for code in another image. -- Yoshiki _______________________________________________ Beginners mailing list [hidden email] http://lists.squeakfoundation.org/mailman/listinfo/beginners |
Very interesting. It looks like I will probably not get to try any of these methods until next week, but, what sort of adjustments do you think it would need for Scratch images? Clinton
On Fri, May 28, 2010 at 10:23 AM, Yoshiki Ohshima <[hidden email]> wrote: At Fri, 21 May 2010 21:35:14 -0600, _______________________________________________ Beginners mailing list [hidden email] http://lists.squeakfoundation.org/mailman/listinfo/beginners |
At Fri, 28 May 2010 10:55:31 -0600,
Clinton Blackmore wrote: > > Very interesting. It looks like I will probably not get to try any of these methods until next week, but, what sort of > adjustments do you think it would need for Scratch images? The biggest single issue is that my ImageBrowser depends on InterpreterSimulator to load the image file and find out the object pointers in it. An older version of InterpreterSimulator that is suitable for the Scratch image can be found somewhere (like in the Squeak2.4 image) but bringing in it will take some efforts. -- Yoshiki _______________________________________________ Beginners mailing list [hidden email] http://lists.squeakfoundation.org/mailman/listinfo/beginners |
Would it be easier to bring Scratch forward to run on a newer version of Squeak?
Clinton
On Wed, Jun 2, 2010 at 11:55 AM, Yoshiki Ohshima <[hidden email]> wrote: At Fri, 28 May 2010 10:55:31 -0600, _______________________________________________ Beginners mailing list [hidden email] http://lists.squeakfoundation.org/mailman/listinfo/beginners |
At Wed, 2 Jun 2010 12:03:30 -0600,
Clinton Blackmore wrote: > > Would it be easier to bring Scratch forward to run on a newer version of Squeak? Hmm, I think that would be so much more work, compared to for example bringing in the InterpreterSimulator into the Scratch image. -- Yoshiki > On Wed, Jun 2, 2010 at 11:55 AM, Yoshiki Ohshima <[hidden email]> wrote: > > At Fri, 28 May 2010 10:55:31 -0600, > Clinton Blackmore wrote: > > > > Very interesting. It looks like I will probably not get to try any of these methods until next week, but, what > sort of > > adjustments do you think it would need for Scratch images? > > The biggest single issue is that my ImageBrowser depends on > InterpreterSimulator to load the image file and find out the object > pointers in it. An older version of InterpreterSimulator that is > suitable for the Scratch image can be found somewhere (like in the > Squeak2.4 image) but bringing in it will take some efforts. > > -- Yoshiki > _______________________________________________ > Beginners mailing list > [hidden email] > http://lists.squeakfoundation.org/mailman/listinfo/beginners > > > [2 <text/plain; us-ascii (7bit)>] > _______________________________________________ > Beginners mailing list > [hidden email] > http://lists.squeakfoundation.org/mailman/listinfo/beginners Beginners mailing list [hidden email] http://lists.squeakfoundation.org/mailman/listinfo/beginners |
Fair enough.
Clinton
On Wed, Jun 2, 2010 at 12:16 PM, Yoshiki Ohshima <[hidden email]> wrote: At Wed, 2 Jun 2010 12:03:30 -0600, _______________________________________________ Beginners mailing list [hidden email] http://lists.squeakfoundation.org/mailman/listinfo/beginners |
Free forum by Nabble | Edit this page |