[perl-python] 20050125 standard modules

Discussion in 'Python' started by Xah Lee, Jan 25, 2005.

  1. Xah Lee

    Xah Lee Guest

    # -*- coding: utf-8 -*-
    # Python

    # some venture into standard modules

    import os

    # print all names exported by the module
    print dir(os)

    # print the module's online manual
    print help(os)
    # the above is also available in
    # interactive mode in Python terminal

    # example of using a function
    print 'current dir is:', os.getcwd()

    # this prints a list of existing modules
    print help('modules')

    # referecnce
    # http://python.org/doc/2.3.4/tut/node12.html

    # in Python terminal, type help() then
    # modules
    # to get a list
    # then a module name to see its doc.

    # take a gander of its richness and
    # suitability

    --------------------------
    in perl, i don't think there is one way to
    list available modules.

    one can write a program to find out. Start by
    use Data::Dumper; print Dumper \@INC;
    to see where is the standard modules located,
    then search for *.pm files to get an idea.

    -------------------------
    Note: this post is from the Perl-Python a-day mailing list at
    http://groups.yahoo.com/group/perl-python/
    to subscribe, send an email to perl-python-subscribe @ yahoogroups.com
    if you are reading it on a web page, program examples may not run
    because html conversion often breaks the code.
    Xah

    http://xahlee.org/PageTwo_dir/more.html
    Xah Lee, Jan 25, 2005
    #1
    1. Advertising

  2. Xah Lee

    Dan Perl Guest

    I sent the following feedback message to Yahoo! Groups about this abusive
    use of their service.

    Feel free to also report this as an abuse of the Yahoo! Groups service until
    the problem is resolved.

    Dan

    -----------
    As the owner of the perl-python group, p0lyglut (aka Xah Lee), has added two
    newsgroups to the mailing list of the group: comp.lang.perl.misc and
    comp.lang.python.

    First of all, I don't think anyone could have given Xah Lee an authorization
    on behalf of the newsgroups. I am not sure, but that is probably a
    violation of the Terms of Service in itself. I will leave this matter up to
    you to investigate.

    The daily messages of the perl-python group are unwanted by the two
    newsgroups. Just take a look at the follow-ups in the newsgroups that the
    perl-python postings have generated.

    I hope that not only the newsgroups will be removed from the perl-python
    group but that such an abuse will also be prevented in the future.

    Thanks,

    Dan Perl
    Dan Perl, Jan 25, 2005
    #2
    1. Advertising

  3. Xah Lee

    Dan Perl Guest

    I was wrong. He is just crossposting to the newsgroups without having them
    as members of the group.

    I wish there was a good way like that to stop these daily postings!

    Dan

    "Dan Perl" <> wrote in message
    news:...
    >I sent the following feedback message to Yahoo! Groups about this abusive
    >use of their service.
    >
    > Feel free to also report this as an abuse of the Yahoo! Groups service
    > until the problem is resolved.
    >
    > Dan
    >
    > -----------
    > As the owner of the perl-python group, p0lyglut (aka Xah Lee), has added
    > two newsgroups to the mailing list of the group: comp.lang.perl.misc and
    > comp.lang.python.
    >
    > First of all, I don't think anyone could have given Xah Lee an
    > authorization on behalf of the newsgroups. I am not sure, but that is
    > probably a violation of the Terms of Service in itself. I will leave this
    > matter up to you to investigate.
    >
    > The daily messages of the perl-python group are unwanted by the two
    > newsgroups. Just take a look at the follow-ups in the newsgroups that the
    > perl-python postings have generated.
    >
    > I hope that not only the newsgroups will be removed from the perl-python
    > group but that such an abuse will also be prevented in the future.
    >
    > Thanks,
    >
    > Dan Perl
    >
    Dan Perl, Jan 25, 2005
    #3
  4. On Tuesday 25 Jan 2005 17:50, Dan Perl wrote:
    > I was wrong. He is just crossposting to the newsgroups without having
    > them as members of the group.
    >
    > I wish there was a good way like that to stop these daily postings!
    >


    You can just filter on [perl-python]

    Pete
    Peter Nuttall, Jan 25, 2005
    #4
  5. Xah Lee

    Paul Lalli Guest

    "Xah Lee" <> wrote in message
    news:...
    --------------------------
    > in perl, i don't think there is one way to
    > list available modules.
    >


    <set followups to c.l.p.m, as this reply deals only with Perl>

    I'm torn between knowing that I shouldn't feed trolls, and my hatred of
    leaving faulty information about Perl unchecked, where some unsuspecting
    newbie might stumble across it.

    So to those newbies, you should know that just because this clown
    doesn't think there's a way, does not in any way imply that there
    actually isn't a way.

    For a list of standard modules included in your distribution of Perl,
    run the following command in your shell:
    perldoc perlmodlib

    To get a list of non-standard modules that have already been installed,
    read the documentation for the ExtUtils::Installed module:
    perldoc ExtUtils::Installed

    To see what other modules are available to be downloaded, visit
    http://www.cpan.org

    Paul Lalli
    Paul Lalli, Jan 25, 2005
    #5
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Abhinav
    Replies:
    0
    Views:
    384
    Abhinav
    Jul 27, 2004
  2. Hung ho
    Replies:
    6
    Views:
    350
    Alex Martelli
    Sep 4, 2004
  3. Rui Vilao
    Replies:
    2
    Views:
    343
  4. Xah Lee
    Replies:
    4
    Views:
    104
    gargoyle
    Jan 26, 2005
  5. bernd
    Replies:
    0
    Views:
    120
    bernd
    Jul 24, 2007
Loading...

Share This Page