[8064] in Perl-Users-Digest

home help back first fref pref prev next nref lref last post

Perl-Users Digest, Issue: 1685 Volume: 8

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Tue Jan 20 17:17:11 1998

Date: Tue, 20 Jan 98 14:00:23 -0800
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)

Perl-Users Digest           Tue, 20 Jan 1998     Volume: 8 Number: 1685

Today's topics:
    Re: A question. <vchandra@mail.delcoelect.com>
    Re: are there something like "Perl for Idiot" in Bookst (Will Morse)
    Re: automatically running a perl script (Leonard Vovk)
    Re: CGI-BIN script - parameter encryption <bowlin@sirius.com>
        flat file db Vs Aliases.db by Perl. ming@utesa.edu
    Re: Forms and Perl <rgambill@census.gov>
    Re: Forms and Perl <rootbeer@teleport.com>
        grabbing email adresses from webpages <paashaas@rice.edu>
    Re: How to convert char to ASCII value? (brian d foy)
    Re: I need a man to lick me in to a frenzy!!! <rjc@liddell.cstr.ed.ac.uk>
    Re: I need some help pleeze <rootbeer@teleport.com>
    Re: I need some help pleeze (Andrew M. Langmead)
        Im new to perl. <vallery@bvsd.k12.co.us>
        Netscape vs. MSIE and Perl script <bahead@interlog.com>
    Re: Newer than New . . . :-)) (brian d foy)
    Re: package declaration <rootbeer@teleport.com>
        PERL Newbie Question (Wiley Scott McIntyre)
    Re: PERL Newbie Question (brian d foy)
        Perl Win32: iterating a folder, is it file or folder? randy.suinn@fci.com
    Re: Reload by perl - is it possible? (brian d foy)
    Re: Simple example of Select needed please <barnett@houston.Geco-Prakla.slb.com>
    Re: source into binary code (John Stanley)
    Re: source into binary code (John Stanley)
    Re: source into binary code <tchrist@mox.perl.com>
    Re: Style Q for modules:  best syntax for "hash" argume (Brad Appleton)
        Were can I get PERL <roesthus@online.no>
    Re: Were can I get PERL (brian d foy)
    Re: Win32::Filesecurity question. <bowlin@sirius.com>
        Digest Administrivia (Last modified: 8 Mar 97) (Perl-Users-Digest Admin)

----------------------------------------------------------------------

Date: Tue, 20 Jan 1998 15:11:39 -0500
From: "V. Chandrasekhar" <vchandra@mail.delcoelect.com>
Subject: Re: A question.
Message-Id: <34C504FB.226E@mail.delcoelect.com>

I realized some thing after posting the article below. I am 
pointing it out in the appropriate place. Regards.


V. Chandrasekhar wrote:
> 
> 1. I have data files that contain lines such as the following:
> 
> 1.092565  7.906363E-02 -.4043237  1.167659  .7806026  6.076082E-02
> -.6601424 1.024119  20.2  0  0  0
> 
> The above is one line consisting of 12 'words'. As may be seen, some of
> the words are in exponential format and some are not.
> 
> 2. I need to print the above to a file in hex, such that each word is
> two-byte. Thus, the output will look like:
> 
> XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
> 1   2   3   4   5   6   7   8   9   10  11  12
> 
> Word 1 is 1.092565 in hex
> Word 6 is 6.076082E-02 in hex etc.
> 

The hex data is multiplied and rounded such that it is within 
-32768 and 32767. In other words, the data is stored in 2 byte 
integer format.

> 3. I can read the line in and split it into the individual words and
> store them in $temp1, $temp2, etc. At this point, (I think that)
> $temp1 contains the string 1.092565 etc.
> 
> 4. I am lost as to what all should be done to perform the necessary
> conversions and print out the four hex characters for each word. I
> am struggling with pack and sprintf.
> 
> 5. I would appreciate help including pointers to books. (The only
> book I have is the Camel book. I am coming back to Perl after a
> three year layoff from Perl. I work for a service company and have
> very little say in what languages are employed, in general. I want
> to write very comprehendable code and find Perl terrific in this
> regard.)
> 
> 6. Regards.
> 
> Chandrasekhar


------------------------------

Date: 20 Jan 1998 14:59:23 -0600
From: will@Starbase.NeoSoft.COM (Will Morse)
Subject: Re: are there something like "Perl for Idiot" in Bookstore?
Message-Id: <6a337b$agg$1@Starbase.NeoSoft.COM>


Well, if you mean complete idiots, I guess it would be called 
something like "Advanced Visual Basic"....

"Learning perl" is still the best book.

Will
In article <01bd2501$51c37180$4c05c180@default>,
Chat U <uchat@rocketmail.com> wrote:
>I just jumped from win95 to Unix a couple weeks ago.  
>I'm do well with pascal and OK with C....but right now, perl is my choice
>:-)
>
>Any comments about Perl books for beginer?
>
>Thanks a lot.
>^_^
>


-- 
# Copyright 1997 Will Morse.  Internet repost/archive freely permitted.
# Hardcopy newspaper, magazine, etc. quoting requires permission.
# 
#      Gravity,                    #    Will Morse
#      not just a good idea,       #    Houston, Texas
#              it's the law.       #    will@starbase.neosoft.com
#
#   These are my views and do not necessarly reflect anyone else/
 =========================================================================
      By US Code Title 47, Sec.227(a)(2)(B), a computer/modem/printer
      meets the definition of a telephone fax machine. By Sec.227(b)
      (1)(C), it is unlawful to send any unsolicited advertisement to
      such equipment, punishable by action to recover actual monetary
      loss, or $500, whichever is greater, for EACH violation.
 =========================================================================



------------------------------

Date: 20 Jan 1998 14:24:04 -0500
From: lvovk@jusdnews.fir.fbc.com (Leonard Vovk)
Subject: Re: automatically running a perl script
Message-Id: <6a2tkk$45@nyb01c-623.fir.fbc.com>


In article <laP$tHA28Ox0EwFK@cydaps.co.uk>, James <James@cydaps.nospam.co.uk> writes:
> 
> Hi,
> 
> I have a script that I need to get to automatically startup at 10.00am
> GMT each day, everyday. Does anyone know how I can do this?
> 
> The script is running on a UNIX server with Perl5. Basically it is a
> script that sends emails out to each registered user of the site each
> day, but at the moment I cannot figure a way to automatically start the
> script at 10.00am without any human involvement.
> 
> Thanks for any help!
> 
> James
> 
> Please remove nospam. if emailing direct.
> 

man crontab.

Put the following line in your crontab
00 10 * * 0-7 /wherever/your/script/resides/yourscript.pl

HTH


------------------------------

Date: Tue, 20 Jan 1998 11:59:28 -0800
From: Jim Bowlin <bowlin@sirius.com>
To: Mike Haberfield <mikeh@summitfs.demon.co.uk>
Subject: Re: CGI-BIN script - parameter encryption
Message-Id: <34C50220.8E51422@sirius.com>

The "method=post" suggestions is good for keeping data out
of the URL.  However, the password will still be sent as
plaintext.  The only solution I know of is to use SSL.


- Jim Bowlin

Mike Haberfield wrote:

> Is there any way to either encrypt the parameters before they're sent to
> my cgi-bin script, or prevent the parameters from being displayed as
> part of the URL in the Location field when the result screen is
> displayed.


------------------------------

Date: Tue, 20 Jan 1998 14:21:46 -0600
From: ming@utesa.edu
Subject: flat file db Vs Aliases.db by Perl.
Message-Id: <885324596.516554765@dejanews.com>

Hi all!!

How can I 'insert' in my Sendmail 8.x a flat file db? I have all forward
information in a flat file Db instead of 'aliases' file, how can I make
my sendmail run a perl script everytime when a new message come in? (that
perl script will search over flat file DB and return a forward address to
sendmail,if any) I really have no idea to do it...

Thanks you for spend time reading this message..!!

MINg

-------------------==== Posted via Deja News ====-----------------------
      http://www.dejanews.com/     Search, Read, Post to Usenet


------------------------------

Date: Tue, 20 Jan 1998 14:52:11 -0600
From: Ron Gambill <rgambill@census.gov>
Subject: Re: Forms and Perl
Message-Id: <885329095.753336330@dejanews.com>


> Do you mean like:
>
> <FORM ACTION="http://your.server.com/scripts/myscript.pl" METHOD=POST>
>

I've been playing around with it today, and it seems to be a combination
of things I'm not quite getting. What I've been trying to do is run the
script on my PC before loading it up on the server.

I have Perl for Win32, like I said. I've recreated the structure of the
directories that reside on the server. When I access the page via the
form, I'm getting the code displayed instead of run.

I'm thinking two things - either I'm not handling the arguments correctly
in the script (I just found more info on this through the groups) or
might I need to install the perl into the directory structure I've set up
rather than in a generic structure.

Apologies if I've mis-posted. First time user of the groups.

-Ron
my office is trying to make me perl instead of cobol...

-------------------==== Posted via Deja News ====-----------------------
      http://www.dejanews.com/     Search, Read, Post to Usenet


------------------------------

Date: Tue, 20 Jan 1998 13:05:43 -0800
From: Tom Phoenix <rootbeer@teleport.com>
To: Ron Gambill <rgambill@census.gov>
Subject: Re: Forms and Perl
Message-Id: <Pine.GSO.3.96.980120130420.6319W-100000@user2.teleport.com>

On Tue, 20 Jan 1998, Ron Gambill wrote:

> I've installed Perl for Win32 on the NT server and will be using it to
> generate HTML pages based on responses (checkboxes, etc.) that I receive
> from a form. What is the correct syntax for the "action" in the HTML?

If you're trying to write HTML yourself, you probably want the HTML docs
or a newsgroup about HTML. But if you're using a module like CGI.pm to
write the HTML for you, that module's docs should be able to help you out.
Good luck! 

-- 
Tom Phoenix           http://www.teleport.com/~rootbeer/
rootbeer@teleport.com  PGP   Skribu al mi per Esperanto!
Randal Schwartz Case:  http://www.rahul.net/jeffrey/ovs/
              Ask me about Perl trainings!



------------------------------

Date: Tue, 20 Jan 1998 15:29:20 -0600
From: Pascal Hos <paashaas@rice.edu>
Subject: grabbing email adresses from webpages
Message-Id: <34C51730.ABBB7B9B@rice.edu>

I'm not familiar at all with perl, so I would like to know if it is
possible to collect the email addresses of webpages. Say one uses a
spider search and a webpage containing url's is displayed. How could one
obtain all the email addresses without actually opening the url's
themselves

Pascal
-- 
-----------------------------------------------------------
Pascal Hos                    |        paashaas@rice.edu
1746 Banks                    |        office:
Houston, TX 77098             |        Cox 207
(713) 523-2318                |        (713) 527-8750 x3626
-----------------------------------------------------------


------------------------------

Date: Tue, 20 Jan 1998 16:14:24 -0500
From: comdog@computerdog.com (brian d foy)
Subject: Re: How to convert char to ASCII value?
Message-Id: <comdog-ya02408000R2001981614240001@news.panix.com>
Keywords: from just another new york perl hacker

In article <34C4FC60.ADC@cory.eecs.berkeley.edu>, Edwin M Mercado <edwinm@cory.eecs.berkeley.edu> posted:

>>Does Perl have a built-in function to convert a single character
>to its ASCII value, e.g.

you can read about ord() and chr(), along with all of the rest of
the built-ins in the perlfunc man page.

good luck :)

-- 
brian d foy                                  <comdog@computerdog.com>
CGI Meta FAQ <URL:http://computerdog.com/CGI_MetaFAQ.html>
Comprehensive Perl Archive Network (CPAN) <URL:http://www.perl.com>


------------------------------

Date: 20 Jan 1998 21:32:31 +0000
From: Richard Caley <rjc@liddell.cstr.ed.ac.uk>
Subject: Re: I need a man to lick me in to a frenzy!!!
Message-Id: <eyhafcqde6o.fsf@liddell.cstr.ed.ac.uk>

In article <6a2iim$174$1@stok.co.uk>, Mike Stok (ms) writes:

ms> Might that be clearer as

ms> &lick_me until $frenzy;

I think in the interests of maintainability it would be better to 

	use POD::Canine;

	man_to_golden_retriever();

-- 
rjc@cstr.ed.ac.uk			_O_
					 |<



------------------------------

Date: Tue, 20 Jan 1998 11:50:55 -0800
From: Tom Phoenix <rootbeer@teleport.com>
To: David Waring <dwaring@nwsr.com>
Subject: Re: I need some help pleeze
Message-Id: <Pine.GSO.3.96.980120115003.6319M-100000@user2.teleport.com>

On 20 Jan 1998, David Waring wrote:

> Just wondering, what is the == doing when comparing two strings?  

It's a numeric comparison, so it doesn't compare two strings. The strings
are converted first to numbers. "F" converts to zero (but can give a
warning). Hope this helps!

-- 
Tom Phoenix           http://www.teleport.com/~rootbeer/
rootbeer@teleport.com  PGP   Skribu al mi per Esperanto!
Randal Schwartz Case:  http://www.rahul.net/jeffrey/ovs/
              Ask me about Perl trainings!



------------------------------

Date: Tue, 20 Jan 1998 20:25:57 GMT
From: aml@world.std.com (Andrew M. Langmead)
Subject: Re: I need some help pleeze
Message-Id: <En3nF9.1s2@world.std.com>

dwaring@nwsr.com (David Waring) writes:

>Just wondering, what is the == doing when comparing two strings?  In other
>words, why is  ($sex == "M") true when $sex = "F"?

Perl is converting both $sex and "M" into numbers, then comparing the
two for equality.

When perl sees that it needs a term in numeric form, but only has the
string form, it converts it into a number. Its method is to ignore all
preceding whitespace, look for an optional sign, as many numeric
characters and up to one decimal separator as it can find, then an
exponent part consisting of an "e" or "E" followed by an optional sign
followed by more numeric digits. It stops scanning as soon as it sees
any character, such as an alphabetic character, which doesn't adhere
to this format. (It uses the C libraries atof() function. If you have
a C compiler and are curious, check its documentation about atof().)

When using this algorithm, "M" and "F" both convert to the number
0. So if $sex has either an "M", an "F", or any alphabetic characters,
perl will evaluate it as "0 == 0", which is always true. If $sex
started with a non-zero number (with optional leading whitespace) it
would fail both the tests of "$sex == 'M'" and "$sex == 'F'"
-- 
Andrew Langmead


------------------------------

Date: Tue, 20 Jan 1998 13:52:59 -0700
From: Jason Vallery <vallery@bvsd.k12.co.us>
Subject: Im new to perl.
Message-Id: <Pine.GSO.3.95.980120135146.7209A-100000@bvsd.k12.co.us>

Im looking for a way to take the standard unix dictionary and have perl
chose a random entry. I want the word into a varible so that I may use
that as output. Thanks.. 

  _____________________________________________ 
 / __________  	 Jason Ray Vallery		\
| |       ___)_                                 |
| |       _____) vallery@bvsd.k12.co.us         |            
| |      ______) guide4@bvsd.k12.co.us          |            
| |    _______)  vallery@usa.net                |            
| \_______)      vallery_j@gems.colorado.edu    |
 \_____________________________________________/



------------------------------

Date: Tue, 20 Jan 1998 15:21:58 -0500
From: "Bruce A. Head" <bahead@interlog.com>
Subject: Netscape vs. MSIE and Perl script
Message-Id: <34C50766.35A0@interlog.com>

I'm not sure whether this is a Perl question or a CGI question (or an
HTTP question!) but I've also posted it in
comp.infosystems.www.authoring.cgi

I'm using the a Perl CGI script to redirect the user to different pages
from a form interface (you know, the "jump to" text boxes you see
everywhere).  Since I'm using the redirect form nested within a frame, I
wanted to trap out certain URL's that I want to appear in the parent
frame
rather than the child frame.

The original script used this code, based on HTTP response headers.  The
variable "target" refers to the name of the frame that you wanted all
the URL's to return to (this was included as a hidden field on the HTML
form text box) and "dest" was the URL itself:

   print "Window-target: $in{'target'}\n"
   print "Location: $in{'dest'}\n\n";

I modified the script as follows:

 if ($gotourl eq "http://www.sample.com/sample.htm") {
        print "Window-target: _parent\n";
        print "Location: $gotourl\n\n";
        exit;

My intention here was to have the CGI redirect to a parent window rather
than the child window, if the url is sample.htm.  I didn't really know
what I was doing in terms of HTTP response headers, so instead of using
a specific name for the parent frame, I used the term "_parent"
instead.  While this works fine in Netscape 3.0, it does not work in
Internet Explorer 4.0.  Internet Explorer returns this URL to the child
frame the same as any other URL.  It appears that IE doesn't recognize
the use of the term "_parent" within this context.

Any suggestions or advice on how I can get IE to recognize this code?

Please e-mail me at <a
href="mailto:bahead@interlog.com">bahead@interlog.com</A> as I don't
have regular access to this newgroup.  Thanks.

Bruce Head


------------------------------

Date: Tue, 20 Jan 1998 16:16:09 -0500
From: comdog@computerdog.com (brian d foy)
Subject: Re: Newer than New . . . :-))
Message-Id: <comdog-ya02408000R2001981616090001@news.panix.com>
Keywords: from just another new york perl hacker

In article <6a2tiq$g8s@dfw-ixnews6.ix.netcom.com>, "Bob" <rgbelon@yahoo.com> posted:

>wonder if someone could recommend a descent book on the subject. Not an

[anything by O'Reilly and Associates is good.]

enough to get you started:

Learning Perl
Randal L. Schwartz & Tom Christiansen
ISBN 1-56592-284-0 
<URL:http://www.oreilly.com>

Programming Perl
Larry Wall, Tom Christiansen & Randal L. Schwartz
ISBN 1-56592-149-6
<URL:http://www.oreilly.com>

-- 
brian d foy                                  <comdog@computerdog.com>
CGI Meta FAQ <URL:http://computerdog.com/CGI_MetaFAQ.html>
Comprehensive Perl Archive Network (CPAN) <URL:http://www.perl.com>


------------------------------

Date: Tue, 20 Jan 1998 12:04:57 -0800
From: Tom Phoenix <rootbeer@teleport.com>
To: Dzuy Nguyen <dzuy@dazel.com>
Subject: Re: package declaration
Message-Id: <Pine.GSO.3.96.980120115349.6319O-100000@user2.teleport.com>

On Mon, 19 Jan 1998, Dzuy Nguyen wrote:

> How can you declare a package name which is a variable?

The declaration 'package foo;' is merely a note to the compiler that new
symbols will go into the foo:: namespace by default. If you wish to put a
symbol into a different namespace at runtime, you could use a soft
reference, perhaps something like this: 

    my $pkg = 'foo';
    my $name = 'bar';
    my $value = "the value goes here";
    {
	no strict 'refs';
	${"${pkg}::$name"} = $value;
    }
    print "$foo::bar\n";

Hope this helps!

-- 
Tom Phoenix           http://www.teleport.com/~rootbeer/
rootbeer@teleport.com  PGP   Skribu al mi per Esperanto!
Randal Schwartz Case:  http://www.rahul.net/jeffrey/ovs/
              Ask me about Perl trainings!



------------------------------

Date: Tue, 20 Jan 1998 21:19:24 GMT
From: mcintyres@hjc.cc.md.us (Wiley Scott McIntyre)
Subject: PERL Newbie Question
Message-Id: <34c50e49.28426020@nntpserver.pppl.gov>

Hi out there,

I am a real newbie to PERL.  I was wondering... I would like to
install PERL on our Sun Netra web server and would like to know where
I can get the latest version for Unix System 5 Release 4.  Then, I
would like to know how can I install it?

Any help in this area would be greatly appreciated. :)


Best Regards,
Scott McIntyre

======================================================================
  HAGERSTOWN JUNIOR COLLEGE           E-MAIL: mcintyres@hjc.cc.md.us
  11400 ROBINWOOD DRIVE                PHONE: 301-790-2800 x327
  HAGERSTOWN MD 21742-6590 USA           FAX: 301-739-0737
======================================================================
                  Home Page: http://www.hjc.cc.md.us/
======================================================================


------------------------------

Date: Tue, 20 Jan 1998 16:39:52 -0500
From: comdog@computerdog.com (brian d foy)
Subject: Re: PERL Newbie Question
Message-Id: <comdog-ya02408000R2001981639520001@news.panix.com>
Keywords: from just another new york perl hacker

In article <34c50e49.28426020@nntpserver.pppl.gov>, mcintyres@hjc.cc.md.us posted:

>I am a real newbie to PERL.  I was wondering... I would like to
>install PERL on our Sun Netra web server and would like to know where
>I can get the latest version for Unix System 5 Release 4.  Then, I
>would like to know how can I install it?

go to <URL:http://www.perl.com>

download the latest perl distribution (latest.tar.gz)

gunzip and un-tar it.

read the README.

-- 
brian d foy                                  <comdog@computerdog.com>
CGI Meta FAQ <URL:http://computerdog.com/CGI_MetaFAQ.html>
Comprehensive Perl Archive Network (CPAN) <URL:http://www.perl.com>


------------------------------

Date: Tue, 20 Jan 1998 15:36:15 -0600
From: randy.suinn@fci.com
Subject: Perl Win32: iterating a folder, is it file or folder?
Message-Id: <885330729.864092168@dejanews.com>

This question applies to Win32:

When iterating the contents of a folder, what is the method to determine
if it's a file or folder?

I have some folders that can be named just about anything.

-------------------==== Posted via Deja News ====-----------------------
      http://www.dejanews.com/     Search, Read, Post to Usenet


------------------------------

Date: Tue, 20 Jan 1998 16:17:20 -0500
From: comdog@computerdog.com (brian d foy)
Subject: Re: Reload by perl - is it possible?
Message-Id: <comdog-ya02408000R2001981617200001@news.panix.com>
Keywords: from just another new york perl hacker

In article <34C4E918.4DD6@inconnect.com>, NerveGas-goaway@inconnect.com posted:

>> > Is it possible to make a reload by a command of perl?
>
>   Not with Perl, but you can use a META tag with a refresh. for
>example, to make my cgi reload itself every 10 seconds,

i can do the same thing with Perl.  so can everyone else that has
read the Netscape docs on a certain HTTP header... :)

-- 
brian d foy                                  <comdog@computerdog.com>
CGI Meta FAQ <URL:http://computerdog.com/CGI_MetaFAQ.html>
Comprehensive Perl Archive Network (CPAN) <URL:http://www.perl.com>


------------------------------

Date: Tue, 20 Jan 1998 14:05:47 -0600
From: Dave Barnett <barnett@houston.Geco-Prakla.slb.com>
Subject: Re: Simple example of Select needed please
Message-Id: <34C5039B.5A052F64@houston.Geco-Prakla.slb.com>

Paul Ryder wrote:
> 
> Hi,
> 
> Could someone just outline a simple example of how select works.
> 
> Into the perl script will be coming the following :
> 
> A Socket Connection
> Keyboard STDIN
> 
> How can i use select to listen for both? no need to go into the
> listen/socket code, i just need to see how select works ..
> 
select() allows you to set the "current default" file handle. 
select(STDOUT) selects STDOUT such that print "junk\n" will print junk
followed by a newline to STDOUT.  select(FILE) followed by print
"junk\n" would print junk followed by a new line to the file referenced
by filehandle "FILE".


> Thanks in advance!
> 
HTH

> Regards
> 
> Paul.

Dave

-- 
"Security through obscurity is no security at all."
		-comp.lang.perl.misc newsgroup posting

------------------------------------------------------------------------
* Dave Barnett               U.S.: barnett@houston.Geco-Prakla.slb.com *
* DAPD Software Support Eng  U.K.: barnett@gatwick.Geco-Prakla.slb.com *
------------------------------------------------------------------------


------------------------------

Date: 20 Jan 1998 20:00:50 GMT
From: stanley@skyking.OCE.ORST.EDU (John Stanley)
Subject: Re: source into binary code
Message-Id: <6a2vpi$nhc$1@news.orst.edu>

In article <Pine.OSF.3.95.980120101020.31207H-100000@primal.ucdavis.edu>,
Jason Christian  <jason@primal.ucdavis.edu> wrote:
>(1) I am not trying to educate you about commercial software, I am
>trying to educate you about (some|one) buyer(s) of software (services).
>Why did I agree to such terms in the first place?  Because,
>unsophisticated dolt that I am, I wasn't totally clued in to the costs
>of proprietary contracts.  

Then you have just proven my point. There must have been SOME reason you
agreed to those terms, and thus there are SOME REASONS that people will
pay for things that they could get a free version of. That is the answer
to the question "why would anyone..."

>Probably the fluoride.  Actually, the second guy is still doing what he
>was doing, making accounting systems for small businesses, albeit on more
>current platforms.  In so doing, he has moved towards "free software,"
>since others can now read and modify his code.

When you claimed it was "just as impossible" to upgrade, I assumed it
really was just as impossible, which means the fellow was no longer
doing what he was doing. I didn't imagine that he was still working as a
programmer and you knew how to get ahold of him.

>Aha!  We're not speaking the same language!  "Free software" means, to
>me, that the code is available for reading and modifying.  

Which does not align at all with the statement "giving it away for free". 

>Oh, I expect that he may make a living adapting that code.  Indeed, I
>have given him leads of other people in the industry.  The way I see it,
>if they pay him to adapt the software to their needs, he will likely
>come up with a few new tricks that will work for us.  

And would they pay him if he gave them the code for free, and they
decided to modify it themselves? No, they wouldn't. He loses money. He
is wonderfully altruistic, but hungry. And he won't get paid until he
comes up with another application. 

>> Nor does the other need apply to all transactions. That is all I would
>> like people to admit. 
>
>My opinion is that there is a lot more opportunity to make a living as a
>professional provider of software services than as a manufacturer of
>geegaws, and that most of the people who think they will strike it rich
>by writing some product for the mass market are deluding themselves.
>But I Could Be Wrong.

And you could be irrelevant. Whether or not they will succeed or make a
fortune is not the issue. That they not be prevented from trying is.
"You can't do that because you might fail" is a wonderful way to create
failure.

>No sir.  "freedom" relates to our ability to have the *code*, as opposed
>to the functionality.  It does not relate to the necessity of paying for
>services.  The software is free; the programmer's time certainly is not.

And as I have pointed out elsewhere, having code is not always a good
thing. Letting the doctors and nurses "fix" the MRI software isn't the
way to run a hospital. Trying to run a small software company and
having everyone and their brother 1) tell you how to write your code
better by changing line 35 of the routine xxx.foo, even though your
code does what it says it does, and 2) modifying your code and then
complaining when it doesn't work anymore, is a terrible way to run a
small software company.

>> unethical and unprofessional. There are lots of professionals who work
>> in manufacturing just so you can buy those widgets, and they do it quite
>> ethically.
>
>You in the straw business, or what?  

I reply to what you write. If that is "straw business", then I guess
so.

>One of the things that characterizes
>the professions is that they develop well-defined bodies of ethics,
>...
>Such codes are not necessary in the widget industries.  

When I last read the code of ethics for the IEEE, it did not excuse
electrical engineers who design the electrical parts of widgets from
the code. I do not recall the code of ethics for the ACM or ACS
excusing WidgetInc employees from those codes. In fact, when I see
discussions of the codes of ethics for those groups, it always seems to
include as a major topic ethics in a corporate climate.  E.g., "you are
a EE who has been asked to design X with certain known limitations..."

Such codes not necessary in the widget industries? I would counter that
such codes exist BECAUSE of industry.

>The lack of a formal ethical code in no way implies that subscribers to
>the other ethos are unethical.  

No, but your statement that "free software" is a statement of
professionality and ethics implies that "non free software" is
otherwise.

>> Show me where I said it cannot.
>
>I believe I have described what most of us understand by "free
>software."  

In other words, you cannot.

>If you agree that that is a functional business model, and
>can understand why at least this *user* shies away from your obfuscated
>code, then I have no argument with you.

I have never said that "free software" was an invalid business model,
only that you cannot make a living giving software away for free. I
have never said that nobody will shy away from obfuscated code, only
that some may not consider that a deal-breaker and may have more
important concerns. That you are arguing with me would imply that you
have an argument with what I said and not with what I did not say. 

>I think it *ought* to be considered unethical for a professional in the
>software services industry to lock up code.  

Well, I think otherwise. I would miss the commercial software that is
available only because the source is not given out.

>I do not believe that someone
>with training and talent in program ought to be restricted to being a
>Professional Software Engineer.  

This is from left field. Who said this?

>Physicians and attorneys are often
>employed by businesses, or are entrepreneurs in their own businesses; so
>long as they do not claim to be "practicing medicine" or "practicing
>law," such activities are not unethical.

Back the horses up, Ramone. 

Let me get this straight. You are saying that you think it is not
unethical for a doctor to run his own business, as long as he does not
claim he is practicing medicine? You are saying the same for lawyers?
By that claim, you imply that it IS unethical for a doctor to run his
own business (or work for someone else) and claim he is practicing
medicine.  Ditto for lawyers.

It is not unethical for a doctor to form a business to practice medicine
and announce that he is practicing medicine. Who he works for has no
bearing on the matter. As long as he is licensed in the state he is
working in, he can claim that he is practicing medicine whether he works
for WidgetCo as a staff doctor or for himself in his own office. 

Ditto for lawyers. 



------------------------------

Date: 20 Jan 1998 20:15:01 GMT
From: stanley@skyking.OCE.ORST.EDU (John Stanley)
Subject: Re: source into binary code
Message-Id: <6a30k5$2ah$1@news.orst.edu>

In article <m3k9bv7xwb.fsf@windlord.Stanford.EDU>,
Russ Allbery  <rra@stanford.edu> wrote:
>John Stanley <stanley@skyking.OCE.ORST.EDU> writes:
>> for and that which they do not. Why get gcc from Cygnus when you can get
>> it for free?

That was a rhetorical question intended to draw the discussion full
circle back to the original question asked about Dan's and Betty's
code. "Why buy Dan's code when you can get something from Betty for
free?" There are reasons, which I gave, which apply to Cygnus, too.

>This is a common type of consulting; right now, a lot of companies are a
>bit more aggressive about keeping the results of outside consulting work
>than I think they should be.  The results of not letting the consultant
>then release the work for free tends to be that it just languishes in the
>possession of the company (which is in some completely different business
>and has no marketing infrastructure for such things) and the consultant
>goes on to be paid for other work.  Making the code freely available
>wouldn't be a loss for either.

It would be a loss for the consultant, who could sell that code to
someone else. It would not be a direct loss to the company, except that
it would provide help to any competitors. E.g, if the code were a
complex decision making system, then it would help a competitor to know
what code you were running to make your decisions, or just by having a
complex decision making system, too. They would benefit at your expense,
and although that is great altruism, it doesn't help your company
succeed and meet its payroll.

>>> Sure there is.  There are people who sell commercial Perl support.
>
>> Oh my God! You mean they won't give me code for free, they will sell me
>> the answer I want? Don't tell Greg. He'll call them 'greedy code
>> hoarders' and think they have no altruism at all.
>
>I think the difference that people are pointing at is between giving away
>existing code for free and writing code for free.  I'll be happy to give
>away my existing code; if someone wants me to solve a problem for them, I
>don't have existing code to solve the problem, and I'm not otherwise in
>the mood to do it for free, I would expect them to pay me.

When I call a technical support for help on a product, I find that what
I am asking quite often is something that has already been asked. When I
was in the position of handling technical support, I found the same
thing. When I read this newsgroup, I find it in spades.

If a company doesn't charge until I ask a new question, that's one
thing. If they charge me for a support contract then that's "greedy code
hoarding" when they give me an answer that has been given to someone
else. I'm sorry, but if that is bad once, then it is bad whenever it
happens.

>This is true.  But similarly the commercial support for such small bits of
>code, even if they are commercial products, tends to be extremely bad.  So

Depends on what it is.

>it's six of one and a half-dozen of another, and in neither case can one
>really make a general argument for or against either side.

Since I wasn't making a general argument, I guess that's ok.



------------------------------

Date: 20 Jan 1998 20:45:39 GMT
From: Tom Christiansen <tchrist@mox.perl.com>
Subject: Re: source into binary code
Message-Id: <6a32dj$qsb$1@csnews.cs.colorado.edu>

 [courtesy cc of this posting sent to cited author via email]

In comp.lang.perl.misc, Jason Christian <jason@primal.ucdavis.edu> writes:
:On 19 Jan 1998, John Stanley wrote:
:There are two different ethoses (what the hell is the plural of ethos?)

"ethoi", of course.  :-)  

--tom
-- 
	Tom Christiansen	tchrist@jhereg.perl.com
"I find this a nice feature but it is not according to the documentation.
   Or is it a BUG?"
"Let's call it an accidental feature. :-)" Larry Wall in <6909@jpl-devvax.JPL.NASA.GOV>


------------------------------

Date: 20 Jan 1998 20:26:51 GMT
From: nospam@no.uce.please (Brad Appleton)
Subject: Re: Style Q for modules:  best syntax for "hash" arguments?
Message-Id: <6a31ab$1dhg$1@schbbs.mot.com>

In article <34C1208B.11B23F97@zeegee.com>, Eryq <eryq@zeegee.com> writes:
>Steve A. Chervitz wrote:
>
>> When a function can accept either named or unnamed parameters, it would
>> be nice to have a standard mechanism for discriminating these cases. For
>> example, it's convenient to allow the following:
>> 
>>      new->Foo("MyFoo");                # Gets default settings.
>>      new->Foo(-name   => "MyFoo",      # Custom settings.
>>               -flavor => "vanilla");
>> 
>> If named parameters always start with a "-" then it is easy to
>> distinguish these situations, regardless what case is used for the tags.
>
>I have to disagree.  What about:
>
>	Foo->new($fooname);
>
>where $fooname just happens to be "-bar"?  A string is a string;
>there's no way to distinguish the intent of the caller.

The way I usually see this done is to have an optional anonymous hash
as the first argument (which presumes the subsequent arg won't also be
an anonymous hash):

  Foo->bar( { -flavor => 'chocolate' }, $foobar );

The method usually looks something like:

  sub bar {
     my $self = shift;
     my %options = ( ref($_[0]) ? shift : () );
     my $flavor = $options{-flavor} || $DEFAULT_FLAVOR;
     ...
  }

Sometimes it won't be enough to simply do a "ref" check like the above.
You may actually need to check if its a hash-ref (as opposed to an
array-ref or a scalar-ref etc.).

Cheers!
-- 
Brad Appleton <bradapp@enteract.com> | http://www.enteract.com/~bradapp/
 "And miles to go before I sleep."   |  3700+ WWW links on CS & Sw-Eng


------------------------------

Date: 20 Jan 1998 21:09:40 GMT
From: "Rolf Xsthus" <roesthus@online.no>
Subject: Were can I get PERL
Message-Id: <01bd25e7$59d2c420$2ce54382@it-step>

Were can I get PERL from?

Anders Xsthus
E-Mail: roesthus@online.no


------------------------------

Date: Tue, 20 Jan 1998 16:27:18 -0500
From: comdog@computerdog.com (brian d foy)
Subject: Re: Were can I get PERL
Message-Id: <comdog-ya02408000R2001981627180001@news.panix.com>
Keywords: from just another new york perl hacker

In article <01bd25e7$59d2c420$2ce54382@it-step>, "Rolf Xsthus" <roesthus@online.no> posted:

>Were can I get PERL from?

what's PERL?  you can get perl from CPAN.

good luck :)

-- 
brian d foy                                  <comdog@computerdog.com>
CGI Meta FAQ <URL:http://computerdog.com/CGI_MetaFAQ.html>
Comprehensive Perl Archive Network (CPAN) <URL:http://www.perl.com>


------------------------------

Date: Tue, 20 Jan 1998 12:09:17 -0800
From: Jim Bowlin <bowlin@sirius.com>
To: Tim Gray <tim@hcirisc.cs.binghamton.edu>
Subject: Re: Win32::Filesecurity question.
Message-Id: <34C5046D.76883097@sirius.com>

Tim,  

I have struggled with this module for some time.
It is pretty much broken and useless in both 5.003 and
5.004.  I was told that the next release of lib-win32 
should fix these problems.

In the meantime I have used shareware from 
http://pw2.netcom.com/~trias/ntsec.htm

I then use system("...") calls to these programs to modify filepermissions, it is
slow and ugly and I don't report errors, 
but it works.


-- Jim Bowlin

Tim Gray wrote:
> 
> When I checked the pod and it looks like the set subroutine needs a
> hash of the complete permission set and does not support partial
> changes.  Is that the case?  What I am looking for is something that I
> can add or remove a single user's or group's permissions from a
> directory tree without modifying other permissions.  For example
> 
> |-MyDir (foo, bar and xyzzy, change permission)
> |     \-MySubDir (foo and bar, change permission)
> |              \-SubSubDir (foo, change permission)
> 
> lets say I want to remove all of bar's permissions.  If from MyDir I
> remove bar and check recurse subdirectories then I will end up giving
> xyzzy permissions that I didn't want him to have.  I want to be able
> to remove bar recursively without changing anything else.
> 
> Is there a tool out there that can do such things or does the API
> prevent it?  Thanks.


------------------------------

Date: 8 Mar 97 21:33:47 GMT (Last modified)
From: Perl-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin) 
Subject: Digest Administrivia (Last modified: 8 Mar 97)
Message-Id: <null>


Administrivia:

The Perl-Users Digest is a retransmission of the USENET newsgroup
comp.lang.perl.misc.  For subscription or unsubscription requests, send
the single line:

	subscribe perl-users
or:
	unsubscribe perl-users

to almanac@ruby.oce.orst.edu.  

To submit articles to comp.lang.perl.misc (and this Digest), send your
article to perl-users@ruby.oce.orst.edu.

To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.

To request back copies (available for a week or so), send your request
to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
where x is the volume number and y is the issue number.

The Meta-FAQ, an article containing information about the FAQ, is
available by requesting "send perl-users meta-faq". The real FAQ, as it
appeared last in the newsgroup, can be retrieved with the request "send
perl-users FAQ". Due to their sizes, neither the Meta-FAQ nor the FAQ
are included in the digest.

The "mini-FAQ", which is an updated version of the Meta-FAQ, is
available by requesting "send perl-users mini-faq". It appears twice
weekly in the group, but is not distributed in the digest.

For other requests pertaining to the digest, send mail to
perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
sending perl questions to the -request address, I don't have time to
answer them even if I did know the answer.


------------------------------
End of Perl-Users Digest V8 Issue 1685
**************************************

home help back first fref pref prev next nref lref last post