Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions bloom/generators/debian/generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -326,9 +326,9 @@ def generate_substitutions_from_package(
data['Description'] = format_description(package.description)
# Websites
websites = [str(url) for url in package.urls if url.type == 'website']
Copy link
Contributor

Choose a reason for hiding this comment

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

Personally I would rather visit any other websites in the package.xml than the distro index.

I personally would go for:

  • website
  • source
  • doc
  • fallback to index

The source or the docs gives me more insight in the package than the index.

Copy link

Choose a reason for hiding this comment

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

Why not the index? It contains all the other links you're mentioning (or it should).

Copy link
Contributor

Choose a reason for hiding this comment

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

If the index contains all urls from the package.xml that could work as well

Copy link
Member Author

Choose a reason for hiding this comment

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

As well as the link to the source in the Repository summary, the Doc in the API Docs right side menu. As well as Browse Source with the package specific path into the repository.

It lists any provided urls in the "Additional Links" section

ex: https://index.ros.org/p/depthai/#kilted
image

The goal is to have one central clearing hub with all the info.

homepage = websites[0] if websites else ''
if homepage == '':
warning("No homepage set, defaulting to ''")
homepage = websites[0] if websites else 'https://index.ros.org/p/%s/#%s' % (package.name, ros_distro)
if not websites:
warning("No homepage set, defaulting to %s" % homepage)
data['Homepage'] = homepage
repositories = [str(url) for url in package.urls if url.type == 'repository']
repository = repositories[0] if repositories else ''
Expand Down
7 changes: 4 additions & 3 deletions bloom/generators/rpm/generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -220,9 +220,10 @@ def generate_substitutions_from_package(
data['LicenseFiles'] = sorted(set(l.file for l in package.licenses if l.file))
# Websites
websites = [str(url) for url in package.urls if url.type == 'website']
data['Homepage'] = websites[0] if websites else ''
if data['Homepage'] == '':
warning("No homepage set")
homepage = websites[0] if websites else 'https://index.ros.org/p/%s/#%s' % (package, ros_distro)
if not websites:
warning("No homepage set, defaulting to %s" % homepage)
data['Homepage'] = homepage
# RPM Increment Number
data['RPMInc'] = rpm_inc
# Package name
Expand Down
Loading