Skip to main content

move_keys

Function move_keys 

Source
pub fn move_keys(
    scope: &Scope,
    direction: Direction,
    git: &GitFn<'_>,
) -> Result<usize, MigrateError>
Expand description

Move the amont.* keys of scope to greengate.* (or back); how many keys moved. Each value the old key holds is added to the new one unless already there (a migration interrupted between two --adds resumes without losing one), and the old key goes only once every value is present. A new key that holds a value of its own was set by the person: the new name wins, and the old values are dropped. amont.agent.* is greenbelay’s, never moved. A cluster.namespace of amont-gates is dropped on the way forward: 4.0’s default namespace is greengate-gates.