Reads a template file (default: .env.template) and merges it with an existing .env file (default: .env), then writes the result.