ThinkC New INIT for Systems 6/7: Today’s the Day

Relating to ThinkC Development

Crutch

Tinkerer
Jul 10, 2022
293
228
43
Chicago
(Cross posting from 68kmla but figure some here may also find interesting):

Here’s a new little utility INIT for Systems 6/7 (and probably much earlier versions): Drop this in your System Folder (or Extensions folder under System 7) so that the Finder will show files modified today or yesterday as “Today” or “Yesterday” just like Mac OS 8. Works in both Finder list views and the Get Info window.

It’s quick and easy and at least a tiny bit nice. (Technical note - it only patches DrawString and DrawText in the Finder’s application heap, so won’t slow down anything else at all.)

Inspired by this episode of Mac Folklore Radio, wherein Derek reads David Pogue praising Mac OS 8 in part due to this simple feature. Now it’s available in Systems 6/7! https://macfolkloreradio.com/2023/03/03/desktop-critic-mac-os-8.html

It can be localized for non-English by just changing STR resources #128 and 129 in the INIT file with ResEdit.

Written in THINK C 6. At some point in the future I will make the source code available, but I want to spiff it up some first. (And figure out how to use GitHub, I’m still stuck in the ‘90s)

Download at: https://macintoshgarden.org/apps/today-s-the-day

D7505D3A-4C2D-4353-BB2D-B3E47FFAF1AC.jpeg
 

Mu0n

Active Tinkerer
Oct 29, 2021
609
560
93
Quebec
www.youtube.com
I can give you a crash course into using github if you want. I got my own crash course back in 2017 and despite being surrounded by well-meaning pro coders, I couldn't burn their free time asking endless questions like I needed so I figured out a lot on my own. You won't need to learn everything I had to learn though and that's a good thing.
 

Mu0n

Active Tinkerer
Oct 29, 2021
609
560
93
Quebec
www.youtube.com
Thing is, I understand the point of view of a classic programmer that learned the trade without version control. I understand how non-intuitive it is to go beyond self managed* backups all over the place.
I understand the initial reaction to branches when you're just doing a project by yourself - why bother is the question on your mind at all times.

I can address all of it from that point of view, having it lived it myself.

*any self-managed methodology falls over to the way side eventually
 

Patrick

Tinkerer
Oct 26, 2021
434
1
224
43
or maybe use @jcs 's amend ?

I haven't actually tried it myself. but seems like it would be nice to be able to do source control straight from the classic environment you setup for think c.
 
  • Like
Reactions: Bolkonskij

MacOfAllTrades

Tinkerer
Oct 5, 2022
168
183
43
Git is great. A little less so if you have to transfer your code over to a a bridge machine to get it to git tho... And then there's the issue of losing the resource fork coming out of the classic world and into anything modern (ie what you'd use to get onto git).

Git has a cool app(s) that monitors your local repo for changes and helps automate the otherwise-terminal-window steps of updating the remote (web) dataabase of code. But I'm sure there are ways to do it.

I was just trying to post some code for my dock app on git but the resource file .rsrc is entirely contained in resource fork so it's just a blank document..
The best I can think of is to post a .sit you make on the classic side so that all the goods are preserved. Then the question becomes do you even bother posting the .c, .h, etc files as standalone (not in the .sit file) files in the repo so changes can be tracked? OR -- you could put the .c and .h (non-resource-fork) files as stand-alone files in git and then include a .sit archive of all the files that are part of your project that do have resource fork stuff. I'm not sure if the THINK C project file itself is resource fork dependent but probably...?
 

Crutch

Tinkerer
Jul 10, 2022
293
228
43
Chicago
One thing you can do is convert the resource fork to text using SADerez, a resource decompiler that comes with THINK C. (THINK will then automatically recompile the resulting .r file into resources if you just stick it in your project.)

You’re right though that the project file itself is another challenge.
 

Crutch

Tinkerer
Jul 10, 2022
293
228
43
Chicago
True, but you can still decompile your resources and post the .r file on git. THINK C 5 still includes SARez as a stand-alone resource compiler, it just won’t auto-build your resources from the IDE just by including the .r file in your project like THINK C 6 will.