make

How to show an Android Snackbar message

To show an Android Snackbar message from an Activity or Fragment, use Java code like this:

Snackbar.make(view, "going to: " + url, Snackbar.LENGTH_LONG).show();

One key is to remember to call the show() method after make(). I have a tendency to forget to call show() and then wonder why my Snackbar message isn’t showing up. So maybe a better way to show that code is like this:

PHP installation error - unable to install php5 - configure: error: libjpeg.(a|so) not found

I ran into this error message today when trying to install PHP 5.2.x on a CentOS Linux server:

unable to install php5 - configure: error: libjpeg.(a|so) not found.

Actually, although I wrote "install" above, I was trying to run the PHP configure script when I got that PHP error message. (configure is the command you run before you run the make or make install commands.)

AppleScript error: Can't make (handler) into type string

If you ever get the following error message in an AppleScript program (at least while editing the program in the ScriptEditor):

Can't make (handler) into type string

fear not, it seems to be pretty simple to cure. In my case I got this more-specific error message:

Can't make (handler getDayOfWeek) into type string

This error just means that I tried to call a function like this:

Ant Swing - A sample ant build script for a Java Swing application (FPTracker)

Ant Swing build script FAQ: Can you share an example of an Ant build script for Java Swing applications?

Here is another sample Ant build script for a Java application. Again, I hope it can help you "Learn Java by Example", or in this case, "Learn Ant by Example".

A sample ant build script for a standalone Java application

Ant Java build scripts: Can you share an example of an Ant build script for a standalone Java application?

This is a sample Ant build script for a Java application I wrote. It is a GUI/Swing application named "AlwaysOnTop". I include it here because I'm a big believer in learning by example, and maybe this Ant script can help you create an Ant script for your own applications.

Linux mkdir - How to create multiple directory levels at one time

Linux mkdir question: I'm about to go to work on a new server, and I want to create subdirectories named docs, bin, and lib, and the docs directory has two subdirectories named personal and business. How can I create these directories and subdirectories with one command?

Answer: Use the "-p" option of the Unix/Linux mkdir command. The answer is shown below: