Shell Loops me mad

Code junkies hangout here

Moderators: ChrisThornett, LXF moderators

Postby Gordon » Wed Jul 27, 2005 9:09 pm

I thought I recognized this code. It seems to be the code from the book "Beginning Linux Programming", Wrox Press, ISBN 1-874416-68-0, chapter 2, code starts on page 72 inmy copy and is copyrighted to Wrox Press 1996. Did K Windle write the original for Wrox?
Violence is the last refuge of the incompetent
User avatar
Gordon
LXF regular
 
Posts: 209
Joined: Thu Apr 07, 2005 5:01 pm
Location: Bradford, West Yorkshire

Postby Nigel » Wed Jul 27, 2005 9:58 pm

Does the code in the book have all the typos in it as well :?: :roll:
User avatar
Nigel
LXF regular
 
Posts: 1141
Joined: Fri Apr 08, 2005 8:03 pm
Location: Gloucestershire, UK

Postby RD » Wed Jul 27, 2005 11:24 pm

Gordon, after a quick google it would seem you was write and i had been given half finished stole code to finish as a result i will speak to the person who gave me the half finished code and to wrox about this matter, as a result i have had no choice but to edit and remove the copy right code from the forums and shall not be acceppting any more code from the person who was supose to "help me understand the shell coding" :evil: , this is an out right embaresment :oops: , Nigel it would seem that i have wasted your time and my own and was fooled into thinking that this was genuine. :evil: :evil:


NOT A HAPPY BUNNY :evil: :evil: :evil: :evil: :evil: :evil: :evil: :evil: :evil: :evil: :evil: :evil: :evil:
RD
LXF regular
 
Posts: 272
Joined: Mon Jul 25, 2005 2:53 am
Location: irc.ixl2.net

Postby Nigel » Wed Jul 27, 2005 11:57 pm

RD - well, at least you have learned something about shell scripts. And I have to admit, so have I - I hadn't used case statements in bash scripts before (although I use them all the time in C). So it hasn't been a complete waste of time.
You may find after a bit of research that you are free to use the script itself, but changing the copyright assignment is a definite no-no.

And this is a good example of why SCO won't find any dodgy code in Linux - with development done so publicly, anything that isn't kosher gets outed very quickly :wink:
User avatar
Nigel
LXF regular
 
Posts: 1141
Joined: Fri Apr 08, 2005 8:03 pm
Location: Gloucestershire, UK

Postby Gordon » Thu Jul 28, 2005 3:19 pm

Hi RD, sorry to have caused you embarresment and anger. But I had also tried the code a few years ago myself from the Wrox book and it didn't work for me then either. Although the code from the book is copyright Wrox press, it is still under the GNU GPL licence, so you can still use it or modify it as long as you make such modifications available to others and acknowledge Wrox as the copyright holders.

Don't let this put you off learning bash scripting though.

With all due respect to Wrox though, "Beginning Linux Programming" may be worth a read. Would Linux Format consider doing a review of the latest edition?

Nigel, The code from the book does have some of the same typoes, such as the "cdttitle" variable.

I hope nobody feels too badly about this.

Regards to all concerned. Gordon
User avatar
Gordon
LXF regular
 
Posts: 209
Joined: Thu Apr 07, 2005 5:01 pm
Location: Bradford, West Yorkshire

Postby RD » Thu Jul 28, 2005 3:53 pm

Hi,

Im embarrested and angriy simple because i was given a half finished code that i thought was genuine to later find out that it had/has been cp by Wrox, i feel cheated out of trying to learn a new skill, in future rather than jumping in head first i shall do some home work first.

BTW thanks
RD
LXF regular
 
Posts: 272
Joined: Mon Jul 25, 2005 2:53 am
Location: irc.ixl2.net

Postby Gordon » Thu Jul 28, 2005 3:57 pm

No probs. You could try looking at the "Advanced Bash Scripting Guide" which is on the LXF70 DVD.

Gordon
Violence is the last refuge of the incompetent
User avatar
Gordon
LXF regular
 
Posts: 209
Joined: Thu Apr 07, 2005 5:01 pm
Location: Bradford, West Yorkshire

Previous

Return to Programming

Who is online

Users browsing this forum: Yahoo [Bot] and 0 guests