Skip to content

channel list output is confusing #755

@jmesnil

Description

@jmesnil

The output of channel list is confusing... It looks like YAML file but it's not. It looks like a channel definition but it's not.

$ prospero channel list
Server /Users/jmesnil/Developer/wildfly/dist/target/wildfly-34.0.0.Beta1-SNAPSHOT/. is subscribed to following channels:

-------
# wildfly
  manifest: org.wildfly.channels:wildfly:34.0.0.Beta1-SNAPSHOT
  repositories:
    id: jboss-public-repository-group
    url: https://repository.jboss.org/nexus/content/groups/public/
    id: central
    url: https://repo.maven.apache.org/maven2
    id: jboss-ga-repository
    url: https://maven.repository.redhat.com/ga/
-------
  • # wildfly actually correspond to the name of the channel.
  • manifest is a different representation of the manifest coordinates (Maven GAV or URL)
  • repositories kind of represents array items

I'm not sure to understand why this command does not output the actual content of the .installation/installer_channels.yaml:

$ cat .installation/installer-channels.yaml
---
schemaVersion: "2.0.0"
name: "wildfly"
repositories:
  - id: "jboss-public-repository-group"
    url: "https://repository.jboss.org/nexus/content/groups/public/"
  - id: "central"
    url: "https://repo.maven.apache.org/maven2"
  - id: "jboss-ga-repository"
    url: "https://maven.repository.redhat.com/ga/"
manifest:
  maven:
    groupId: "org.wildfly.channels"
    artifactId: "wildfly"
    version: "34.0.0.Beta1-SNAPSHOT"
noStreamStrategy: "none"

Maybe we could provide a short and long output for channel list.
The short list would display the name of the channel as well as the manifest GAV or URL (which are the most important information) while the long list would dump .installation/installer_channels.yaml (which would be a valid YAML file corresponding to channel definitions).

Something like:

$ prospero channel list
wildfly org.wildfly.channels:wildfly:34.0.0.Beta1-SNAPSHOT

$ prospero channel list --full
---
schemaVersion: "2.0.0"
name: "wildfly"
repositories:
  - id: "jboss-public-repository-group"
    url: "https://repository.jboss.org/nexus/content/groups/public/"
  - id: "central"
    url: "https://repo.maven.apache.org/maven2"
  - id: "jboss-ga-repository"
    url: "https://maven.repository.redhat.com/ga/"
manifest:
  maven:
    groupId: "org.wildfly.channels"
    artifactId: "wildfly"
    version: "34.0.0.Beta1-SNAPSHOT"
noStreamStrategy: "none"

@spyrkob WDYT?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions