Browse Source

Add entries when importing, instead of remplacing

 + Entries from old rc file are prepended to entries in the new one. It’s a
 better behavior than remplacing with new entries, which was done before.
Leo 8 years ago
parent
commit
0e5b0d4c34
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/rc.ml

+ 1 - 1
src/rc.ml

@@ -312,7 +312,7 @@ let import ~from ~to_file =
   let imported_rc : t = init ~rc:to_file () in
   let to_import : File_com.t = File_com.init_rc ~rc:from () in
   to_import.progs |> List.map ~f:(fun command -> new entry command)
-  |> imported_rc#change_entries
+  |> imported_rc#add_entries
   |> fun rc -> rc#write;
   Messages.ok "Import successful!";
   sprintf "from: %s; to: %s" (Lazy.force from) (Lazy.force to_file)