Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

Clean Up AppleWorks temporary files Apps

Some background:

  1. AppleWorks 6.2.9 Latest version (I hoped updating to the latest would fix the problem, but it didn't).
  2. OS X 10.2.8
  3. I use "insert equation" on a regular basis with the Word Processing document type

I often use the "Insert equation..." under the Edit menu to insert equations into my AppleWorks documents. This menu command brings up a handy little helper application which allows simple manipulation of equations. Anyhow, that's not the problem. The equation editor works wonderfully. Until recently, this solution has been working fine ... but I've noticed that AppleWorks has been running slower and slower. So slow to the point that the spinny beachball (new colour version or black and white one, depending on the location of the cursor) would often show up.

The problem is that equation editor creates a bunch of temproary files in ~/Documents -> Appleworks User Data -> Starting Points -> Recent Items. It appears to be creating temproary files and leaving references in the recent items folder -- but neglecting to remove them afterwards. So I wrote a small shell script which I run every once in a while (usually after about a dozen equation insertions):


#!/bin/sh

cd ~/Documents/AppleWorks\ User\ Data/Starting\ Points/Recent Items/
rm tmp*
This removes the temporary data, and AppleWorks returns to its normal speed.
    •    
  • Currently 1.00 / 5
  • 1
  • 2
  • 3
  • 4
  • 5
  (1 vote cast)
 
[6,423 views]  

Clean Up AppleWorks temporary files | 4 comments | Create New Account
Click here to return to the 'Clean Up AppleWorks temporary files' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Clean Up AppleWorks temporary files
Authored by: haumann on Jan 28, '04 06:13:42PM

It's not the equation editor that's causing the proliferation of files in the recent items folder -- AppleWorks itself is the culprit. You'd get the same proliferation if you never used the equation editor at all. This bug has been around since the introduction of AW6. Despite preference settings to the contrary, AW creates a new entry in recent items every time you open an AW document -- apparently, the code to remove items that are no longer considered recent was not implemented.

Having said al that, your fix is a good one, but it applies to pretty much all AW6 users, not just those who use its equation editor.



[ Reply to This | # ]
Clean Up AppleWorks temporary files
Authored by: peterneillewis on Jan 28, '04 09:27:20PM
Yes, this has annoyed me too. But this hint inspired me to solve the problem. Save the following script, adjust the $maxrecent variable to somewhat less than your AppleWorks preference setting for number of recent files to remember, and then run the script from cron (crontab -e) using this line (adjusting the path to the script).

22 1 * * * perl '/Users/peter/perl/CleanAppleWorksRecent.pl'
then once per day the script will run and delete any old recent files and life will be much improved. Note that the script is quite pedantic about the listing romat to ensure it does not delete things it should not delete (so it ensures that the file size is zero for example).

#!/usr/bin/perl -w

use warnings;
use strict;
use diagnostics;

my $maxrecent = 25;
my $appleworks_recent_dir = "$ENV{HOME}/Documents/AppleWorks User Data/Starting Points/Recent Items";

my $count = 0;
chdir( $appleworks_recent_dir ) or die "Cant change to AppleWorks Recent Directory $!";
open( LIST, "/bin/ls -lt |" ) or die;
while ( <LIST> ) {
	chomp;
	next if m!^total \d+$!;
	die $_ unless s!^-rw-r--r--  1 \w+\s+\w+\s+0 [A-Z][a-z][a-z] [0-9 ]\d \d\d:\d\d ([^/]+)$!$1!;
	my $file = $1;
	$count++;
	if ( $count >= $maxrecent ) {
#		print "rm $file\n";
		unlink( $file );
	}
}
close( LIST );


[ Reply to This | # ]
Appleworks Slowdown
Authored by: samread on May 14, '04 04:16:02PM

I also have the problem of slowing down Appleworks 6.2.4 using OS 10.3.3 on a G4 iMac with 512 MB RAM. I have TechTool Pro and have optimised everything in sight but Appleworks still doesn't speed up.
I use it a lot but am extremely un-technical. Can anyone possibly take me by a theoretical hand and guide me through some process that will avoid me having to tear out what little remains of my hair – please??



[ Reply to This | # ]
Clean Up AppleWorks temporary files
Authored by: dmg on Jan 29, '04 05:52:55AM

haumann notes in another comment that this problem is indeed an ongoing issue for any AppleWorks user in either Mac OS 9 or Mac OS X.

There are also a couple of AppleScripts available for both Mac OS 9 and Mac OS X users that will manage recent items. See the two User Contributed FAQs about recent items at (Apple's) AppleWorks Discussion site.

(shameless plug) As well, my program Sidekick displays recent items in the Mac OS X menu bar, as well as managing recent items and doing other things.

 



[ Reply to This | # ]