Licensing info not showing in "snap info"

Hi there,

I have a snap called shfmt that I packaged up for upstream.

I was just refreshing and noticed that when I run snap info shfmt that it shows the licensing info as unset.

❯ snap info shfmt
name:      shfmt
summary:   A shell parser, formatter and interpreter (POSIX/Bash/mksh).
publisher: Dustin Krysak (bashfulrobot)
store-url: https://snapcraft.io/shfmt
contact:   dustin@bashfulrobot.com
license:   unset
description: |
  "A shell parser, formatter and interpreter (POSIX/Bash/mksh)."
commands:
  - shfmt
snap-id:      QTbIv2VzcPGpSbhpsqpySciwS7sOE822
tracking:     latest/stable
refresh-date: 12 days ago, at 23:00 PDT
channels:
  latest/stable:    3.1.0 2020-04-22 (17) 1MB -
  latest/candidate: ↑                         
  latest/beta:      ↑                         
  latest/edge:      3.1.0 2020-04-22 (17) 1MB -
installed:          3.1.0            (17) 1MB -

But when I look in the web interface for the listing page (https://snapcraft.io/shfmt/listing) - I do have it set.

If I do not have a license specified in my snapcraft.yaml does that overwrite?

Any suggestions?

Thank you.

This is what I get:

$ snap info shfmt
name:      shfmt
summary:   A shell parser, formatter and interpreter (POSIX/Bash/mksh).
publisher: Dustin Krysak (bashfulrobot)
store-url: https://snapcraft.io/shfmt
contact:   dustin@bashfulrobot.com
license:   BSD-3-Clause
description: |
  "A shell parser, formatter and interpreter (POSIX/Bash/mksh)."
snap-id: QTbIv2VzcPGpSbhpsqpySciwS7sOE822
channels:
  latest/stable:    3.1.0 2020-04-22 (17) 1MB -
  latest/candidate: ↑                         
  latest/beta:      ↑                         
  latest/edge:      3.1.1 2020-05-04 (18) 1MB -

Maybe it just took a while for all the caches to be cleared etc?

I am perplexed. ha ha.

Snap info on an installed snap will show what you set in the snap’s snapcraft.yaml, not what you configured in the web Ui :slight_smile:

Dustin has the snap installed, while Merlijn does not, this is why you see different things.

Add a license field to your snapcraft yaml and rebuild the snap, then snap info will show that if you have the snap installed.

1 Like

Thank you!!

I’ll fix it up.