LXF 152 Tip of the Month.

Comments, suggestions and questions about Linux Format magazine and the coverdiscs

Moderators: ChrisThornett, LXF moderators

LXF 152 Tip of the Month.

Postby ajgreeny » Sun Nov 06, 2011 8:14 pm

I believe there is a misprint in the Tip of the Month on page 75 of the LXF 152 magazine, as I have just spent a while trying to get the tip to work, ie, the "Instant web server" using python.

To start I could not find the character you printed in the command which I show here in red.
python -m SimpleHTTPServer 1111
I presume this must be a non-printing character which should not have shown in the magazine, as it does not even appear in the character map on my gnome 2.32 ubuntu 10.04, and I could not reproduce it in any way.

Being a subscriber, I copied the command from the pdf of the magazine and tried that, but that showed an "unknown option -" I then tried the command without the odd character and, BINGO! it worked without a problem.

What a useful facility/utility for quick file viewing (and transfers) around the LAN; just like giver.
Xubuntu 12.04 user, and loving it!
ajgreeny
LXF regular
 
Posts: 457
Joined: Wed May 10, 2006 8:18 pm
Location: Oxfordshire.

Postby nelz » Sun Nov 06, 2011 8:30 pm

You're right, that character shouldn't be there. The correct command is
Code: Select all
python -­m SimpleHTTPServer 1111
"Insanity: doing the same thing over and over again and expecting different results." (Albert Einstein)
User avatar
nelz
Site admin
 
Posts: 8523
Joined: Mon Apr 04, 2005 11:52 am
Location: Warrington, UK

Postby Spangwiches » Sun Nov 06, 2011 10:28 pm

Just as a note, on newer Pythons (I'm on 3.2.2, I don't know when it changed though) it's:

python -m http.server
User avatar
Spangwiches
 
Posts: 81
Joined: Thu Sep 22, 2011 2:50 am

Postby ajgreeny » Sun Nov 06, 2011 10:36 pm

nelz wrote:You're right, that character shouldn't be there. The correct command is
Code: Select all
python -­m SimpleHTTPServer 1111

For some strange reason, nelz, when copying your command into terminal by using select/middle click, an extra space is added between the "-" and "m".

Very odd! It doesn't show in your forum entry.
Xubuntu 12.04 user, and loving it!
ajgreeny
LXF regular
 
Posts: 457
Joined: Wed May 10, 2006 8:18 pm
Location: Oxfordshire.

Postby nelz » Sun Nov 06, 2011 11:37 pm

I pasted that from the text file I sent in (I wrote that tip) and watching the character counter in Kate, there is an invisible character between the - and m.
"Insanity: doing the same thing over and over again and expecting different results." (Albert Einstein)
User avatar
nelz
Site admin
 
Posts: 8523
Joined: Mon Apr 04, 2005 11:52 am
Location: Warrington, UK

Postby ajgreeny » Mon Nov 07, 2011 10:34 am

Fair enough.

I won't ask why, I will just nod my head and slowly back away.
Xubuntu 12.04 user, and loving it!
ajgreeny
LXF regular
 
Posts: 457
Joined: Wed May 10, 2006 8:18 pm
Location: Oxfordshire.

Postby nelz » Mon Nov 07, 2011 10:46 am

It's a non-typing character, 0xAD, so I didn't put it there. It probably got picked up in a cut and paste.
"Insanity: doing the same thing over and over again and expecting different results." (Albert Einstein)
User avatar
nelz
Site admin
 
Posts: 8523
Joined: Mon Apr 04, 2005 11:52 am
Location: Warrington, UK

a software like Giver

Postby Arno » Mon Nov 07, 2011 9:40 pm

If you want a software like Giver, you can try Transfer on LAN ( http://code.google.com/p/transfer-on-lan/ ). It's cross-platform, open source an requires no configuration.
Arno
 
Posts: 2
Joined: Mon Nov 07, 2011 9:33 pm

Postby nelz » Mon Nov 07, 2011 10:07 pm

The point about the tip is that it not only needs no configuration, it needs no installation either because distros come with Python as standard.

That's not to say that Transfer-on-LAN couldn't be useful, it looks like it could, but this is a tip for a quick to set up file transfer without needing to install or set up anything - just one command. However, it does work better with the command correctly typed :(
"Insanity: doing the same thing over and over again and expecting different results." (Albert Einstein)
User avatar
nelz
Site admin
 
Posts: 8523
Joined: Mon Apr 04, 2005 11:52 am
Location: Warrington, UK

Postby Arno » Mon Nov 07, 2011 10:43 pm

OK. But, I just tried to answer the ajgreeny's question about Giver :
What a useful facility/utility for quick file viewing (and transfers) around the LAN; just like giver.
Arno
 
Posts: 2
Joined: Mon Nov 07, 2011 9:33 pm

Postby nelz » Tue Nov 08, 2011 1:05 am

Of course, and it does look useful.
"Insanity: doing the same thing over and over again and expecting different results." (Albert Einstein)
User avatar
nelz
Site admin
 
Posts: 8523
Joined: Mon Apr 04, 2005 11:52 am
Location: Warrington, UK

Re: a software like Giver

Postby ajgreeny » Tue Nov 15, 2011 12:01 pm

Arno wrote:If you want a software like Giver, you can try Transfer on LAN ( http://code.google.com/p/transfer-on-lan/ ). It's cross-platform, open source an requires no configuration.

Thanks very much for that link Arno. I have just installed TOL on my machine, made a launcher for it in the Internet menu section (Ubuntu 10.04), and I have to say, it looks really great at the moment. I will play with it a for a while and see if it lives up to its first viewing promise.
Xubuntu 12.04 user, and loving it!
ajgreeny
LXF regular
 
Posts: 457
Joined: Wed May 10, 2006 8:18 pm
Location: Oxfordshire.


Return to Magazine and coverdiscs

Who is online

Users browsing this forum: No registered users and 2 guests