January 2013

The following articles below were published during the month of January 2013 (times are based on UTC):


Writing cleaner PHP code with heredoc

Written by Nitin Venkatesh on Jan. 30, 2013, 2:06 a.m.

Sometimes we need to write up long strings in PHP and things might get confusing the next time we read through it or someone else takes a look at the code. That’s when heredoc comes to the rescue. The way to use heredoc is as follows $var_name = <<<HEREDOC_NAME /* String assignment values go here */ HEREDOC_NAME; <<<HEREDOC_NAME marks the beginning and the HEREDOC_NAME; marks the end. A heredoc name can be anything you please, but the same heredoc name should be used at both the beginning and the end of the string. A very important note – No characters, whitespace, indentation should be present either before or after the end heredoc statement,meaning that there should be nothing before or ...


Invoking the bash shell with some simple parameters

Written by Nitin Venkatesh on Jan. 28, 2013, 9:44 a.m.

Although most of you may know how to do this, it’s just a personal note for myself and for others who might get something out of it. Everyone knows the bash shell can be kickstarted with the bash command. These few switches make life a li’l more easier: 1. $ bash -r # creates a restricted bash shell where the $USER can’t move out of the home directory, even to a sub-directory nits@excalibur:~$ ls -lF | grep -i documents drwxr-xr-x 9 nits nits 4096 Dec 22 19:50 Documents/ nits@excalibur:~$ bash -r nits@excalibur:~$ cd Documents bash: cd: restricted nits@excalibur:~$ cd /mnt bash: cd: restricted nits@excalibur:~$ cd /var bash: cd: restricted 2. $ bash -c #runs a bash shell executing the string ...


What shell am I currently on?

Written by Nitin Venkatesh on Jan. 28, 2013, 9:03 a.m.

Although most of you may know how to do this, it’s just a personal note for myself and for others who might get something out of it. There are a few ways to do this, we will not be depending on environment variables to tell us what shell we are on, since it’s a variable that echoes anything that it’s set to and hence is not always right. 1. $ echo $0 # prints the name of the current program running. So when entered on shell prompt, returns the name of the shell. nits@excalibur:~$ echo $0 bash nits@excalibur:~$ ksh $ echo $0 ksh 2. $ ps -p $$ # uses the PID of the currently running program to get information ...


Ubuntu Developer Week (Raring) is coming to town!

Written by Howard Chan on Jan. 26, 2013, 7 a.m.

Yes Ladies and Gentlemen, please welcome Ubuntu Developer Week (Raring)! Ubuntu Developer Week is a series of online workshops where you can: learn about different packaging techniques find out more about different development teams check out the efforts of the world-wide Development Community participate in open Q&A sessions with Ubuntu developers much more... It will be held on 29th January to 31st January, 2013, around 15:00 UTC to 20:00 UTC. Sessions include: "Introduction to Ubuntu Development" and "Getting set up to Ubuntu Development" by Daniel Holbach; "Introduction to patch systems" and "Ubuntu App Review Process explained" by Bhavani Shankar; "Working with upstreams" and "Interacting with Debian's Bug Tracking System" by Stefano Rivera; "Introduction to One Hundred Paper Cuts" by Chris ...


Connect to Your Ubuntu Machine with an HTML5 VNC Client

Written by Nathan Osman on Jan. 24, 2013, 7:30 p.m.

We all know that VNC is hard to beat when it comes to remote access of an Ubuntu Desktop. Well, okay, some of us use SSH but that isn't always an option. Take my Kindle Touch for example. There are currently no third party apps for the Kindle Touch and the only means I have to connect to anything is the built in web browser. Thankfully this browser implements a good chunk of the HTML 5 spec. Therefore, in order to connect to my machine via the Kindle, I would need to employ a browser-based solution - something that utilized the HTML5 canvas and WebSocket APIs. Enter noVNC. Now before I do any further explaining, it's important to realize just ...


Call to action: Save Getdeb

Written by Roland Taylor on Jan. 22, 2013, 6:11 p.m.

Some time this month (and again today) it came to my attention that Getdeb and Playdeb are no more. The maintainer of these awesome repositories (that once were) has announced that he can no longer maintain the, due to issues he is facing (lack of time essentially). However, we have a chance to save Getdeb and Playdeb from total loss. According to the same announcement, all that is needed to recover Getdeb (provided that someone, or a team from the community, can take up the responsibility) is still there. It's not outside the scope of the Ubuntu/Debian community to pull this off, so consider this a call to action! If you have what it takes, including the time, you can ...


Is Ubuntu Phone targetting 4K UHD video capturing???

Written by Howard Chan on Jan. 17, 2013, 5:34 a.m.

Today I went into the usual strolling along Launchpad and IRC and such (and still moaning about not being able to download any Android 4.0 or up source code) and found something interesting when I visited the Launchpad page of Ubuntu. In the "Newest Blueprints" section there is a blueprint called "Ubuntu Phone: Enable the ability to film 4K UHD video on 8.5-megapixel or greater mobile cameras". That was surprising, so I clicked in the blueprint to have a look. It's contents say: "Given that 4K UHD video is essentially the equivalent of an ~8.29-megapixel still image and that most mobile cameras in 2012 to begin with were already 8 megapixels, the cameras in 2013 and beyond will most certainly ...


Please support the Blender 3D Stack Exchange Proposal

Written by Roland Taylor on Jan. 14, 2013, 7:44 p.m.

The community has spoken! It is time for a Blender 3D Stack Exchange site. Are you a user, a fan, or even an expert? Do you use (or are you interested) in using Blender for anything from Digital art, to games, to video editing, to Python scripting? Then please, join us and commit to the proposal, and feel free to remain with us after it goes into beta and beyond!


Kernel 3.8 officially available on 13.04

Written by Roland Taylor on Jan. 11, 2013, 10:54 p.m.

Just a heads up, Linux kernel 3.8 is finally here on 13.04.


Speculation: Are the Ubuntu Phone App Icons the work of Faenza's author?

Written by Roland Taylor on Jan. 10, 2013, 12:27 p.m.

Take a good look: Seem familiar? I could be wrong, but it looks like "Tiheum" got right down to work after joining Canonical :). Good work, I must say :)