charmstore icon indicating copy to clipboard operation
charmstore copied to clipboard

document promulgation revision semantics

Open rogpeppe opened this issue 7 years ago • 0 comments

[Original issue created by @jrwren at https://github.com/CanonicalLtd/charmstore-client/issues/219]

given promulgation's limited user base we can put it in markdown in this repo. Really, it is OK.

The first promulgated version gets a revision starting at zero. If a users charm with versions -1 and -0 were never promulgated and -2 is promulgated, then it becomes rev 0 of the promulgated charm.

e.g.

$ charm push ...
$ charm publish cs:~bob/trusty/foopress-0
$ charm push...
$ charm publish cs:~bob/trusty/foopress-1
$ charm push...
$ charm publish cs:~bob/trusty/foopress-2
$ charm promulgate cs:~bob/trusty/foopress-2
cs:trusty/foopress-0

That the charms point to the same place can been seen using the charm show command and the hash field.

charm show cs:~bob/trusty/wordpress-2 hash
1d0f284efe3edea4b9ca3bd514fa134b17eae361ccc7a1eefeff801b9bd6604e01f21f6bf249ef030599f0c218f2ba8c
charm show cs:trusty/wordpress-0 hash
1d0f284efe3edea4b9ca3bd514fa134b17eae361ccc7a1eefeff801b9bd6604e01f21f6bf249ef030599f0c218f2ba8c

rogpeppe avatar Nov 14 '18 11:11 rogpeppe