Archive for June, 2009

The following is taken from the Linux Information Project.

For people accustomed to MS-DOS commands, the following aliases can be defined so that a Unix-like operating system appears to behave more like MS-DOS:

alias dir="ls"
alias copy="cp"
alias rename="mv"
alias md="mkdir"
alias rd="rmdir"
alias del="rm -i"

However, some experienced users of Unix-like systems contend that this may not be a good idea and that it might just make Linux seem more confusing, rather than simpler. Instead, they advocate having Linux users become accustomed to the UNIX terminology right from the start.

I have underlined the above paragraph because it seems to me there is quite a bit of conflict within the Linux community about interoperability, not simply between Dos and Linux, or Unix, but between the variants of Linux also known as distributions. At the end of the day, it is the user which suffers.

We all know about code and how some coders like keeping their code secret, while others give their code away for all the world to see. The open-source community has grown precisely on this principle of freedom and openness, but by and large, code is still in the hands of coders, and the needs of individual communities are compromised as a result. Would you really want a world in which the only novels were written by scientists, or the only music was composed by mathematicians?

The reason why Ubuntu is so successful, is not just the easy to understand shell but the personality behind the shell which appears to be benign and the shell wants us to learn along with it, and not simply to install but to compile from source. This does not mean the Ubuntu CLI is the easiest, or best shell, and BASH still suffers from being too mathematical while the Linux support is too clinical for a lot of users. (Some might say, the problem is rather one of syntax and meaning, while others might say the problem is not simply about math but which maths, and not language, but which language?)

Now imagine being able to create different schemas of commands (using aliasing) that might confer unique advantages depending upon the target user? In other words, creating a linguistic or adaptive personality behind the computer that at the end of the day allows the user to remember and grasp the concept behind the command, and therefore to make more use of the power of the command line?


Read Full Post »

[PLEASE SEE Better PPA Fixkey Method the below is for informational purposes only.]

In Fix Software Sources Bad Behaviour we reported two methods for accomplishing the same task of fixing keys. The first, involved manually entering two lines in a terminal. The second involved one entry. Now there is a third faster method. Aliasing.

ICE20.com describes aliasing in BASH this way:

Many of us use certain commands over and over again, or we have preferred combinations of options which we always give to certain commands. We can create shortcuts to these commands by giving them an alias in our ~/.bashrc file. The format is:

alias new_name=’command -options’

There are some examples provided at the above site, but the one we want to create is this:

alias fixkey=’sudo apt-key adv –recv-keys –keyserver keyserver.ubuntu.com’

Which will execute a command string when you type fixkey.

1. All you have to do is backup your ~/.bashrc file

cp .bashrc .bashrc.bak

2. then open it in a text editor

gedit ~/.bashrc

3. Scroll down to the relevant section.

# Alias definitions.
# You may want to put all your additions into a separate file like
# ~/.bash_aliases, instead of adding them here directly.
# See /usr/share/doc/bash-doc/examples in the bash-doc package.

#if [ -f ~/.bash_aliases ]; then
#. ~/.bash_aliases

4. Uncomment so it looks like this

if [ -f ~/.bash_aliases ]; then
. ~/.bash_aliases

5 Save and exit.

Bash documentation recommends creating a separate file for aliases like this.

6. Create the  ~/.bash_aliases file

gedit ~/.bash_aliases

7. Enter the following code

alias fixkey=’sudo apt-key adv –recv-keys –keyserver keyserver.ubuntu.com’

8. Save and exit.

9. Refresh bash. by either logging out, closing the terminal or entering $ bash

10 To fix an errant key, using fixkey. Open Terminal


WARNING: I  tried the above first leaving the sudo command out and entering it directly in .bashrc expecting that one should be able to simply sudo fixkey in this instance, but this merely turns up a “command not found” dialogue and so I included sudo  in the command string in order for it to execute. This might not be the case with the .bash_aliases file. Any advice on this would be welcome. please see Better PPA Fixkey Method

NOTE: I don’t recommend going off and aliasing everything you do, as you terminal will quickly begin to resemble a unique creature which might bork when you install a new piece of software with the same command structure. (How exactly does this problem of potential commandline scripting conflict get resolved? For example, the above is substantially similar to the following posting at Commandlinefu. Depending on whether your starting point is the ‘addition’ of a key, or ‘fixing’ a key after the fact. Of course both fixkey and launchpadkey can coexist) Rather, I suggest we share commands at places like Commandlinefu or Ubuntu Forums and see if there is any agreement within the broader Ubuntu Community at what to do about reducing relatively complex or time-consuming CLI tasks into easy to remember, attractive or familiar commands. In fact creating more human, or themed commands using the aliasing capabilities of bash, could be the next frontier. I imagine the day when we will be sharing and exchanging CLI matrices or schemas as easily as trying on a new hat or pair of shoes. If the shoe fits, wear it, if not, give it away. – DRL

SEE Environment Variables

Read Full Post »

A short while ago we announced the release of Ubuwiki for Africa. The idea is very simple. A lot of us take connectivity for granted. We also fail to take bandwidth considerations into account and the result is known as the Digital Divide. PDF is a great format for sharing books. Ogg-Theora is the open-source format for sharing music. WoaS or Wiki-on-a-Stick is “a wiki living in a self-modifying XHTML file”. We want it to become the “MP3 of Data” or in Opensource terms, the Ogg-Theora of Data.

Originally Ubuwiki, essentially a modded WoaS “containing repurposed content” was a forked development of WoaS. The two projects have now combined forces and there are plans to develop the format even further. What we want you to do, is modify Woas or Ubuwiki and to share the modified files with your friends. Create online and offline data-sharing. Encourage users to share information with those who don’t have bandwidth. Here is an example of a modification from the official WoaS forum “i use woas with this extention for tabs. i also did some dirty code modifications to use it with ie8 and embedded images. further i did some css modifications.”


Read Full Post »

ZenTwitter is an amazing small script which is able to update twitter accounts without the need of having a browser window open all the time. It uses zenity and curl. (note: if you want to just use your terminal for tweeting see this posting)


Just dump it into your ~/bin directory, open it in the editor of your choice to change the username/password, make it executable (chmod a+x) and add a launcher icon to the panel/menu/desktop of your preferred window manager.

Download: ZenTwitter.tgz


Read Full Post »

Ubuntu Capistrano


This looks amazing. If you need to set-up a server, Ubuntu Machine has Capistrano recipes that will automate the setups. Now wouldn’t it be amazing to see some desktop customisations coming out as Capistrano recipes? In fact I would love to reduce my entire setup to a script, and carry my Ubuntu computer around in my pocket. Or better yet, upload my data, and publish my installation which could then behave like ET and phone home?

Read Full Post »







Read Full Post »

Subversion is a version control system, which allows you to keep old versions of files and directories (usually source code), keep a log of who, when, and why changes occurred, etc., like CVS, RCS or SCCS. Subversion keeps a single copy of the master sources. This copy is called the source ‘‘repository’’; it contains all the information to permit extracting previous versions of those files at any time.

(copied from svn man pages)

To install svn just type this in terminal:

$ sudo apt-get intall subversion

To some setting svn through proxy server:

$ nano ~/.subversion/servers

And add this following lines:

http-proxy-host = your.proxy
http-proxy-port = 8080 #your proxy port
http-proxy-exceptions = localhost #etc
http-proxy-username = your_user
http-proxy-password = your_password

Save the file. Now your SVN will worked through your proxy server.

The other setting can be tweaked manually, just edit servers and config in the ~/.subversion directory

courtesy of Abz Notes http://abz89.wordpress.com/2009/01/23/setting-svn-through-proxy-server/

Read Full Post »

This stumped me. Low-budget computer with a fairly decent motherboard that has onboard graphics and I can’t get the most basic compositing on my Ubuntu Hardy? Surely there is a solution that doesn’t cost money? Well, if you need a compositing window manager in order to enable such things as the AWN dock and you can’t enable Visual Effects in Preferences > Appearance, don’t give up hope.

Metacity (Gnome’s default window manager) can do compositing, though it’s turned off by default. Hit alt-f2 and type “gconf-editor” and ENTER to launch the GConf editor. Under Apps > Metacity > General, put a check next to Compositing Manager and close the application.

You should find that you screen rebuilds and you can now activate AWN without having to buy a graphics card.

NOTE: In researching this, I found an alternative compositor or tool named xcompmgr which apparently provides basic compositing support and gcompmgr which is a GUI frontend. If anyone has tried comparing the two options, I would be interested in hearing from you. Metacity vs Xcomp Manager (xcompmgr)

Read Full Post »

ASCII art in Ubuntu

888          8 8                       8    8 8                 w
 8  8d8b. .d88 8 .d8b. Yb  dP 8   8    8    8 88b. 8   8 8d8b. w8ww 8   8
 8  8P Y8 8  8 8 8' .8  YbdP  8b d8    8b..d8 8  8 8b d8 8P Y8  8   8b d8
888 8   8 `Y88 8 `Y8P'   YP   `Y8P8    `Y88P' 88P' `Y8P8 8   8  Y8P `Y8P8

There are two ASCII art viewers in the repostory. Aview and Cacaview. Both are CLI programmes, so you have to open a terminal. Exploring the world of ASCII art is very 1999, but the retro-adventure is well worth the time and effort. You’ll also find the venerable Lynx Browser, which is an ASCII browser for paper-thin net browsing, and a whole bunch of tools for generating ASCII images which could do with a brush up.

Try Cacafire a port of AALib’s aafire which displays burning ASCII art flames or the Cacademo. Wish there was an easier method for creating ASCII video. I can’t help thinking that there are lot of places which haven’t been explored in the world of Alphanumerics and ASCII art is about to enjoy a resurgence as a design statement.

If you want to cut to the chase, Jerome Desmoulins website has an online ASCII art generator.

Or even better Sporkforge.com

Install figlet if you want an easy way to create ASCII “figs” on the command line.

sudo apt-get install figlet
figlet <text>

None of the above would be possible without the Ubuntu Forum discussion on the subject

Read Full Post »

31 of the 130 Ubuntu HOWTOS from Say Linux

  1. Unzip or Unrar Many Files at Once in Linux
  2. Track MySQL Queries with mysqlsniffer on Ubuntu
  3. Set Gmail as Default Mail Client in Ubuntu
  4. Fix “Password required” Error When Using Unrar in Ubuntu
  5. Add the Trash Can Icon to Your Ubuntu Desktop
  6. Hide Removable Drive Icons from Your Ubuntu Desktop
  7. Assign Custom Shortcut Keys on Ubuntu Linux
  8. Monitor Your Website in Real-Time with Apachetop
  9. Reinstall Ubuntu Grub Bootloader After Windows Wipes it Out
  10. Display Number of Processors on Linux
  11. Delete Files Older Than x Days on Linux
  12. Upgrading Ubuntu From Edgy to Feisty (6.10 to 7.04)
  13. Save 15 Keystrokes – Use Ctrl+Enter to Complete URL
  14. Installing Rainlendar2 on Ubuntu
  15. Install Samba Server on Ubuntu
  16. Share Ubuntu Home Directories using Samba
  17. Create a Samba User on Ubuntu
  18. Set Windows as Default OS when Dual Booting Ubuntu
  19. Change your Network Card MAC Address on Ubuntu
  20. Install MySQL Server 5 on Ubuntu
  21. Install MySQL Server 4.1 on Ubuntu
  22. Install Subversion with Web Access on Ubuntu
  23. Change the GRUB Menu Timeout on Ubuntu
  24. Show the GRUB Menu by Default on Ubuntu
  25. How to Customize Your Ubuntu Kernel
  26. Enable Remote Desktop (VNC) on Kubuntu
  27. Disable the System Beep on Ubuntu Edgy
  28. Disable the Login Sound on Ubuntu
  29. Install TrueCrypt on Ubuntu Edgy
  30. Keyboard Shortcuts for Bash ( Command Shell for Ubuntu, Debian, Suse, Redhat, Linux, etc)
  31. See What Updated Packages Are Available from Ubuntu Command Line

Rest available from Saylinux.com

Read Full Post »

Older Posts »


Get every new post delivered to your Inbox.