Coding Academy Project 2 Aspell problem

Code junkies hangout here

Moderators: ChrisThornett, LXF moderators

Coding Academy Project 2 Aspell problem

Postby Ozram » Tue Apr 20, 2010 8:21 am

When I run the command to dump the word list from Aspell into a file I get the following error message:

rod@Dylan:~/Projects/WordScramble/WordScramble/bin/Debug$aspell dump master|sort|uniq>wordlist
Error: The file "/usr/lib/aspell/en_AU" can not be opened for reading.

There is no en_AU in the aspell directory.
It looks to me like the command is trying to find an Australian version of the dictionary.

Thinking it might be hidden from me I tried chmod while in the aspell directory:

rod@Dylan:/usr/lib/aspell$ sudo chmod u+r en_AU
chmod: cannot access `en_AU': No such file or directory


Any help at all would be appreciated.
Ozram
 
Posts: 1
Joined: Tue Apr 20, 2010 7:34 am
Location: Towamba, Australia

Postby Coll » Tue Apr 20, 2010 8:22 pm

en_AU is not a command but a language setting.

look for the variable set to en_AU by this command:
set | grep en_AU

and try setting that to en_US for now.

I'd say that aspell is set up in en_US. A better solution would be to install aspell in en_AU, but don't know if that option is available.
Coll
 
Posts: 2
Joined: Tue Apr 20, 2010 8:06 pm

Postby JohnMac » Wed May 05, 2010 10:31 am

I am having the same problem- maybe it is due to the southern latitude!
Have run the following with result shown
john@john-desktop:~/Projects/WordScramble/WordScramble/bin/Debug$ aspell dump master |sort|uniq>wordlist
Error: The file "/usr/lib/aspell/en_AU" can not be opened for reading.
john@john-desktop:~/Projects/WordScramble/WordScramble/bin/Debug$ set | grep en_AU
GDM_LANG=en_AU.UTF-8
LANG=en_AU.UTF-8
john@john-desktop:~/Projects/WordScramble/WordScramble/bin/Debug$

My knowledge of Terminal is severely lacking as to what action I should take to take the action suggested of changing the setting.

Help would be appreciated.
JohnMac
 
Posts: 4
Joined: Fri Sep 18, 2009 6:09 am
Location: Parramatta 2150 Australia

aspell

Postby Coll » Wed May 05, 2010 6:49 pm

Try the following:

set LANG=en_US.UTF-8
aspell dump master |sort|uniq>wordlist
set LANG=en_AU.UTF-8

This is an educated guess, not something I have actually tried.

Alternatively, possibly there is an option in aspell (try "aspell --help" ?) to tell it to do it in english-US. Or maybe there is an option to install the AU dictionary with real words for aspell. If you are on a Red-Hat based machine eg Centos try

yum list aspell

and look for a something claiming to be an australian dictionary then do a
yum install _______(au dictionary)
Coll
 
Posts: 2
Joined: Tue Apr 20, 2010 8:06 pm

Problem with aspell

Postby JohnMac » Fri May 07, 2010 10:09 am

Tried the forgoing without success, however, a bit of lateral thinking along the lines of AU representing our version of the English dictionary led to using System Administration -> Language Support changing the Dictionary to English (United Kingdom) but had to stick with the US text for dollar sign!
This appears to have done the trick & I now have a wordlist file to work with.
I should be able to go back to our dictionary now.
JohnMac
 
Posts: 4
Joined: Fri Sep 18, 2009 6:09 am
Location: Parramatta 2150 Australia


Return to Programming

Who is online

Users browsing this forum: No registered users and 0 guests

cron