Java enables you to exectute a process on the host OS and to provide input (STDIN) to the process and read standard out (STDOUT) and standard error (STDERR). Each time that you execute a process via Runtime.exec() or ProcessBuilder.start() STDIN, STOUT, and STDERR are piped to the running JVM as an OutputStream or InputStream. For each stream there are two file descriptors and typically when the process terminates those streams are closed also closing the two file descriptors.
Category: Ryan’s Internet Technology, and Web Design Blog
Creating an Eclipse Java Project from an Existing Directory Structure and Source
If you are keeping your code and configs in a repository, more likely than not (and it is recommended) that you do not also store your IDE specific configurations or files within the repo.
As such, you will only keep the bare minimum of IDE independent files in your repository and when you check out a copy of it you will have an existing set of directories and files that you will use to create a project with in Eclipse.→ Continue reading “Creating an Eclipse Java Project from an Existing Directory Structure and Source”
GPI Racing Radiators
I stumbled upon these guys looking for some things on eBay. I wonder if they would make a custom radiator?
http://www.aliexpress.com/fm-store/505902→ Continue reading “GPI Racing Radiators”
Bash Style Guide and Coding Standard
A great resource for bash coding conventions (the PDF is also available as an attachment to the blog post).
http://lug.fh-swf.de/vim/vim-bash/StyleGuideShell.en.pdf → Continue reading “Bash Style Guide and Coding Standard”
Yum Proxy Configuration with an @ (at) Character in Your User Name or Password
If you want to set up yum.conf to talk to repos via a proxy server AND you have an @ sign in your user name or password, try replacing the @ with the url encoded equivalent of ‘%40’→ Continue reading “Yum Proxy Configuration with an @ (at) Character in Your User Name or Password”
Problem Adding a Network Printer Under Windows 7 on a Samba Share
Ah, Windows. It still has it’s old, quirky, you-just-can’t-wait-for-MicroSoft-to-go-out-of-business charm.
But seriously, if you are having trouble adding a printer on a Samba share on a Linux host try the following:
- After you authenticate to the Samba share, make sure that you actually open up a window displaying the contents of the home directory. For some reason, just authenticating to the Samba share will not get you access to the Samba servers list of shared printers.
- If the searching for
Syntax for Dynamically Generating JSON in JavaScript to be Output to HTML
Should you find yourself in a situation where you want to call a function (or method) that accepts JSON data parameters that you want to actually print to the browser to be invoked on some sort of callback (onchange, onclick, etc).
Given the following function:
doSomething(JSONparam) {
// Something happens in here . . .
}
Here is the syntax for rendering an onclick link that is generated in JavaScript and then output to the DOM:
var $markup = ‘<a → Continue reading “Syntax for Dynamically Generating JSON in JavaScript to be Output to HTML”
Simple Solution for JavaScript Object Packages and Namespaces
Most OO programers are familiar with packages. This enables programmers to group like classes together in a logical order and provide some namespace to avoid class name collisions.
I have seen a variety of JavaScript sugar implementations that are mostly unintelligible.
I like things that are simple and easy to understand.
So, if you have a JavaScript class that looks like:
/**
* Constructor
*/
com.ryanchapin.Base = function() {
//
// Constructor does something here . . .
//
}→ Continue reading “Simple Solution for JavaScript Object Packages and Namespaces”
Solution for ‘NX service is not available’
When first installing NXServer I have seen a number of occastions when the initial run of
# /usr/NX/bin/nxserver –install
Does not necessarily work correctly and simply running the following commands has worked.
# /usr/NX/bin/nxsetup –uninstall –purge –clean
then
# /usr/NX/bin/nxsetup –install –setup-nomachine-key
If the previous uninstall/install command doesn’t work, try rpm -e nx*.rpms and reinstalling the rpms before trying to run the nxserver –install command again.→ Continue reading “Solution for ‘NX service is not available’”
Resources for Understanding Object-Oriented JavaScript
Following are some good articles/tutorial on OO JavaScript:
- http://killdream.github.com/blog/2011/10/understanding-javascript-oop/
- http://mckoss.com/jscript/object.htm
- http://nefariousdesigns.co.uk/archive/2006/05/object-oriented-javascript/
- http://msdn.microsoft.com/en-us/magazine/cc163419.aspx