Linux Format forums Forum Index Linux Format forums
Help, discussion, magazine feedback and more
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

LXF 152 Tip of the Month.

 
Post new topic   Reply to topic    Linux Format forums Forum Index -> Magazine and coverdiscs
View previous topic :: View next topic  
Author Message
ajgreeny
LXF regular


Joined: Wed May 10, 2006 9:18 pm
Posts: 449
Location: Oxfordshire.

PostPosted: Sun Nov 06, 2011 8:14 pm    Post subject: LXF 152 Tip of the Month. Reply with quote

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!
Back to top
View user's profile Send private message
nelz
Site admin


Joined: Mon Apr 04, 2005 12:52 pm
Posts: 8455
Location: Warrington, UK

PostPosted: Sun Nov 06, 2011 8:30 pm    Post subject: Reply with quote

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

_________________
"Insanity: doing the same thing over and over again and expecting different results." (Albert Einstein)
Back to top
View user's profile Send private message
Spangwiches



Joined: Thu Sep 22, 2011 3:50 am
Posts: 81

PostPosted: Sun Nov 06, 2011 10:28 pm    Post subject: Reply with quote

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
_________________
http://uoou.info/
Back to top
View user's profile Send private message
ajgreeny
LXF regular


Joined: Wed May 10, 2006 9:18 pm
Posts: 449
Location: Oxfordshire.

PostPosted: Sun Nov 06, 2011 10:36 pm    Post subject: Reply with quote

nelz wrote:
You're right, that character shouldn't be there. The correct command is
Code:
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!
Back to top
View user's profile Send private message
nelz
Site admin


Joined: Mon Apr 04, 2005 12:52 pm
Posts: 8455
Location: Warrington, UK

PostPosted: Sun Nov 06, 2011 11:37 pm    Post subject: Reply with quote

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)
Back to top
View user's profile Send private message
ajgreeny
LXF regular


Joined: Wed May 10, 2006 9:18 pm
Posts: 449
Location: Oxfordshire.

PostPosted: Mon Nov 07, 2011 10:34 am    Post subject: Reply with quote

Fair enough.

I won't ask why, I will just nod my head and slowly back away.
_________________
Xubuntu 12.04 user, and loving it!
Back to top
View user's profile Send private message
nelz
Site admin


Joined: Mon Apr 04, 2005 12:52 pm
Posts: 8455
Location: Warrington, UK

PostPosted: Mon Nov 07, 2011 10:46 am    Post subject: Reply with quote

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)
Back to top
View user's profile Send private message
Arno



Joined: Mon Nov 07, 2011 9:33 pm
Posts: 2

PostPosted: Mon Nov 07, 2011 9:40 pm    Post subject: a software like Giver Reply with quote

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.
Back to top
View user's profile Send private message
nelz
Site admin


Joined: Mon Apr 04, 2005 12:52 pm
Posts: 8455
Location: Warrington, UK

PostPosted: Mon Nov 07, 2011 10:07 pm    Post subject: Reply with quote

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 Sad
_________________
"Insanity: doing the same thing over and over again and expecting different results." (Albert Einstein)
Back to top
View user's profile Send private message
Arno



Joined: Mon Nov 07, 2011 9:33 pm
Posts: 2

PostPosted: Mon Nov 07, 2011 10:43 pm    Post subject: Reply with quote

OK. But, I just tried to answer the ajgreeny's question about Giver :
Quote:
What a useful facility/utility for quick file viewing (and transfers) around the LAN; just like giver.
Back to top
View user's profile Send private message
nelz
Site admin


Joined: Mon Apr 04, 2005 12:52 pm
Posts: 8455
Location: Warrington, UK

PostPosted: Tue Nov 08, 2011 1:05 am    Post subject: Reply with quote

Of course, and it does look useful.
_________________
"Insanity: doing the same thing over and over again and expecting different results." (Albert Einstein)
Back to top
View user's profile Send private message
ajgreeny
LXF regular


Joined: Wed May 10, 2006 9:18 pm
Posts: 449
Location: Oxfordshire.

PostPosted: Tue Nov 15, 2011 12:01 pm    Post subject: Re: a software like Giver Reply with quote

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!
Back to top
View user's profile Send private message
View previous topic :: View next topic  
Display posts from previous:   
Post new topic   Reply to topic    Linux Format forums Forum Index -> Magazine and coverdiscs All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Linux Format forums topic RSS feed 


Powered by phpBB © 2001, 2005 phpBB Group


Copyright 2011 Future Publishing, all rights reserved.


Web hosting by UKFast