fix(helm): skip overwriting the lock if it hasn't changed

'helm dep up' will only overwrite the lock file if the digest has
changed (e.g. the source requirements.yaml is different).

Closes #1438
pull/1454/head
Matt Butcher 8 years ago
parent a34472d18e
commit 819ec44215
No known key found for this signature in database
GPG Key ID: DCD5F5E5EF32C345

@ -138,6 +138,12 @@ func (m *Manager) Update() error {
return err
}
// If the lock file hasn't changed, don't write a new one.
oldLock, err := chartutil.LoadRequirementsLock(c)
if err == nil && oldLock.Digest == lock.Digest {
return nil
}
// Finally, we need to write the lockfile.
return writeLock(m.ChartPath, lock)
}

Loading…
Cancel
Save