Complete update function. Add spec file.