create function to copy environment struct