After a bit of head scratching, my diff stack now produces this (it's the bare-bones of what I want). I'll likely whittle it down further to find word differences on each line.
- diff-wd-v2.png (45.28 KiB) Viewed 5349 times
(I was trying to confuse it)
Does this work? Can anyone else suggest any changes or see an error in the logic of my function?
You might ask why I'm doing this?
(if you were thinking of Github - you'd be right)... I'm doing this to make my own changes-tracker to script in OXT Lite. The idea is this will be a user friendly github, but without the github part
OXT Lite will be able to look at everyone's proposed changes, identifiy what has stayed the same, and what has changed - and we (the community) can either "allow that change through" or "block that change", or "roll back the change" to the last version.
It's quite a lot to implement, but the key is getting this compare function to be human-readable and working reliably.
From there, the rest I think is possible.
Earlier,
I mentioned that OXT lite wouldn't have loads of new features, and is more a bug fix release. However, I think that this function is needed if OXT Lite is going to ever be maintained or improved by multiple people (rather than just me). Because I have this (hatred is perhaps too strong a word... maybe indifference, or replusion?) to Github - I'll create my own that works for our purposes.
The nice thing about that is of course, it'll be aware of content inside .rev, .livecode, .livecodescript, and .oxtstack file types (which Github is not).
Does anyone have any objections to this? I currently imagine this being a preference (like "Developer Mode") that you can turn on. (It'll be off as default though). I think I'll also have to implement something like 'flood control' to stop a dDOS attack with only so many script change submissions allowed within a certain timeframe. It does also open it up to abuse though, so I'll need to carefully consider the details of how this is implemented. There also needs to be plenty of warnings along the lines of "you accept full responsibility for running script from potentially unknown sources on your computer"... or something like that. Just so we can't be blamed for someone running unverified code that hasn't been approved. That might also require a bit of careful contemplation.
But I think it's an important feature to add nonetheless, so that we can truly have a collaborative effort. I'm sure a lot more progress would be made, (and faster) - if everyone who comes here could test changes and submit them for review in an easier manner. Just the finer nuances of it need to be worked out beforehand.