So you may of seen my recent posts about supporting the open standards policy within the UK government. I aim to answer a few questions it may of raised.

Why is this important?

Open standards allows anyone to reuse data and interact with services provided by the government. It fuels innovation and business, allowing access to public data can mean you can offer a valued added service that can support your customers better. To the normal end user this may not seem like much, but to those in business it can a critical source of information. Data such as the crime in an area is useful on sites selling houses for example, then there is transport information and plethora of other resources.

Being an open and published standard it lowers the cost of entry for data reuse. Open Standards allow anyone with technical knowledge to start using it. If this data was to be controlled by a larger company that doesn’t use open standards we have vendor lock in. This is going to create a cost barrier to anyone wishing to use the data, this might be in the form of training, sdk or software licensing. In my opinion these barriers often deter innovation purely because of costs, and that’s exactly what we can stop if we get behind the policy.

Not just data!

This isn’t just about data. Lets say you have an open source product (a blog, a database or even an OS), and your business model is to sell support. Helping this policy become a reality is also vital for you. All of a sudden you have a level playing field to compete for tenders with the government against large contracts. No longer are you going to be in the situation where you don’t stand a chance of winning a contract against the software giants of our industry. You can learn and develop the products without restrictions, without having to buy a license, with only time invested you can be industry experts and have a service or product as good as larger companies. This is great for SME’s and in turn great for the economy!

Where policy goes others follow.

This policy has implications outside of the government also. You often find where a government sets a policy industry often follows suite, this can only be a good thing for SME’s. If one government adopts this policy others are likely to consider this too this has global implications. This is why the larger companies are pouring resources into discrediting open standards.

Arguments against.

I’ve heard a couple of very thin arguments against Open Standards, one being that it “discourages innovation”, my answer to this is you are reading this article on the web. The web is probably the best example of an Open Standard and who can deny that its been responsible for a massive amount of innovation over the last 20+ years. In fact the very same companies who oppose this policy are also touting HTML5 an Open Standard itself as the future of applications.

As a note lets not forget http://www.number10.gov.uk/ is powered by an open source CMS.

What can you do?

Head over to http://open.squarecows.com and hit reply. If you have time please fill in some recommendations and ideas you may have around the subject. This kind of feed back will be crucial to the debate. I’m merely looking to even the fight and put forward the merits of being open, and allowing everyone to take part.

Also please spread the word and get everyone you know to take part in supporting open standards. take to the social networks/email/phone and hey why not fax and send everyone to http://open.squarecows.com

Who needs to fill in the form?

Anyone! Individuals and organisations. If you’ve had a open source success please say why and how it fuels by open standards. You don’t have to be UK based to take part either, the companies who are currently lobbying against this aren’t after all.

 

, , , , ,

A Quick VIM Primer

When you read a lot of HOWTO’s and guides for Linux you’ll often find commands that say edit a file in vi or vim. However we (old skool admins) tend to forget how infuriating these editors can be for new users, so here a little primer that will hopefully get you going. Vim is extremely powerful and is normally installed either as vi or vim on most systems, its lightweight and quick to edit a file remotely on your server for example.

Getting Ready.

First of all lets get you using vim (Vi improved) rather than vi. from a terminal run:

sudo apt-get install vim vim-scripts

vim-scripts isn’t needed but I’ll touch on some articles about using them at a later date.

Now lets make vim your default terminal editor.

update-alternatives –config editor

Select the option /usr/bin/vim.basic

Basics.

Ok now lets create and work on a file. Run:

vi testfile.txt

You’re now faced with a blank screen, and at present no way of entering text. BEFORE pressing anything else press insert, you’ll notice “testfile.txt” [New File] changes to — Insert –. If you press insert again it will say — Replace –. These are the main edit modes we’ll cover in this primer, I’m sure you can work out the difference between insert and replace.

So now you can start typing. As you can see its very basic, but that’s all yo need to edit most files.

Now lets say you want to save your work. Firstly we must exit insert mode. To do this press Esc. The line which once said — Insert — is now blank. To enter any command in order to make vim do things like save and exit you need to use the colons : As you press this you’ll see it appear in the bottom left hand corner. To save your work type w (short for write) followed by enter. The status bar at the updates to tell you the file is written. Now if you want to edit the file simply press insert again!

To exit vim completely press Esc to get out of editor mode followed by : then q (short for quit) followed by enter. NOTE: this will not save changes you make to the file. To save and quit use Esc :wq followed by enter.

If you’ve opened a file edited it then decided its now not what you want to do, vim wont let you exit the file before saving. To over come this use ! to force a command. Esc :q! then enter means quit and don’t worry about prompting me to save.

Quick deleting.

Now lets do some more advanced stuff. Image you just need to open a file and delete a section. For this you don’t even need to go into editor mode (– Insert –). Lets try this by working on your file. Make sure you have a couple of lines of text, separate lines would be even better. Now exit edit mode by pressing Esc. You notice you can still move the cursor around on the text but you can’t actually go right to the end of a line and start typing new text. Move your cursor to the beginning of some text you want to delete and press x. Yes you can see it deleted the letters from in front (to the right) of the cursor. Now that’s great for quickly deleting a few bits then saving the file and exiting. But what if you want to delete a complete line? Simple move your cursor to that line and press d twice. Bang its gone!

Copy/Paste.

You can always highlight text from anywhere by just left click on the mouse and dragging as per normal, but if you’re new to Linux, you may not know that you can then just simply paste by middle clicking in the new document. You can use these features in the terminal also. However vim offers a few tricks of its own. For example lets say you want to duplicate a line of text already in your document and move it else where. Make sure you are NOT in editor mode, move the cursor to the line you want to copy and press Y (short for yank also note its a capital). Now move the cursor to somewhere else in the document and press p. Your line gets pasted. Now use this with the delete command and you can move text round your document easily. Also you’ll find if you delete a line using dd you can then paste it somewhere else using p.

Stacking up commands.

Now you know how to Yank and Delete lines, what if you want to do more than one line? Simple before your command type a number. For example 2dd will delete two lines. 5Y will copy five lines. Give this a go as it will get you used to the concept that vim is very flexible with its commands.

Syntax and line numbers and strange pasting.

Lets say you’re editing a .php file. Vim can highlight the code and show you incorrect syntax or even make it easier to see the start and end of {} or <>. To turn this feature on type Esc :syntax on then press enter and the magic will happen. You may also want line numbers just type Esc :set number on. You can of course turn these off by swaping on for off in the previous commands. If you find when you paste some text from a website it goes haywire when inserted into vim turn off AI which tries to work out what the indentation should be Esc :set noai

A good trick is to switch these features to be always on, to do this create a file in your home directory called .vimrc

vi .vimrc

add these lines

syntax on

set number on

set noai

Now exit vim and open a .php file. You’ll see the features are automatically turned on.

Search and Replace.

I use this command a lot! Its incredibly handy for editing config files. This is fairly advanced for this primer but as I use it so much I though you’d find it useful also. I’ll start by just showing you the command and then breaking it down. Yet again start by leaving insert mode, by pressing Esc.

:1,$ s/foobar/moo/g

Lets break this down so it doesn’t look so confusing.

: – Colons as mentioned before precede any command.

1,$1 tells the command to start on the first line of the text (you could start on line 20 by just swapping this) you then need to follow that with a , and then you use the line where you want to stop this command running, so if you want to go to the end of the file use $ and vim works out this number automatically. However if you want to stop on line 30 and start on line 20 do something like this :20,30

s/ – is used to say swap anything matching the text after this line /

foobar – this is your first string so this should match the word you’re looking to replace.

/ – Separate the word you’re searching for with the new word.

moo – This is your new word.

/ – Tell the command that’s the end of the new word

optional g or ig means global this means every occurrence of the work in you file will be replaced (within your start and end line numbers) If you don’t use g you may find it only updates the first occurrence in each line. i will make the search case insensitive which can be useful. You can use both g and i together as so /gi

Hopefully this will help you start using vim and get confident with day to day tasks. There is MUCH more this editor can do, I recommend looking at The vim Cheat Sheet.

, , , , ,

You may remember a while back I reviewed UbuntuOne, Canonical’s cloud based storage offering which is not unlike Dropbox, at the time I preferred Dropbox, due to pricing and features. A few days before the official launch of Maverick MeerKat, Canonical have stepped up their game plan. By default you get “UbuntuOne Basic” which every user can have for free entitling you to 2GB of on line storage space. However we now also see storage packs of 20GB for just $2.99 a month which means that you have a more flexible pricing scheme than Dropbox, something that the old UbuntuOne didn’t compete very well on. Dropbox offer 50GB for $10 a month, where for $8.97 you get 60GB with UbuntuOne. I personally don’t yet require 50GB on line storage and would begrudge paying $10 for something I don’t fully use, for this reason I think Canonical may of hit a sweet spot in the market. The sync daemon also seems to have improved dramatically with Ubuntu 10.10 and I haven’t had nearly as many problems as before with previous versions. It now seems to have that magic “It just works” status.

Another great advance making users life’s a little easier is the introduction of the windows client (currently in beta). This is in my opinion a great idea allowing users to seamlessly move between the two OS’s and helps with converting from one platform to another. Now all we need to see is a OSX client please guys.

The continued integration of the Ubuntu Music store (powered by 7digital) is also a nice feature, automatically transferring your purchased music to your cloud based storage. We can now start to see the planing behind this with the upcoming streaming service “UbuntuOne Mobile”, which will stream your music to your mobile phone. Android, iPhone and BlackBerry are going to be supported, which is a win for freedom of choice in my opinion! The streaming service will cost an extra $3.99 per month, something that may need to be reduced if they want to see large scale adoption. I understand they have to pay for bandwidth but this isn’t spotify you can only play the music you upload yourself, I think it will leave lots of users thinking why not just get a phone with more storage? If they were to offer a $5 bundle of 20GB and streaming I may consider this, and think most users would like to see some deals like this. Having said this there are other advantages to “UbuntuOne Mobile” including contact syncing, which is nice but there are already some big players in this market like Google with gmail or Google Apps both allowing the sync of contacts and calendars, It at the moment isn’t special enough to get me to part with an extra $3.99 a month.

The website Dashboard is also looking very smooth and polished and has received some TLC the same way the Ubuntu website has. The future of “UbuntuOne” is looking more and more exciting and I’m hoping to see more initiative features introduced soon. I know what I’d like to see and I’m sure other users have ideas also so lets hope Canonical open a suggestions section.

As a quick round up UbuntuOne is now a real contender in the on line storage/cloud storage market. Well work another look!

,
You are protected by wp-dephorm: