added and implemented --edit