Version Control

A place to discuss Version Control in LiveCode

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller

igorBUSvRhc
Posts: 37
Joined: Thu Apr 19, 2012 8:12 am

Re: Version Control

Post by igorBUSvRhc » Mon May 14, 2012 10:23 am

Thank you very much for this hint - this is the kind of thing that is useful for us, newbies:
jacque wrote:If you set the destroystack property of the stack to true it won't stay in memory when you close it. Then you won't have to remember to do anything special.

There's a preference that automatically creates all new stacks with destroystack true. I always use it.
This is the *second* useful hint I've had from you. The first one was the link to the milk liqueur recipe you posted on the use-livecode mailing list.... ;-)

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7318
Joined: Sat Apr 08, 2006 8:31 pm
Contact:

Re: Version Control

Post by jacque » Mon May 14, 2012 4:26 pm

LOL! It seems there will be a whole lot of drunken LiveCode coders now. :)
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 9755
Joined: Fri Feb 19, 2010 10:17 am

Re: Version Control

Post by richmond62 » Fri May 17, 2013 7:55 pm

Goofy types like me do a version control routine like this:

I do a 'Save As' each time into a directory with a name that includes the date; e.g.

17MAY2013
17MAY2013_2
18MAY2013
18MAY2013_2
18MAY2013_3
19MAY2013

It isn't rocket science, but it works for me.

Newbie4
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 332
Joined: Sun Apr 15, 2012 1:17 am
Contact:

Re: Version Control

Post by Newbie4 » Fri Jul 26, 2013 2:04 pm

Great posts, I am enjoying them. I have the same problems.

There is a script that you can maybe use the code to write your own code to find differences, or at least use to output all your scripts and then use an external text compare to find all the differences. It is called Script Reporter and is open source at http://www.createchsol.com/ScriptReporter/
Script Reporter is an open source project that you are welcome to download and update/revise.
It is an application that will gather all of the scripts in a project and let you view them while in another project.
Simple application that may be useful to others.
You might also find some samples of code and sources by looking at the posts at http://forums.runrev.com/viewtopic.php? ... pts#p61603 and http://forums.runrev.com/viewtopic.php? ... ipts#p7897

cheers
Cyril Pruszko
https://sites.google.com/a/pgcps.org/livecode/
https://sites.google.com/a/setonhs.org/app-and-game-workshop/home
https://learntolivecode.com/

icouto
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 92
Joined: Wed May 29, 2013 1:54 am

Re: Version Control

Post by icouto » Wed Oct 09, 2013 4:10 pm

Newbie4 wrote:There is a script that you can maybe use the code to write your own code to find differences, or at least use to output all your scripts and then use an external text compare to find all the differences. It is called Script Reporter and is open source at http://www.createchsol.com/ScriptReporter/
Just thought that for completeness' sake I'd mention Monte Goulding's excellent lcVCS here, in case anyone comes to this thread looking for tools that may enable them to work better with LiveCode and modern vcs tools like git:

https://github.com/montegoulding/lcVCS

MaxV
Posts: 1579
Joined: Tue May 28, 2013 2:20 pm
Contact:

Re: Version Control

Post by MaxV » Mon Jun 30, 2014 3:17 pm

Version 1.2 of ScriptReporter is here: http://livecodeshare.runrev.com/stack/5 ... eporter-LC
Livecode Wiki: http://livecode.wikia.com
My blog: https://livecode-blogger.blogspot.com
To post code use this: http://tinyurl.com/ogp6d5w

THOLIEN
Posts: 12
Joined: Mon Jul 02, 2018 6:03 pm

Re: Version Control

Post by THOLIEN » Thu Aug 02, 2018 10:02 pm

It looks like it has been another few years since this topic has been addressed. I am looking for a simple script comparison between two versions of the same stack.

I am coming into a bit of a mess. There are several different versions of a stack. I want to know what scripts are different. That's all.

What is the simplest, easiest way to compare scripts between different versions of the same stack?

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 9755
Joined: Fri Feb 19, 2010 10:17 am

Re: Version Control

Post by richmond62 » Fri Aug 03, 2018 7:09 am

Well, that depends on which operating system you're developing on.

On Macintosh you can use TextWrangler to open your 2 stacks and run a text comparison:

http://www.barebones.com/products/textwrangler/

On RiscOS you can use StrongED to do the same thing:

https://www.riscosblog.co.uk/?p=2141

Pe on HaikuOS . . . more apps than you can shake your fist at on Linux.

Oh, and for the CTOS:

https://alternativeto.net/software/text ... rm=windows

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7318
Joined: Sat Apr 08, 2006 8:31 pm
Contact:

Re: Version Control

Post by jacque » Fri Aug 03, 2018 6:01 pm

Brian Milby wrote a stack that's compatible with git and shows diffs between stacks:

viewtopic.php?f=77&t=31079
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

bwmilby
Posts: 460
Joined: Wed Jun 07, 2017 5:37 am
Contact:

Re: Version Control

Post by bwmilby » Sat Aug 04, 2018 8:38 am

Script Tracker will generate a composite diff of two versions of a stack file pretty easily. Here's an outline of the process:
  1. Download and open ScriptTracker (see link in signature or use RevOnline)
  2. Create a folder for the stack
  3. Add a copy of the first version of the stack and open
  4. Select the stack in ScriptTracker and do a sync to export the stack scripts
  5. Close the stack and remove from memory
  6. Replace the stack file with the next version
  7. Open the stack and perform another sync (select "Stack" for conflicts)
At this point, there will be a file in the diff folder with all of the differences between the two stacks. Every object with a script in the first version will be listed in the file since the metadata was reset, but only the actual differences in script will appear. New scripts (files) will not be listed in the diff. If the name of the stack changes, no diff will be shown since the tool uses the stack name as the key.

If you have a tool like DeltaWalker, you can do 3 way folder diffs. The process would be slightly different since you would want to get 3 separate exports (use steps 2-5 on each version).

marksmithhfx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 931
Joined: Thu Nov 13, 2008 6:48 am

Re: Version Control

Post by marksmithhfx » Mon Aug 22, 2022 12:05 am

jacque wrote:
Wed May 09, 2012 7:25 am
If you set the destroystack property of the stack to true it won't stay in memory when you close it. Then you won't have to remember to do anything special.

There's a preference that automatically creates all new stacks with destroystack true. I always use it.
Another hidden gem!!
macOS 12.6.5 (Monterey), Xcode 14.2, LC 10.0.0, iOS 15.6.1
Targets: Mac, iOS

Post Reply

Return to “Version Control”