Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Plugin framework's "COLN" ignores view.yml #616

@provjeremys

Description

@provjeremys




Describe the bug
When customizing a view and then using the $COLN variable in a plugin, the default columns are considered.

To Reproduce
Use the following for view.yml

k9s:
  views:
    v1/pods:
      columns:
        - AGE
        - NAMESPACE
        - NAME
        - STATUS
        - READY
        - LABELS

and for plugin.yml

# $HOME/.k9s/plugin.yml
plugin:
  camel:
    shortCut: Ctrl-L
    description: Spit
    scopes:
    - po
    command: echo
    background: false
    args:
    - $COL1
    - $COL2
    - $COL3
    - $COL4
    - $COL5
    - $COL6

Steps to reproduce the behavior:

  1. Start k9s
  2. Highlight a pod
  3. press Ctrl+L
  4. See message at bottom saying "😎 Plugin command launched successfully!"
  5. Ctrl-C to close k9s
  6. Scroll up to see data output to stdOut as "$NAME $READY $RESTARTS $STATUS" etc.

Expected behavior
Data output as defined by view.yml

Screenshots
If applicable, add screenshots to help explain your problem.

Versions (please complete the following information):

  • OS: OSX 10.14.6
  • K9s 0.17.5
  • K8s v1.15.9

Additional context
This situation was discovered when trying to get additional information (i.e., the labels) into a plugin for integration with Helm.

Metadata

Metadata

Assignees

No one assigned

    Labels

    as-designedWorks as designedquestionFurther information is requested

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions