LUG Community Blogs

Mick Morgan: compare and contrast

Planet ALUG - Sat, 08/02/2014 - 17:34

Foreign Secretary William Hague is apparently concerned about press restrictions in Egypt. He has reportedly urged the interim Egyptian government to demonstrate commitment to free expression.

The press release on the gov.uk website says:

Speaking today about increasing restrictions placed upon journalists and the media in Egypt, Foreign Secretary William Hague said:

  • “I am very concerned by restrictions on freedom of the press in Egypt, including reports of the recent charging of Al Jazeera journalists, two of whom are British, Sue Turton and Dominic Kane.
  • “We have raised our concerns about these cases and freedom of expression at a senior level with the Egyptian government in recent days. I will discuss these concerns with other European Foreign Ministers at the European Foreign Affairs Council on Monday, and we will continue to monitor the situation of the journalists very closely, and raise them with the Egyptian authorities.
  • “The UK believes a free and robust press is the bedrock of democracy. I urge the Egyptian interim government to demonstrate its commitment to an inclusive political process which allows for full freedom of expression and for journalists to operate without the fear of persecution.”

So, the UK Government believes that a “free and robust press is the bedrock of democracy”.

I agree.

Last weekend’s Guardian newspaper reported on the visits they had from and the conversations they had with Cabinet Secretary, Sir Jeremy Heywood and colleagues back in June and July of last year when the Snowden revelations were just starting to cause some ripples.

That article says:

In two tense meetings last June and July the cabinet secretary, Jeremy Heywood, explicitly warned the Guardian’s editor, Alan Rusbridger, to return the Snowden documents.

Heywood, sent personally by David Cameron, told the editor to stop publishing articles based on leaked material from American’s National Security Agency and GCHQ. At one point Heywood said: “We can do this nicely or we can go to law”. He added: “A lot of people in government think you should be closed down.”

It goes on:

Days later Oliver Robbins, the prime minister’s deputy national security adviser, renewed the threat of legal action. “If you won’t return it [the Snowden material] we will have to talk to ‘other people’ this evening.” Asked if Downing Street really intended to close down the Guardian if it did not comply, Robbins confirmed: “I’m saying this.”

Perhaps Hague should have a word with Cameron. They really need to be more consistent. If freedom of expression is vital in Egypt, I submit it is equally vital in the UK.

Categories: LUG Community Blogs

Surrey LUG Bring-A-Box 8th February 2014

Surrey LUG - Sat, 08/02/2014 - 16:28
Start: 2014-02-08 11:00 End: 2014-02-08 16:45

 

 

Latest news on road floods. --

All roads approaching the Sailing club are flooded and closed.  I drove through Shepperton on Laleham Rd approaching from the North. the Littleton Lane Is  marked as Road Closed but  the ffloodis spilling off he road  and it is passable with care.

  • Renfree Way  closed at  10:16am  about 30cm  I saw a transit van pass through,  but authorities have closed it.
  • Littleton Lane just north of sailing club  Road closed.  10:30   Water is washing over the road and spilling over the curb.  I saw a Mini  and Golf  pass through.
  • Chertsey Bridge Road  Road closed with Police  attendance IIat  10:37   saw a Land Rover pass through.
  • 9 SLUGer's managed to wade through the floods,  and are at the meeting today.
  • Sorry for any one who was not able to make it to the meeting.  Hopefully the weather will be more compliant next time. 
   

This month's meeting is at  -  Littleton Sailing Club - Shepperton.

Donations are requested to cover the cost of rental, heating and power.

We have a TRIAL of a new venue.  Please read the venue page, to see restrictions on the automated gate at this venue. Please arrive promptly,  or book your gate opening time via the maillist.

We have regular sessions on the second Saturday of each month. Bring a 'box', bring a notebook, bring anything that might run Linux, or just bring yourself and enjoy socialising/learning/teaching or simply chilling out!

New members are very welcome. We're not a cliquey bunch, so you won't feel out of place! Usually between 15 and 30 people come along.

Categories: LUG Community Blogs

Adam Trickett: Picasa Web: Yorkshire

Planet HantsLUG - Sat, 08/02/2014 - 15:24
Date: 8 Feb 2014
Number of Photos in Album: 4

View Album

Categories: LUG Community Blogs

Jono Bacon: An Exciting Future

Planet WolvesLUG - Fri, 07/02/2014 - 19:53

We are growing a world-class community and app developer eco-system, fuelled by Open Source and open collaboration. We are putting the core pieces in place and I am delighted to be working with such a wonderful team:

(L-R) Daniel Holbach, Kyle Nitzsche, Michael Hall, This Guy, Nicholas Skaggs, Alan Pope, David Planella

Categories: LUG Community Blogs

Aq: Follow-the-pointer mini screencast Python app for Ubuntu

Planet WolvesLUG - Fri, 07/02/2014 - 19:10

I had this idea for a “screencast” which follows the mouse pointer around, rather than making you nominate a fixed screen area; ideal for little demo animated GIFs of how to do a thing on websites. No existing screencast app seems to do this, so I threw a quick thing together to do it for me. Python (because that’s what I use for native apps that can’t be done in pure QML) and Gtk (because there’s no point in using Qt for this since the Python bindings are weird, I use Qt/QML for Ubuntu SDK apps but this can’t be done there anyway because the phone is Mir rather than X and app confinement will prevent screenshots anyway).

Lots of hardcoded things, so it’s not a proper useful app, but it works for what I needed it for. Note that it contains a hardcoded mouse pointer image, because getting the mouse pointer image is insane and requires you to talk directly to X, which is possible with Python but needs loads of extra libraries, and look life’s just too short what are you thinking. Also uses modern Gdk and GI, not pygtk which is ancient and yet what all the existing posted code samples are. Probably should use Cairo from GI too but cairo.CONTENT_COLOR doesn’t seem to exist there. Anyway, if you need to take screenshots from Python using modern Gtk, or you want to do a little animated gif screencast which follows the mouse around, here you go.

import time from gi.repository import Gdk import cairo from PIL import Image from PIL.GifImagePlugin import getheader, getdata import StringIO CURSOR = """iVBORw0KGgoAAAANSUhEUgAAAA0AAAAUCAYAAABWMrcvAAAABmJLR0QA/wD/AP+gvaeTAAAACXBI WXMAAAsTAAALEwEAmpwYAAAAB3RJTUUH3gIHETMhphEADwAAAfJJREFUOMuVkztvE1EQhb+b9cq+ 3s2CIU7hH+GOxpWxoOIhOR1UaTBUQEmFIA1C1BTUceWCyp1Lp7HcpCFVIgpLK0XRyo4Uy3cfuUOz tlDMIxlpym/OvXPmAHwCfGCDG5S4rvsNuHsTUKrVauw4zlfgznVBOT4+lkqlkiilvgC3rwOKtVaO jo4kCIJEKfURuPU/UNI0FUAODw/F9/0EeAcE/wJlsViItVYAGY1GUi6XE+AtsAmoP0IXFxcrNUCG w+ESfJXbsQbKbDYTY8wKAmQwGIjWOgZ2Ae8qKFEUrakB0u/3RWttgGdXQTk9PZXz8/M1NUB6vZ5o rRdAG9BLUMIw/KsaIPv7+1ZrPQceASUFyGQyoVgsrtp1Xer1uj05OZHlc+I4dpRSU2vt4w2ALMvI sowwDOl2u4gInU5HOY4zMca8Mcbsishza+0LYLE6o/F4LLVaLfE8Lz07O5P5fC5BECTAS6CWX0kA aAf4sLOzQ7vdTqMoGiilFq7rbrdaLZWmqRqPx9tpmvaACDBABiBbW1tJoVD4DjwEnvq+H0dRJNPp dGnyk3xzq7KO43SB+3mmNj3PO9jb27vMskwajYYBPuexWfn0Hrj3W5YcoFUqlUyz2TTlcnkOvAYq S0jln7vMt2LzQSXgQd4/gCHwE4gBfgH0ew11MKHjYAAAAABJRU5ErkJggg==""" def shot(width, height): # Take a screenshot t = time.time() w=Gdk.get_default_root_window() _, mousex, mousey, _ = w.get_pointer() s=Gdk.Window.create_similar_surface(w, cairo.CONTENT_COLOR, width, height) ctx=cairo.Context(s) Gdk.cairo_set_source_window(ctx,w,-mousex + (width/2),-mousey + (height/2)) ctx.paint() return (t, s) SECONDS_DURATION = 3 WIDTH = 300 HEIGHT = 150 FPS = 25 surfaces = [] start = time.time() last = time.time() while (time.time() - start) SECONDS_DURATION: while (time.time() - last) (1.0/FPS): time.sleep(0.01) last = time.time() surfaces.append(shot(WIDTH,HEIGHT)) # now, convert each surface to a PIL PNG then write as a gif buffer = StringIO.StringIO() buffer.write(CURSOR.decode("base64")) buffer.seek(0) cursor_image = Image.open(buffer) fp = open("anim.gif", "wb") previous = None for t, surface in surfaces: sio = StringIO.StringIO() surface.write_to_png(sio) sio.seek(0) im = Image.open(sio) im.paste(cursor_image, (WIDTH/2, HEIGHT/2), mask=cursor_image) im = im.convert('RGB').convert('P', palette=Image.WEB) del surface # Fixme: add specific delay (from t) for each frame, and add looping if not previous: for s in getheader(im) + getdata(im): fp.write(s) else: for s in getdata(im): fp.write(s) previous = im.copy() fp.close() print "Now optimise with gifsicle -b -O3 anim.gif"
Categories: LUG Community Blogs

Aq: Follow-the-pointer mini screencast Python app for Ubuntu

Planet WolvesLUG - Fri, 07/02/2014 - 19:10

I had this idea for a “screencast” which follows the mouse pointer around, rather than making you nominate a fixed screen area; ideal for little demo animated GIFs of how to do a thing on websites. No existing screencast app seems to do this, so I threw a quick thing together to do it for me. Python (because that’s what I use for native apps that can’t be done in pure QML) and Gtk (because there’s no point in using Qt for this since the Python bindings are weird, I use Qt/QML for Ubuntu SDK apps but this can’t be done there anyway because the phone is Mir rather than X and app confinement will prevent screenshots anyway).

Lots of hardcoded things, so it’s not a proper useful app, but it works for what I needed it for. Note that it contains a hardcoded mouse pointer image, because getting the mouse pointer image is insane and requires you to talk directly to X, which is possible with Python but needs loads of extra libraries, and look life’s just too short what are you thinking. Also uses modern Gdk and GI, not pygtk which is ancient and yet what all the existing posted code samples are. Probably should use Cairo from GI too but cairo.CONTENT_COLOR doesn’t seem to exist there. Anyway, if you need to take screenshots from Python using modern Gtk, or you want to do a little animated gif screencast which follows the mouse around, here you go.

import time from gi.repository import Gdk import cairo from PIL import Image from PIL.GifImagePlugin import getheader, getdata import StringIO CURSOR = """iVBORw0KGgoAAAANSUhEUgAAAA0AAAAUCAYAAABWMrcvAAAABmJLR0QA/wD/AP+gvaeTAAAACXBI WXMAAAsTAAALEwEAmpwYAAAAB3RJTUUH3gIHETMhphEADwAAAfJJREFUOMuVkztvE1EQhb+b9cq+ 3s2CIU7hH+GOxpWxoOIhOR1UaTBUQEmFIA1C1BTUceWCyp1Lp7HcpCFVIgpLK0XRyo4Uy3cfuUOz tlDMIxlpym/OvXPmAHwCfGCDG5S4rvsNuHsTUKrVauw4zlfgznVBOT4+lkqlkiilvgC3rwOKtVaO jo4kCIJEKfURuPU/UNI0FUAODw/F9/0EeAcE/wJlsViItVYAGY1GUi6XE+AtsAmoP0IXFxcrNUCG w+ESfJXbsQbKbDYTY8wKAmQwGIjWOgZ2Ae8qKFEUrakB0u/3RWttgGdXQTk9PZXz8/M1NUB6vZ5o rRdAG9BLUMIw/KsaIPv7+1ZrPQceASUFyGQyoVgsrtp1Xer1uj05OZHlc+I4dpRSU2vt4w2ALMvI sowwDOl2u4gInU5HOY4zMca8Mcbsishza+0LYLE6o/F4LLVaLfE8Lz07O5P5fC5BECTAS6CWX0kA aAf4sLOzQ7vdTqMoGiilFq7rbrdaLZWmqRqPx9tpmvaACDBABiBbW1tJoVD4DjwEnvq+H0dRJNPp dGnyk3xzq7KO43SB+3mmNj3PO9jb27vMskwajYYBPuexWfn0Hrj3W5YcoFUqlUyz2TTlcnkOvAYq S0jln7vMt2LzQSXgQd4/gCHwE4gBfgH0ew11MKHjYAAAAABJRU5ErkJggg==""" def shot(width, height): # Take a screenshot t = time.time() w=Gdk.get_default_root_window() _, mousex, mousey, _ = w.get_pointer() s=Gdk.Window.create_similar_surface(w, cairo.CONTENT_COLOR, width, height) ctx=cairo.Context(s) Gdk.cairo_set_source_window(ctx,w,-mousex + (width/2),-mousey + (height/2)) ctx.paint() return (t, s) SECONDS_DURATION = 3 WIDTH = 300 HEIGHT = 150 FPS = 25 surfaces = [] start = time.time() last = time.time() while (time.time() - start) < SECONDS_DURATION: while (time.time() - last) < (1.0/FPS): time.sleep(0.01) last = time.time() surfaces.append(shot(WIDTH,HEIGHT)) # now, convert each surface to a PIL PNG then write as a gif buffer = StringIO.StringIO() buffer.write(CURSOR.decode("base64")) buffer.seek(0) cursor_image = Image.open(buffer) fp = open("anim.gif", "wb") previous = None for t, surface in surfaces: sio = StringIO.StringIO() surface.write_to_png(sio) sio.seek(0) im = Image.open(sio) im.paste(cursor_image, (WIDTH/2, HEIGHT/2), mask=cursor_image) im = im.convert('RGB').convert('P', palette=Image.WEB) del surface # Fixme: add specific delay (from t) for each frame, and add looping if not previous: for s in getheader(im) + getdata(im): fp.write(s) else: for s in getdata(im): fp.write(s) previous = im.copy() fp.close() print "Now optimise with gifsicle -b -O3 anim.gif"
Categories: LUG Community Blogs

Adam Bower (quinophex): I finally managed to beat my nemesis!

Planet ALUG - Thu, 06/02/2014 - 23:40
I purchased this book http://www.amazon.co.uk/dp/0738206679 (Linked, by Barabasi) on the 24th of December 2002, I had managed to make 6 or 7 aborted attempts at reading it to completion where life had suddenly got busy and just took over. This meant that I put the book down and didn't pick it up again until things were less hectic some time later and I started again.

Anyhow, I finally beat the book a few nights ago, my comprehension of it was pretty low anyhow but at least it is done. Just shows I need to read lots more given how little went in.

comments
Categories: LUG Community Blogs

Dick Turpin: They don't come out?

Planet WolvesLUG - Thu, 06/02/2014 - 17:22
Customer: "Is it possible to swap the battery on this HP 8440p?"
Me: "For what?"
Customer: "No, can you take the battery out? I was in Currys looking at laptops the other day but they was no good as you couldn't remove the batteries."
Me: "You don't think that was deliberate to stop people pinching them do you?"
Customer: "Oh!"

Sheesh give me strength!
Categories: LUG Community Blogs

Dick Turpin: Give me your supplier.

Planet WolvesLUG - Thu, 06/02/2014 - 14:05
Customer: "I see you have some Windows 7 pro laptops for sale, can you do them any cheaper?"
Me: "I'm afraid not, we put very little markup on them and as they are refurbished they are very reasonably priced anyway."
Customer: "Seeing as it's pro I take it they come with Word and Excel?"
Me: "I'm sorry, why would Pro mean that? No that is just the operating system, Office will be extra"
Customer: "What? They're not much use without Word."
Me: "As I said, you can have Word/Office for an additional cost."
Customer: "Can you tell me where you buy them from please?"
Me: "I'm afraid not."
Customer: "Why not?"
Me: "Two reasons, one they only sell to Trade and two, why would I tell you that so that you go to them direct?"
Customer: "You're very rude?"
Me: "I'm sorry you feel that way, I think we will leave it there. Goodbye."

And they say sales people try to rip you off?


Categories: LUG Community Blogs

Andrew Savory: Login problems on Mac OS X Snow Leopard

Planet ALUG - Thu, 06/02/2014 - 13:05

These are notes from a tech support call with my parents last night, saved here for the next time stuff breaks.

If you’re running Mac OS X Snow Leopard (and possibly other versions), you may find you can’t log in. Symptoms are:

  • You click on your username and enter your password
  • The login screen is replaced by a blue screen for a short time
  • You are returned to the login screen.

After searching the interwebs I found Fixing a Mac OSX Leopard Login Loop Caused by Launch Services. It seems the problem is caused by corrupted cache files (which could be caused by the computer shutting down abruptly, or may just be “one of those things” that happens from time to time). This gave me enough information to come up with these “easy” steps to resolve it:

  1. Log in to the Mac as a different user*
  2. Press cmd-space to open Spotlight, type “Terminal”, and click on the Terminal application.
  3. Work out the broken user’s username by typing: ls /Users and look for the appropriate broken account name e.g. franksmith or janedoe.
  4. Find out the user ID of the user from the previous step by typing: id -u janedoe which will print a number something like 501
  5. Delete the user’s broken cache files. In the following command, be sure to substitute the correct username (in place of janedoe) and the correct user ID after the 023 (in place of the 501): su -l janedoe -c ‘rm /Library/Caches/com.apple.LaunchServices-023501.*’ (be very careful with this, you don’t want to delete the wrong things).
    • If you’re super-confident in figuring out backticks you could of course skip step 4 and instead of step 5 do: su -l janedoe -c ‘rm /Library/Caches/com.apple.LaunchServices-023`id -u janedoe`.*’
  6. Test by logging in to the troublesome user account.
Note that if you had any apps configured to launch at login, you may need to re-add these.

* This makes me think it’s good practice when setting up a Mac to always set up an extra user account, just in case stuff breaks.

Categories: LUG Community Blogs

Peter Cannon: Please work!

Planet WolvesLUG - Thu, 06/02/2014 - 12:40

Unless you’ve been living under a rock you’ll know I’ve just taken ownership of a Behringer Q502 mixing desk. Last night , full of excitement,  I looked forward to recording episode 69 of The Dick Turpin Road Show.  I should point out that everything was fine with my Fedora 19 machine as I had spent the whole of the previous day doing test recordings.

Knowing from bitter experience that kit and systems can let you down when you most need them around 6:30pm I set about setting up my systems for recording. “Oh no?” the network is not working on the Fedora box? Now I know I could have restarted the network but hey, let’s do a reboot anyway. Still no network? OK, lets not faff about, I don’t really need Internet access on this machine as in this instance it’s just a large, if expensive, recording device. “Oh no?” I can’t mount /dev/sdb1? keeps moaning about FUSE? Did modprobe fuse, nothing? And this is where I save the recordings! Lets look in Settings. Hang on, it can’t see my network card, sound card or recording device? This is serious!

So there I was boys and girls thinking “Looks like no recording tonight?” but hey, we tdtrs’ers are made of sterner stuff! I whipped out a Parted Magic Live CD to see if the hardware on my motherboard had failed. Nope, boots fine, I’m on the Internet and can play music. Parted Magic is pretty much a self-contained distro anyway with a browser, tools and most of the features you find on any basic Linux release. “Right lets download Ubuntu.” now that may surprise some people as I have been tagged as an Ubuntu hater, which is pretty unfair tbh. I don’t hate the distribution as such I just hate the cobblers that comes out of Canonical and the Ubuntu community about it. Anyway, I downloaded Ubuntu 12.04 to /dev/sdb1 (Which can be mounted I hasten to add) then used xfburn within Pmagic to burn the iso. Rebooted with the 12.04 Live CD so now we are running Ubuntu in memory.

Networking is OK as is sound and I can access /dev/sdb1 right lets install Audacity (To memory remember) Cool, Audacity sees the Q502 and is recording device. Changed the temp location for Audacity’s recording within preferences to /dev/sdb1 as it was using memory then Matt and I prayed that my 8GB of memory didn’t run out as we set about recording EP69

All in all this proves the saying “There’s more than one way to skin a cat.” Hats off to Ubuntu for a reliable distro, for Live CD’s and Matt’s encouragement of “The show must go on!” Sadly as of this moment I have no idea how to fix my broken Fedora I may well have to do a fresh install of something?

Categories: LUG Community Blogs

Steve Kemp: External Comments, updated

Planet HantsLUG - Thu, 06/02/2014 - 11:40

The simple external-comments code is now complete enough for me to stop poking it on a daily basis:

  • Although the comments are styled minimally you can override that with CSS.
  • Although the default "Add your reply" form is ugly you can replace it with your own.
    • The reply-form may go above or below the comments.
  • If you add an email field then your comments will include a gravitar link.
  • Comments are assumed to be in markdown now.
  • The commments may be retrieved in newest-first, or oldest-first order.
  • There's now a simple anti-spam plugin system present.

All in all I'm pretty happy with the way it works, and the server-code. The client-side Javascript is less good, but I'm probably done poking that too.

In an ideal world the client-side code should be a jQuery plugin, but I've not worked out how to make a static method (the JSONP callback) be a member of a jQuery plugin-object. So without that I have to re-pass the options around too many places, rather than making them a member of "this".

Meh, pull requests welcome for adding new storage back-ends (redis and sqlite are supported by default), and similarly for cleanups.

Links:

Categories: LUG Community Blogs
Syndicate content