Pages

Monday, September 19, 2011

Set $PATH Environment Variable on Mac OS

I want to append mysql directory to the $PATH I would do this:

1) Create the file /etc/paths.d/mysql like this:

sudo touch /etc/paths.d/mysql
2) Edit the file:

sudo vim /etc/paths.d/mysql

3) Put the path inside the file:
/usr/local/mysql/bin

Error: "Cannot create a server using the selected type"

After I change the location of Tomcat Server, I got the error "Cannot create a server using the selected type" when I delete the old server and tried to add a new server in Eclipse. The reason is that Eclipse already create the server runtime Environment profile and could not find the server from the previous location.

To fix this, simply go to "Preferences", -> Server -> Runtime Environments, select the server and change the installation directory to where Tomcat is now.

Saturday, September 17, 2011

Setting Environment Variables


On Unix, typical shell startup files are .bashrc or .bash_profile for bash, or .tcshrc for tcsh.
Suppose that your MySQL programs are installed in /usr/local/mysql/bin and that you want to make it easy to invoke these programs. To do this, set the value of the PATH environment variable to include that directory. For example, if your shell is bash, add the following line to your .bashrc file:
PATH=${PATH}:/usr/local/mysql/bin
bash uses different startup files for login and nonlogin shells, so you might want to add the setting to .bashrc for login shells and to .bash_profile for nonlogin shells to make sure that PATH is set regardless.
If your shell is tcsh, add the following line to your .tcshrc file:
setenv PATH ${PATH}:/usr/local/mysql/bin
If the appropriate startup file does not exist in your home directory, create it with a text editor.
After modifying your PATH setting, open a new console window on Windows or log in again on Unix so that the setting goes into effect.

How to set Java 1.6 as default in Mac OX 10.5

Welcome to last year Apple. I've never seen a good explanation of why Apple has taken so long to release Java 1.6 for Mac OS X. I remember attending WWDC in 2000 when Steve Jobs announced that Java would be a first class citizen on Mac OS X. Things looked promising, but times have changed. I could understand waiting for the first patch, but this is the 5th patch for Java 1.6. We have been using Java 1.6 on hundreds of production systems in my group for over a year. I can't tell you how annoying it has been to run a VM on my Mac just so I can develop with Java 1.6. The delay for the release has been painful, I'm relived that my life will be improved now
Java 1.6 is not installed as the default, its just available:

After doing Software Update:

cmar$ java -version
java version "1.5.0_13"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_13-b05-237)
Java HotSpot(TM) Client VM (build 1.5.0_13-119, mixed mode, sharing)
when you type java at the command line, it invokes /usr/bin/java which is really a link to the Java Framework

Java Link

cmar$ ls -la /usr/bin/java
lrwxr-xr-x 1 root wheel 74 Apr 30 08:41 /usr/bin/java -> /System/Library/Frameworks/JavaVM.framework/Versions/Current/Commands/java

Switching you default

If you want to switch your default then you need to either modify the link /usr/java/bin
sudo ln -s /System/Library/Frameworks/JavaVM.framework/Versions/1.6/Commands/java /usr/bin/java
You might have to do "rm /usr/java/bin" first to remove the link before creating a new one.
Or you can just create an alias in your ~/.bash_login
alias java=/System/Library/Frameworks/JavaVM.framework/Versions/1.6/Commands/java

Friday, September 16, 2011

Useful Node.js Tools, Tutorials And Resources

Useful Node.js Tools, Tutorials And Resources
Published on Smashing Magazine Feed | shared via feedly mobile
  
Created by Ryan Dahl in 2009, Node.js is a relatively new technology which has gained a lot of popularity among Web developers recently. However, not everyone knows what it really is. Node.js is essentially a server-side JavaScript environment that uses an asynchronous event-driven model. What this means is simple: it's an environment which is intended for writing scalable, high performance network applications. It's like Ruby's Event Machine or Python's Twisted, but it takes the event model a bit further—it presents the event loop as a language construct instead of as a library.
And that's not all: what's really great about Node.js is the thousands of modules available for any purpose, as well as the vibrant community behind this young project. In this round-up, you will find the most useful resources for Node.js, from handy tools to detailed tutorials, not to mention in-depth articles and resources on this promising technology. Do you use Node.js already? Let us know in the comments to this post!

Sunday, September 11, 2011

Scout Observer replaces military SATCOM, is powered by the iPhone 4


 
Scout Observer replaces military SATCOM, is powered by the iPhone 4
Published on Engadget | shared via feedly mobile
If you need to channel your inner MacGyver, there's a tool for that... predictably, it's powered by your smartphone. By connecting an iPhone 4 to the Scout Observer's Toolkit, it's transformed into a spectrum analyzer, power meter, multimeter and Low Noise Block Downconverter (LNB). In English, that means the device lets you locate and verify satellite signals (including other mobile signals), measure their strength, and determine GPS location (amongst other things). The six-pound device replaces the standard 160-pound SATCOM terminal, making it the perfect accessory for covert operations -- if those are the kinds of romps you prefer on the weekend. The company is now accepting pre-orders for shipment sometime in Q4, and hopes to roll out versions for other phones in the near future.

Scout Observer replaces military SATCOM, is powered by the iPhone 4 originally appeared on Engadget on Sun, 11 Sep 2011 14:26:00 EDT. Please see our terms for use of feeds.

Permalink | sourceScout | Email this | Comments



Sent from my iPhone

Saturday, September 3, 2011

How Steve Jobs handles trolls (WWDC 1997) - garry's posterous


 
Navigated from FarukAt.eş - Latest Entries | shared via feedly mobile



Sent from my iPhone