You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In interacting with Opam switches, I quite often find myself wanting to switch to a particular switch in order to perform a specific thing, then switch back to the switch I was on before:
$ opam switch plugin-host
$ ... # rebuild an opam plugin
$ opam switch irmin+4.10 # resume normal operation
The Git CLI has an idiom for this w.r.t branches, allowing git switch -:
$ git switch plugin-host
$ ...
$ git switch - # go back to branch before `plugin-host`
(In fact, Git has a more general @{-N} syntax for referencing historic branch states, and - is a synonym of @{-1}.)
It might be nice if the opam CLI could support a similar syntax, although this would likely be a breaking change as it's currently possible to name an Opam switch "-".
The text was updated successfully, but these errors were encountered:
In interacting with Opam switches, I quite often find myself wanting to switch to a particular switch in order to perform a specific thing, then switch back to the switch I was on before:
The Git CLI has an idiom for this w.r.t branches, allowing
git switch -
:$ git switch plugin-host $ ... $ git switch - # go back to branch before `plugin-host`
(In fact, Git has a more general
@{-N}
syntax for referencing historic branch states, and-
is a synonym of@{-1}
.)It might be nice if the
opam
CLI could support a similar syntax, although this would likely be a breaking change as it's currently possible to name an Opam switch "-
".The text was updated successfully, but these errors were encountered: