Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re: NEW [doc://perldoc#deeplink] works now with all perldocs

by Anonymous Monk
on Feb 18, 2020 at 00:13 UTC ( #11113079=note: print w/replies, xml ) Need Help??


in reply to NEW [doc://perldoc#deeplink] works now with all perldocs

?? is doc:// still relevant ?

In my mind and browser I've stopped using it, but my fingers still type it on the keyboard sometimes

[doc://perlintro#String comparison]
String comparison
[doc://perlintro#String-comparison]
String comparison
[doc://open]
open
[doc://open.pm]
open.pm
[doc://open#Implementation Details]
Implementation Details
[doc://open.pm#Implementation Details]
Implementation Details
[doc://open#Implementation-Details]
Implementation Details
[doc://open.pm#Implementation-Details]
Implementation Details
[doc://sort]
sort
[doc://sort.pm]
sort.pm

Replies are listed 'Best First'.
Re^2: NEW [doc://perldoc#deeplink] works now with all perldocs ( pragmas/modules vs functions conflicts )
by LanX (Sage) on Feb 18, 2020 at 01:22 UTC
    I've submitted a new patch which should hopefully allow these alternative notations to work properly (after approval)

    • core module:
      [doc://B::Deparse] --> B::Deparse
    • core module.pm: (same)
      [doc://B::Deparse.pm] --> B::Deparse.pm
    • core module deeplink
      [doc://B::Deparse#Synopsis] --> Synopsis

    ... and for completenes

    • perlvar:
      [doc://$_] --> $_

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

    updates
    • expanded and commented tests
    • #IMPLEMENTATION-DETAILS was case sensitive
    • added perlvar

      G'day Rolf,

      I don't know if you've made several typos or if there's a problem with your patch. Obviously, as you're awaiting approval for the patch, I can't test it.

      You posted four links; these three are invalid:

      http://perldoc.perl.org/open.pm.html http://perldoc.perl.org/open.pm.html#Implementation-Details http://perldoc.perl.org/B/Deparse.pm.html

      In each case, if you remove the '.pm' part, they will be valid.

      I think it would also be a good test to show the open function ([doc://open]) resolving to https://perldoc.perl.org/functions/open.html and the open pragma ([doc://open.pm]) resolving to https://perldoc.perl.org/open.html.

      Update (additional information): More for completeness than anything else, I'll just add the http: is converted to https: by perldoc.perl.org regardless of whether the link is valid or not.

      — Ken

      [doc://open.pm#Implementation-Details] --> Implementation Details
      FAILs... because apparently anchor names are case sensitive, and the anchor names in use (mostly?) on perldoc.perl.org are AlL-cApS. Try:

      [doc://open.pm#IMPLEMENTATION-DETAILS] --> Implementation Details

      Should we convert the user-supplied anchor name to uppercase for this purpose? I tend to think so... but only if we believe that that will work 99.9% of the time for perldoc.perl.org.

      I reckon we are the only monastery ever to have a dungeon stuffed with 16,000 zombies.
        > FAILs... because apparently anchor names are case sensitive,

        Race commenting, I ran and expanded the tests as soon as I saw your approval :)

        > Should we convert the user-supplied anchor name to uppercase for this purpose?

        No, I don't think so, we can't keep up to date with changes in perldoc.perl.org.

        The author of the post should care.

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

      I've submitted a new patch...

      Applied.

Re^2: NEW [doc://perldoc#deeplink] works now with all perldocs
by LanX (Sage) on Feb 18, 2020 at 00:26 UTC
    > Implementation Details

    Pragmas having the same name like functions are a problem for doc, and there is no possible DWIM solution to decide which one is meant:

    • https://perldoc.perl.org/functions/open.html
    • https://perldoc.perl.org/open.html

    Your attempt to write open.pm to indicate a module/pragma might be a workaround.

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

    PS: FWIW personally I'm using my own JS solution, which takes the full URL but shortens the text.

    • so this https://perldoc.perl.org/open.html#Implementation-Details
    • becomes [HTTPs://perldoc.perl.org/open.html#Implementation-Details|open#Implementation-Details]
    • displays open#Implementation-Details

      Indeed, adding .pm to indicate the pragma DWYM. :-)

      I reckon we are the only monastery ever to have a dungeon stuffed with 16,000 zombies.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (4)
As of 2022-11-29 02:27 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Notices?