Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added 'metacpan_url' method for fetching MetaCPAN links of module, re… #74

Merged
merged 1 commit into from Mar 22, 2017

Conversation

mickeyn
Copy link
Contributor

@mickeyn mickeyn commented Mar 22, 2017

#69

added 'metacpan_url' method to Module, Release and Author types.

Is anything missing? (I don't think Distribution has a representation page on the frontend)

@haarg
Copy link
Member

haarg commented Mar 22, 2017

A dist is https://metacpan.org/release/$dist_name.
A release is https://metacpan.org/release/$author/$release
A module is https://metacpan.org/pod/$module or https://metacpan.org/pod/release/$author/$release/$file_path.

@autarch
Copy link
Contributor

autarch commented Mar 22, 2017

Yeah, I think adding one for distribution would be nice.

@mickeyn
Copy link
Contributor Author

mickeyn commented Mar 22, 2017

the above suggested link for distribution will give the release (latest) page which can be a bit confusing given the data we hold in the Distribution object in the client (which reflects the distribution type in our ES data).
but I don't mind adding it - if that's what you want.

@haarg
Copy link
Member

haarg commented Mar 22, 2017

It looks like the module link is wrong in the code.

@mickeyn
Copy link
Contributor Author

mickeyn commented Mar 22, 2017

fixed (i hope) and added distirbution

@mickeyn
Copy link
Contributor Author

mickeyn commented Mar 22, 2017

added File as well (/source) to @haarg's request.

@haarg++

use strict;
use warnings;
use MetaCPAN::Client;
use DDP;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think DDP is actually being used?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

right, that's just part of my template :) will clean it out

Supports: Module, Release, Distribution, File & Author.
@mickeyn mickeyn merged commit c1008b6 into master Mar 22, 2017
@mickeyn mickeyn deleted the mickey/url_method branch March 22, 2017 15:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants