Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re^2: CPAN namespace hierarchy

by GrandFather (Saint)
on Jan 24, 2021 at 22:09 UTC ( [id://11127413]=note: print w/replies, xml ) Need Help??


in reply to Re: CPAN namespace hierarchy
in thread CPAN namespace hierarchy

The end goal is to figure out an appropriate XXX::YYY::ELF::Parser or XXX::YYY::Extract::ELF or some such module name for an ELF file parsing and data extraction module I'm putting together. The immediate driver for the project is to extract application images to be written to flash memory for an embedded system I'm working with at $work. That requires finding 60k of code out of a 6MB ELF file and dumping that into a suitable image to feed a boot loader. Given I haven't found anything useful on CPAN that works on Windows to do that I think it worth a slice of time to wrap the code I'm generating up for CPAN. The hierarchy stuff is just a means to figuring out what XXX, YYY and whatever else might be on that path might be.

Optimising for fewest key strokes only makes sense transmitting to Pluto or beyond

Replies are listed 'Best First'.
Re^3: CPAN namespace hierarchy
by LanX (Saint) on Jan 25, 2021 at 01:01 UTC
    You've described your use case.

    That could easily be done by filtering the list of modules with a regular expression.

    But you mentioned TK, hence you have more requirements than just running some regex.

    Without knowing these requirements I can only guess.

    (I can't comment on ELF)

    For instance:

    RAT has a foldable thread/post view.

    You could translate those modules into such a tree.

    You could use JS / CSS selectors to interactively filter such a tree.

    But I don't think you'll invest in this. ;)

    If yes you could use the js-console to interactively try it out.

    HTH :)

    Cheers Rolf
    (addicted to the Perl Programming Language :)
    Wikisyntax for the Monastery

      In the end I found https://www.cpan.org/modules/02packages.details.txt.gz which contains a list of CPAN packages - about 250000 entries. I opened the contained text file in an editor and searched for ELF. Turns out there aren't many entries. Some sort of tree/folding representation wouldn't actually have helped very much as it turns out.

      Optimising for fewest key strokes only makes sense transmitting to Pluto or beyond
        > Some sort of tree/folding representation wouldn't actually have helped very much as it turns out.

        The question is, would it have helped others? IOW is there a need?

        > Turns out there aren't many entries.

        Well ... searching CPAN for ELF is easy.

        I'm still puzzled what the tree view should display ...

        Cheers Rolf
        (addicted to the Perl Programming Language :)
        Wikisyntax for the Monastery

        I wonder if you couldn't (pre-)process that into JSON that you could then drive a d3 treemap pretty quickly.

        The cake is a lie.
        The cake is a lie.
        The cake is a lie.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11127413]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others pondering the Monastery: (5)
As of 2024-03-28 13:19 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found