Source control for temporary projects
Jan. 16th, 2007 05:09 am![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
It really is ridiculous how much more stuff I get done when I'm on a roll. I admit I haven't always been good at putting everything in source control, especially little bits that somehow don't feel like planned projects. But I'm here to assure you that it is always worth it.
I finally set up a subversion repository on my home machine for the flash game (and anything else). Installing subversion and tortoise_svn (graphical client #1) took literally less than five minutes, and paid for itself in productivity in the *next* five minutes, which I swear would have taken an hour otherwise. Do it. Put the text documents in there as well.
Flash's action-script is not 100% the most convenient language. But you *can* rip it out of the flash file and nestedly #include it, allowing simple flicking back and forth between dev vesion and release version, orthogonal development of game logic and level design, etc. Rock on.
I finally set up a subversion repository on my home machine for the flash game (and anything else). Installing subversion and tortoise_svn (graphical client #1) took literally less than five minutes, and paid for itself in productivity in the *next* five minutes, which I swear would have taken an hour otherwise. Do it. Put the text documents in there as well.
Flash's action-script is not 100% the most convenient language. But you *can* rip it out of the flash file and nestedly #include it, allowing simple flicking back and forth between dev vesion and release version, orthogonal development of game logic and level design, etc. Rock on.
no subject
Date: 2007-01-16 10:27 am (UTC)[1] Well, you'd think. My company recently assimilated another small company, and was rather startled to find that they've maintained a largish piece of software for some years in a team of about three developers without source control. Warrgh!, we thought.
no subject
Date: 2007-01-16 10:50 am (UTC)It reflects the philosophy that everyone spends half their time fixing dumb stuff, so almost any amount of time avoiding that is worth it.
I guess it's the Joel test. What simple, necessary things aren't there? I won't tell you if *our* company is perfect or not, though we've several plans in progress to get a lot better (I don't know why it's taking so long!) But that each point on the Joel Test probably doubles productivity :)
no subject
Date: 2007-01-16 10:59 am (UTC)Aw! You're growing up into a (highly successful) medium sized fish :) Sorry, just kidding.
It reflects the philosophy that everyone spends half their time fixing dumb stuff,
Date: 2007-01-16 02:08 pm (UTC)no subject
Date: 2007-01-16 02:21 pm (UTC)But that doesn't mean I wouldn't have liked to have source control available even during that stage, if I'd known about it. It makes some things so much easier, such as filling your program full of temporary diagnostics to track down a subtle bug and knowing you've got rid of them all again once you've solved it...
no subject
Date: 2007-01-17 01:44 pm (UTC)Hmm, yes, arguably. The less you're changing things and the more you're adding things to something which wasn't known to work, the less important. But: some good people just seem to have a plough-ahead approach, regardless of the task at hand. I don't know if they'd do better if they used source control, etc, well, or if something in the way they work is antithetical to it.
no subject
Date: 2007-01-16 01:28 pm (UTC)PHP does the same, but actionscript multiplies its sins by automatically declaring every variable as global. Hence you should be very careful to define almost every variable using the 'var' type - otherwise when it comes to things like a single 'for' loop, if you use 'i' as the counter, and have a function call inside that ends up with another loop (also using 'i' for the counter) - well, now you're screwed. I get the impression it was designed for small snippets of code rather than full projects.
And yes, source control is life.
no subject
Date: 2007-01-16 01:49 pm (UTC)In retrospect, they could use almost any other language that likes dealing with random objects, if they wanted. There's nothing flash-specific in the language. But there you go.
I get the impression it was designed for small snippets of code rather than full projects.
Yeah, me too. Have you used it much?
I dislike languages that don't force you to define variables before using them
Yeah, that it a problem. OTOH, I would love to be able to use temporary variables *a bit*. Is there any compromise, eg. whereby you can declare a variable implicitly by assignment (and it's local), but future assignments produce a warning/error? Then you can invent a variable with relative impunity, knowing if you misspell either the assignment, or the use, or a future assignment that accidntnly collides, you get a warning?
no subject
Date: 2007-01-16 02:08 pm (UTC)I've also gone back to it recently at work for something I'm working on (and if you think actionscript is screwy, take a look at the spec for the file formats - whoever wrote the original spec was pretty stingy with the bits available for many fields, and as a result there are various places where they'd had to bodge in 'extended' fields, switch byte-order around or do other crazy things to cope.
It's decent at what it does, generally. My current technique is to assign actionscript to the specific components that will use it, when possible, rather than keeping it a\t the root level, and to specifically declare all variables as local. I don't think there's any way to force it to do so, and to warn you if you use one you haven't define, though.
no subject
Date: 2007-01-17 01:51 pm (UTC)I've also gone back to it recently at work for something I'm working on
I don't think I'd like to *work* with it though, however fun it can be :)
My current technique is to assign actionscript to the specific components that will use it,
Ah, yes. In a way it would be so much more logical and object oriented if the Winnie-the-Pooh movie clip had all the logic for moving it about. But the trouble is, almost all of that interacts with the map array and other "global" things, so really makes much more sense as a root level function.