Categories
coding

Fortune

I’ve been learning Terminal commands from a new book that I got, “Tweak Your Mac Terminal“.

Reading through the first chapter, I discovered a simple command-line utility called “Fortune”. When it’s installed and run at the command-line, Fortune displays random quotations or proverbs. It is often used to provide a humorous or thought-provoking message to users when they log in or open a terminal session. I noticed within the fortune manual (man fortune) that there were some offensive fortunes that had been relegated to only operating when one entered the -o flag (fortune -o) but then discovered that the offensive quotations had actually been removed altogether from the home-brew repository because, well, it includes explicitly racist, homophobic, ethnically insensitive and other offensive content that directly conflicts with the Homebrew’s code of conduct.

Curiosity killed the cat and I found them online. Needless to say, they are at least pretty crass if not outright offensive. But finding them led me down the path to discovering how one creates their own quotations to add to the library of possible fortunes.

To add your own quotations or messages to the fortune database, you’ll need to create a custom fortune file and then compile it into a .dat file. Here are the steps:

Create a Fortune File:
  • Open a text editor, such as bbedit, nano, vim, or gedit.
  • Add your quotations or messages, one per line, to the file. Each message should end with a % character. For example:
This is my first custom fortune message.
%
Here's another custom fortune message.
%
Add as many messages as you like.
%
  • Save the file with a .txt or .dat extension (e.g., my_fortunes.txt).
Convert the Fortune File:
  • Use the strfile command to convert your text file into a .dat file. The .dat file is used by the fortune program to provide random messages efficiently. Run the following command:
strfile my_fortunes.txt my_fortunes.dat
  • Replace my_fortunes.txt with the actual name of your text file and my_fortunes.dat with the desired name for your .dat file.
  • Install or Copy to Fortune Directory:
  • If you want to make your custom fortunes available system-wide, you can copy the .dat file to the system’s fortune directory. On most Unix-like systems, this directory is typically /usr/share/games/fortunes/ or /usr/local/share/games/fortunes/. You may need to use sudo to copy the file:
sudo cp my_fortunes.dat /usr/share/games/fortunes/
Categories
coding

Scrumdinger

scrumdinger card color not working

I’ve been dabbling with Xcode since I got my first Macbook back in 2016. I’ve wanted to learn how to make an iPhone app and especially how to make one that uses SwiftUI, the user interface is growing in popularity and by all accounts is Apple’s recommended choice. Last month I started on this tutorial from Apple’s developer site and last week I finished it! The app is called Scrumdinger and it helps keep track of speaking turns and time limits during a meeting.

A screenshot of the Scrumdinger app.

One problem that needed to be sorted out happened within the section titled, “Creating a card view“. I ran into this warning:

Because I had followed the first section perfectly, I assumed I didn’t need to download the Scrumdinger “starting project” because if that was the case, then how would I be able to make an app myself? Eventually I discovered I would need to add color assets to Xcode in order to avoid needing the “starting project” files.

After eventually figuring out how to do it manually, I made this video showing a quick look at the process:

Then repeat for the remaining 15 colours or just download the “starting project”. I can see why the writers of the tutorial opted to skip the tedious operation of adding each colour manually but it’s nice to know how to do it.

Categories
computer

Messages within Messages App on macOS Not Delivered

A couple of weeks ago I had an issue with my iPhone and decided to log out of iCloud and then log back in. That fixed whatever problem I was having (I don’t even remember what it was) but from that point on the Messages app on my MacBook Pro stopped being able to send messages. Anytime that I would try I would just get the “Not Delivered” error message. Clicking retry didn’t help either. After some frustrating searching of old forums and searching through settings to find anything that I could turn off and turn back on, I finally decided to just log out and log back in. It fixed the problem.

Categories
computer education tutorial

Ninety Percent of People Don’t Know How to Use CTRL-F

Last year I read, “Crazy: 90 Percent of People Don’t Know How to Use CTRL+F“, an article from theatlantic.com, and I decided then to make sure that as a school teacher I was going to try and reverse that statistic. Thinking about it today, I realize I have never posted here to help get the word out, so I’m doing it now.

CTRL-F will help you find text on a web page in most modern browsers. Press and hold Ctrl and then press F, follow that by typing in the words or words you want to find. Mac users try Command + F.

There — I just saved hours, if not days of your life.

CTRL-F Why you no work on paper?

Oh, and as a bonus tip, if you want the same search functionality in your personal (paper) book library, give the My Library feature of Google Books a try — it might just blow your mind.

Categories
computer

hoyolajo.dll

In addition to running very slowly, lately I’ve been getting some unexplained popups on my computer. They’re very strange, sometimes appearing with the Internet Explorer logo (which I don’t use except for updating windows).

Some of the popups have the Firefox logo but then have an Internet Explorer error message. Some other of the pop-ups are coming up as error 404 but that is likely because of my hosts file. (If you don’t have a modified hosts file, I highly recommend you get this one. (instructions)

I ran a scan using Hijackthis and found, what I think are, suspicious .dll files in the windows/system32 folder:

  • hoyolajo.dll
  • pamukuhu.dll
  • subiluje.dll

I don’t know what these files do and the limited search results aren’t helping. I’m posting this here with the hope that someone else may shed some light on the situation.

Categories
computer download

VLC: Best Media Player?

I think VLC is the best media player out there. No more worrying about codecs or corrupt files, VLC does it all—not to mention, it even plays DVDs!

VLC media player is a highly portable multimedia player for various audio and video formats (MPEG-1, MPEG-2, MPEG-4, DivX, mp3, ogg, …) as well as DVDs, VCDs, and various streaming protocols. It can also be used as a server to stream in unicast or multicast in IPv4 or IPv6 on a high-bandwidth network.

Get VLC now.

Categories
computer

iTunesHelper.ex.exe has generated errors…

I’ve got a small problem with my iTunes and ipod—they’re no longer talking to each other. It seems to be related to an error I started getting a few days ago, “iTunesHelper.ex.exe has generated errors and will be closed by windows. You will need to restart the program.”

I did a search and found one other poor soul that seems to have had the exact same error, but this was back in 2004. Unfortunately no one responded to his request:

I’ve installed the software that came with my iPod but keep getting a Program Error “iTunesHelper.ex.exe has generated errors and will be closed by windows. You will need to restart the program”. When I open iTunes I then get another error message “The software required for communicating with the iPod is not installed correctly. Please reinstall iTunes to install the iPod’s software”. I’ve uninstalled and re-installed the iTunes software about 20 times and still can’t get it to work. Can anyone help me?

And since his plea went unanswered, my question is: can anybody help me? I haven’t reinstalled 20 times yet, but twice and it still hasn’t done the trick. Perhaps somebody visiting has had the same problem and knows how to fix it?

Categories
computer life swimming

Linux Update and the Competitive Life Guarding Competition

Ahhh, there is nothing quite as relaxing as sitting down to the quiet hum of your computer in your own home, drinking a nice refreshing Pepsi and posting to your blog. I have lots of things to post tonight so without further ado…

Today I emailed a guy from the Linux club here in Lethbridge and asked him for a copy of Linux on CD. Not only did he respond promptly he actually volunteered and delivered the CD to my house. I still haven’t installed it, but I’m planning on setting up a Linux server on that other computer one of these days.

As I may or may not have mentioned, I volunteered to help out at the competitive life guarding competition that is happening tomorrow at the Max Bell (the University Pool). I am pretty happy that I did because I got a free Level 2 training tonight and although it did take 4 hours from my life… I am now a certified level two official which if nothing else is a nice addition to my resume.

The actual event sounds like it will be very fun to watch; of course more fun to be in, but what can you do? Some of the things they must do are: race across the pool and drag a manikin back in the fastest time keeping “the head” above water, swimming through an obstacle course, and doing it all in relays among other things. As it stands right now, my job as a volunteer will be to make sure that all of the equipment is in place and ready to go at the start of each race. I have 3 or 4 assistants helping me out and I think it will be a great experience. I’ll let you know how it goes.

When I was in Medicine Hat the other day, I bought a Maxtor 1394 PCI Adapter Card for my computer which will allow me to link up firewire devices, specifically digital video cameras, and then I’ll be able to do my homework here at home. I guess it was a little late considering the school year is almost over, but I figured it would be good to have for next year and in case I get my own digital video camera or other firewire device. I haven’t installed it yet, but as soon as I have an afternoon with nothing to do I’ll get right on it.

It’s amazing how fast a 710 mL bottle of Pepsi goes. Til next time keep the comments coming, I love them.