<div dir="ltr">I found the following command works:<div><br></div><div>snap revert --revision 29</div><div><br></div><div>as expected.</div><div><br></div><div>We still need a command to list all revision of a snap install in the system (we can get that from 'df', but still better to get all info from a command) ?</div><div><br></div><div>YC</div></div><div class="gmail_extra"><br><div class="gmail_quote">2016-10-27 14:38 GMT+08:00 Didier Roche <span dir="ltr"><<a href="mailto:didrocks@ubuntu.com" target="_blank">didrocks@ubuntu.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000"><span class="">
<div class="m_8209758444123188224moz-cite-prefix">Le 27/10/2016 à 08:32, YC Cheng a
écrit :<br>
</div>
<blockquote type="cite">
<div dir="ltr">I think we need a way to just Un-revert from rev 20
to rev 29 without remove rev 29.
<div><br>
</div>
<div>Shall we fire a bug for that if we don't have such method
exists now ?<br>
</div>
</div>
</blockquote>
<br></span>
I think it's not that easy considering the associated data. You need
to swap them to restart from the latest version of data from rev 20
to copy to 29. Explicitely removing that version makes sense in that
context. Have an unrevert command won't convey that notion.<span class="HOEnZb"><font color="#888888"><br>
<br>
Didier</font></span><div><div class="h5"><br>
<blockquote type="cite">
<div dir="ltr">
<div>
<div><br>
</div>
</div>
</div>
<div class="gmail_extra"><br>
<div class="gmail_quote">2016-10-27 14:13 GMT+08:00 Didier Roche
<span dir="ltr"><<a href="mailto:didrocks@ubuntu.com" target="_blank">didrocks@ubuntu.com</a>></span>:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Le
27/10/2016 à 03:01, Marcos Alano a écrit :<br>
> Hello guys,<br>
<br>
Hey Marcos,<br>
<span>><br>
><br>
> Sorry if I'm in the wrong mailing list. That's the
only one about snap i<br>
> could found. The question is: how I revert-revert
(un-revert) a snap? I<br>
> can install a snap:<br>
><br>
> (sudo snap install hello) after thatr I can upgrade a
snap (snap refresh<br>
> hello --channel=beta hello) and finally revert (sudo
snap revert hello).<br>
> But after that if I try to re-upgrade I just can't:<br>
><br>
> $ sudo snap refresh --beta hello<br>
><br>
> error: cannot refresh "hello": snap "hello" has no
updates available<br>
><br>
> I'm doing something wrong?<br>
<br>
</span>You are not doing it wrong :) The revert command
"blacklists" this<br>
particular snap revisions on purpose, so that you don't
reupdate to it.<br>
However, there is a way to get back to it! You can remove
explicitely<br>
that revision (without removing the current snap). Data
associated to<br>
the reverted revision will be cleaned up as well.<br>
Then, you can refresh.<br>
<br>
In a concrete example with the hello snap:<br>
20 is the revision in the stable channel, 29 corresponds to
the revision<br>
in the beta channel.<br>
<br>
# Install and update<br>
$ snap install hello<br>
$ snap list hello<br>
Name Version Rev Developer Notes<br>
hello 2.10 20 canonical -<br>
$ snap refresh hello --beta<br>
$ snap list hello<br>
Name Version Rev Developer Notes<br>
hello 2.10.1 29 canonical -<br>
<br>
# Revert<br>
$ snap revert hello<br>
$ snap list hello<br>
Name Version Rev Developer Notes<br>
hello 2.10 20 canonical -<br>
<br>
# Remove reverted version (and associated data)<br>
$ snap remove hello --revision=29<br>
hello removed<br>
$ snap list hello<br>
Name Version Rev Developer Notes<br>
hello 2.10 20 canonical -<br>
<br>
# Reupdate<br>
$ snap refresh hello --beta<br>
$ snap list hello<br>
Name Version Rev Developer Notes<br>
hello 2.10.1 29 canonical -<br>
<br>
I hope that answer your questions :)<br>
Cheers,<br>
Didier<br>
<div class="m_8209758444123188224HOEnZb">
<div class="m_8209758444123188224h5"><br>
<br>
--<br>
Snapcraft mailing list<br>
<a href="mailto:Snapcraft@lists.snapcraft.io" target="_blank">Snapcraft@lists.snapcraft.io</a><br>
Modify settings or unsubscribe at: <a href="https://lists.ubuntu.com/mailman/listinfo/snapcraft" rel="noreferrer" target="_blank">https://lists.ubuntu.com/mailm<wbr>an/listinfo/snapcraft</a><br>
</div>
</div>
</blockquote>
</div>
<br>
</div>
<br>
<fieldset class="m_8209758444123188224mimeAttachmentHeader"></fieldset>
<br>
</blockquote>
<p><br>
</p>
</div></div></div>
<br>--<br>
Snapcraft mailing list<br>
<a href="mailto:Snapcraft@lists.snapcraft.io">Snapcraft@lists.snapcraft.io</a><br>
Modify settings or unsubscribe at: <a href="https://lists.ubuntu.com/mailman/listinfo/snapcraft" rel="noreferrer" target="_blank">https://lists.ubuntu.com/<wbr>mailman/listinfo/snapcraft</a><br>
<br></blockquote></div><br></div>