Parse package name and latest version from artifactory
See original GitHub issueFeature Request
Description
Badge in terra-doc-template looks for package in npm repository, However we have package published in internal repo and would like to reference.
Additional Context / Screenshots
We could have new prop called internalNpmPackage
in DocTemplate
. If we have user defined value for the prop then we build href
and img src
with internal repository url otherwise always fallback to normal npm lookup.
Cosiderations
We have npm package published to internal artifactory and would like to fetch package name and latest version to display.
Issue Analytics
- State:
- Created 5 years ago
- Comments:6 (6 by maintainers)
Top Results From Across the Web
How can I fetch the build versions from Artifactory repository
2) Download and parse the maven-metadata.xml file inside this folder. This file contains information about available versions.
Read more >Artifactory REST API - Artifactory 6.x - JFrog Wiki
Retrieve Latest Artifact. Description: Retrieves the latest artifact version from the specified destination. Latest Maven Release/Integration: Specify SNAPSHOT ...
Read more >Xray REST API - JFrog - JFrog Documentation
Learn how to use and configure cURL here. Base URL. New API Version. From version 2.4, JFrog Xray is introducing a new REST...
Read more >PyPI Repositories - JFrog - JFrog Documentation
For Artifactory to handle those packages correctly as PyPI packages they must be uploaded with pypi.name and pypi.version Properties. Automatic ...
Read more >Release Notes - Artifactory 6.x - JFrog Wiki
Overview. This page presents release notes for JFrog Artifactory describing the main fixes and enhancements made to each version as it is released....
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Ran into an issue that made me think about this issue. The doc site has a stale deployment where the npm badge pulls the latest version from the released npm package, but the docs show an older version. This causes confusion as the user will think they are looking at the latest released docs.
This can happen if npm publish is successful but the doc site deploy fails. Edit: Or someone like me forgets to do doc deployment after release.
This made me think that this badge should be pulling the version directly from the package.json file instead of pulling from npm service. I think this could mitigate all the concerns noted on this issue.
Talked with @mmalaker and @amichaelparker about this today. VoiceOver in Safari seems to get trapped in the SVG DOM loaded as a background image in this img.
Planning to update this so it is no longer a dynamically generated SVG via badgegen.
Tech Design
Replace this rendering with the following which would use a new prop
packageVersion
.In our example files, we pull the packageName from the package.json file for the component. We could pull the package version as well and pass this into the
<DocTemplate />
component.Considerations
packageVersion
prop is set, otherwise, fallback to the current rendering.packageUrl
prop that users could pass in. We could look into defaulting this tohttps://www.npmjs.org/package/${packageName}
if you don’t pass in apackageUrl