Changeset 1203 in MondoRescue
- Timestamp:
- Feb 25, 2007, 11:12:55 AM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/stable/mondo/src/mondorestore/mondorestore.c
r1202 r1203 13 13 **************************************************************************/ 14 14 #include <unistd.h> 15 #include <utime.h> 15 16 16 17 #include "my-stuff.h" … … 234 235 popup_and_OK(COMPAQ_PROLIANTS_SUCK); 235 236 if (ask_me_yes_or_no 236 (_ 237 ("Would you like to reboot and use your Compaq CD to prep your hard drive?"))) 237 (_("Would you like to reboot and use your Compaq CD to prep your hard drive?"))) 238 238 { 239 fatal_error(_ 240 ("Aborting. Please reboot and prep your hard drive with your Compaq CD.")); 239 fatal_error(_("Aborting. Please reboot and prep your hard drive with your Compaq CD.")); 241 240 } 242 241 } … … 273 272 interactively_obtain_media_parameters_from_user(bkpinfo, FALSE); 274 273 } else { 275 popup_and_OK(_ 276 ("No restoring or comparing will take place today.")); 274 popup_and_OK(_("No restoring or comparing will take place today.")); 277 275 if (is_this_device_mounted("/mnt/cdrom")) { 278 276 run_program_and_log_output("umount /mnt/cdrom", FALSE); … … 365 363 if (g_text_mode) { 366 364 if (!ask_me_yes_or_no 367 (_ 368 ("Interactive Mode + textonly = experimental! Proceed anyway?"))) 365 (_("Interactive Mode + textonly = experimental! Proceed anyway?"))) 369 366 { 370 367 fatal_error("Wise move."); … … 410 407 mvaddstr_and_log_it(1, 30, _("Restoring Interactively")); 411 408 if (bkpinfo->differential) { 412 log_to_screen(_ 413 ("Because this is a differential backup, disk")); 414 log_to_screen(_ 415 (" partitioning and formatting will not take place.")); 409 log_to_screen(_("Because this is a differential backup, disk")); 410 log_to_screen(_(" partitioning and formatting will not take place.")); 416 411 done = TRUE; 417 412 } else { 418 413 if (ask_me_yes_or_no 419 (_ 420 ("Do you want to erase and partition your hard drives?"))) 414 (_("Do you want to erase and partition your hard drives?"))) 421 415 { 422 416 if (partition_table_contains_Compaq_diagnostic_partition … … 430 424 if (ptn_errs) { 431 425 log_to_screen 432 (_ 433 ("Warning. Errors occurred during disk partitioning.")); 426 (_("Warning. Errors occurred during disk partitioning.")); 434 427 } 435 428 … … 437 430 if (!fmt_errs) { 438 431 log_to_screen 439 (_ 440 ("Errors during disk partitioning were handled OK.")); 441 log_to_screen(_ 442 ("Partitions were formatted OK despite those errors.")); 432 (_("Errors during disk partitioning were handled OK.")); 433 log_to_screen(_("Partitions were formatted OK despite those errors.")); 443 434 ptn_errs = 0; 444 435 } … … 450 441 } else { 451 442 mvaddstr_and_log_it(g_currentY++, 0, 452 _ 453 ("User opted not to partition the devices")); 443 _("User opted not to partition the devices")); 454 444 if (ask_me_yes_or_no 455 445 (_("Do you want to format your hard drives?"))) { … … 467 457 mvaddstr_and_log_it(g_currentY++, 468 458 0, 469 _ 470 ("Errors occurred. Please repartition and format drives manually.")); 459 _("Errors occurred. Please repartition and format drives manually.")); 471 460 done = FALSE; 472 461 } … … 474 463 mvaddstr_and_log_it(g_currentY++, 475 464 0, 476 _ 477 ("Errors occurred during partitioning. Formatting, however, went OK.")); 465 _("Errors occurred during partitioning. Formatting, however, went OK.")); 478 466 done = TRUE; 479 467 } … … 497 485 /* restore */ 498 486 if ((restore_all = 499 ask_me_yes_or_no(_ 500 ("Do you want me to restore all of your data?")))) 487 ask_me_yes_or_no(_("Do you want me to restore all of your data?")))) 501 488 { 502 489 mr_msg(1, "Restoring all data"); … … 547 534 mvaddstr_and_log_it(g_currentY++, 548 535 0, 549 _ 550 ("User opted not to restore any data. ")); 536 _("User opted not to restore any data. ")); 551 537 } 552 538 if (retval) { 553 539 mvaddstr_and_log_it(g_currentY++, 554 540 0, 555 _ 556 ("Errors occurred during the restore phase. ")); 541 _("Errors occurred during the restore phase. ")); 557 542 } 558 543 … … 562 547 mvaddstr_and_log_it(g_currentY++, 563 548 0, 564 _ 565 ("User opted not to initialize the boot loader.")); 549 _("User opted not to initialize the boot loader.")); 566 550 } 567 551 … … 572 556 (_("Label your ext2 and ext3 partitions if necessary?"))) { 573 557 mvaddstr_and_log_it(g_currentY, 0, 574 _ 575 ("Using e2label to label your ext2,3 partitions")); 558 _("Using e2label to label your ext2,3 partitions")); 576 559 if (does_file_exist("/tmp/fstab.new")) { 577 560 mr_asprintf(&fstab_fname, "/tmp/fstab.new"); … … 601 584 mvaddstr_and_log_it(g_currentY++, 602 585 0, 603 _ 604 ("Warning - errors occurred during the restore phase.")); 586 _("Warning - errors occurred during the restore phase.")); 605 587 } 606 588 iamhere("Leaving interactive_mode()"); … … 657 639 if (system("umount /tmp/isodir 2> /dev/null")) { 658 640 log_to_screen 659 (_ 660 ("WARNING - unable to unmount device where the ISO files are stored.")); 641 (_("WARNING - unable to unmount device where the ISO files are stored.")); 661 642 } 662 643 return (retval); … … 684 665 /* -H option */ 685 666 mr_asprintf(&tmp, 686 _ 687 (" Mondo has restored your system. Please remove the backup media and reboot.\n\nPlease visit our website at http://www. 667 _(" Mondo has restored your system. Please remove the backup media and reboot.\n\nPlease visit our website at http://www. 688 668 mondorescue.org for more information.")); 689 669 popup_and_OK(tmp); … … 691 671 } 692 672 693 log_to_screen(_ 694 ("Mondo has restored your system. Please remove the backup media and reboot.")); 695 log_to_screen(_ 696 ("Thank you for using Mondo Rescue.")); 697 log_to_screen(_ 698 ("Please visit our website at http://www.mondorescue.org for more information.")); 673 log_to_screen(_("Mondo has restored your system. Please remove the backup media and reboot.")); 674 log_to_screen(_("Thank you for using Mondo Rescue.")); 675 log_to_screen(_("Please visit our website at http://www.mondorescue.org for more information.")); 699 676 } 700 677 g_I_have_just_nuked = TRUE; … … 744 721 if (!evaluate_mountlist(mountlist, tmpA, tmpB, tmpC)) { 745 722 mr_asprintf(&tmp, 746 _ 747 ("Mountlist analyzed. Result: \"%s %s %s\" Switch to Interactive Mode?"), 723 _("Mountlist analyzed. Result: \"%s %s %s\" Switch to Interactive Mode?"), 748 724 tmpA, tmpB, tmpC); 749 725 if (ask_me_yes_or_no(tmp)) { … … 761 737 if (bkpinfo->differential) { 762 738 log_to_screen(_("Because this is a differential backup, disk")); 763 log_to_screen(_ 764 ("partitioning and formatting will not take place.")); 739 log_to_screen(_("partitioning and formatting will not take place.")); 765 740 res = 0; 766 741 } else { … … 784 759 if (res) { 785 760 log_to_screen 786 (_ 787 ("Warning. Errors occurred during partitioning.")); 761 (_("Warning. Errors occurred during partitioning.")); 788 762 res = 0; 789 763 } … … 794 768 sleep(1); 795 769 sync(); 796 log_to_screen(_ 797 ("Please wait. This may take a few minutes.")); 770 log_to_screen(_("Please wait. This may take a few minutes.")); 798 771 res += format_everything(mountlist, FALSE, raidlist); 799 772 } … … 805 778 mvaddstr_and_log_it(g_currentY++, 806 779 0, 807 _ 808 ("Failed to partition and/or format your hard drives.")); 780 _("Failed to partition and/or format your hard drives.")); 809 781 810 782 if (ask_me_yes_or_no(_("Try in interactive mode instead?"))) { … … 822 794 unmount_all_devices(mountlist); 823 795 log_to_screen 824 (_ 825 ("Unable to mount all partitions. Sorry, I cannot proceed.")); 796 (_("Unable to mount all partitions. Sorry, I cannot proceed.")); 826 797 return (retval); 827 798 } … … 837 808 mvaddstr_and_log_it(g_currentY, 838 809 0, 839 _ 840 ("Using e2label to label your ext2,3 partitions")); 810 _("Using e2label to label your ext2,3 partitions")); 841 811 842 812 mr_asprintf(&tmp, "label-partitions-as-necessary %s < /tmp/fstab", … … 846 816 847 817 if (res) { 848 log_to_screen(_ 849 ("label-partitions-as-necessary returned an error")); 818 log_to_screen(_("label-partitions-as-necessary returned an error")); 850 819 mvaddstr_and_log_it(g_currentY++, 74, _("Failed.")); 851 820 } else { … … 888 857 if (!g_restoring_live_from_cd) { 889 858 popup_and_OK 890 (_ 891 ("Please insert tape/CD/boot floppy, then hit 'OK' to continue.")); 859 (_("Please insert tape/CD/boot floppy, then hit 'OK' to continue.")); 892 860 sleep(1); 893 861 } … … 945 913 946 914 947 #include <utime.h>948 915 /** 949 916 * @addtogroup LLrestoreGroup … … 1600 1567 if (run_program_and_log_output(tmp, FALSE)) { 1601 1568 log_to_screen 1602 (_ 1603 ("(compare_a_tarball) Compression program not found - oh no!")); 1569 (_("(compare_a_tarball) Compression program not found - oh no!")); 1604 1570 mr_free(tmp); 1605 1571 mr_free(executable); … … 1706 1672 if (does_file_exist("/PAUSE")) { 1707 1673 popup_and_OK 1708 (_ 1709 ("Press ENTER to go on. Delete /PAUSE to stop these pauses.")); 1674 (_("Press ENTER to go on. Delete /PAUSE to stop these pauses.")); 1710 1675 } 1711 1676 unlink(filelist_subset_fname); … … 2030 1995 if (does_file_exist("/PAUSE")) { 2031 1996 popup_and_OK 2032 (_ 2033 ("Press ENTER to go on. Delete /PAUSE to stop these pauses.")); 1997 (_("Press ENTER to go on. Delete /PAUSE to stop these pauses.")); 2034 1998 } 2035 1999 close_progress_form(); … … 2135 2099 if (current_tarball_number == 0) { 2136 2100 log_to_screen 2137 (_ 2138 ("No tarballs. Strange. Maybe you only backed up freakin' big files?")); 2101 (_("No tarballs. Strange. Maybe you only backed up freakin' big files?")); 2139 2102 mr_free(progress_str); 2140 2103 return (0); … … 2361 2324 if (does_file_exist("/PAUSE")) { 2362 2325 popup_and_OK 2363 (_ 2364 ("Press ENTER to go on. Delete /PAUSE to stop these pauses.")); 2326 (_("Press ENTER to go on. Delete /PAUSE to stop these pauses.")); 2365 2327 } 2366 2328 … … 2561 2523 if (!find_home_of_exe("petris") && !g_text_mode) { 2562 2524 newtDrawRootText(0, g_noof_rows - 2, 2563 _ 2564 ("Press ALT-<left cursor> twice to play Petris :-) ")); 2525 _("Press ALT-<left cursor> twice to play Petris :-) ")); 2565 2526 newtRefresh(); 2566 2527 } … … 2569 2530 mount_cdrom(bkpinfo); 2570 2531 mvaddstr_and_log_it(g_currentY++, 0, 2571 _ 2572 ("Restoring OS and data from streaming media")); 2532 _("Restoring OS and data from streaming media")); 2573 2533 if (bkpinfo->backup_media_type == cdstream) { 2574 2534 openin_cdstream(bkpinfo); … … 3026 2986 if (argc != 1) { 3027 2987 popup_and_OK 3028 (_ 3029 ("Live mode doesn't support command-line parameters yet.")); 2988 (_("Live mode doesn't support command-line parameters yet.")); 3030 2989 paranoid_MR_finish(1); 3031 2990 } … … 3089 3048 if (retval) { 3090 3049 log_to_screen 3091 (_ 3092 ("Warning - load_raidtab_into_raidlist returned an error")); 3050 (_("Warning - load_raidtab_into_raidlist returned an error")); 3093 3051 } 3094 3052 … … 3162 3120 if (does_file_exist("/tmp/changed.files")) { 3163 3121 log_to_screen 3164 (_ 3165 ("See /tmp/changed.files for list of files that have changed.")); 3122 (_("See /tmp/changed.files for list of files that have changed.")); 3166 3123 } 3167 3124 mvaddstr_and_log_it(g_currentY++, 3168 3125 0, 3169 _ 3170 ("Run complete. Errors were reported. Please review the logfile.")); 3126 _("Run complete. Errors were reported. Please review the logfile.")); 3171 3127 } else { 3172 3128 if (IS_THIS_A_STREAMING_BACKUP(bkpinfo->backup_media_type)) { 3173 3129 mvaddstr_and_log_it(g_currentY++, 3174 3130 0, 3175 _ 3176 ("Run complete. Please remove floppy/CD/media and reboot.")); 3131 _("Run complete. Please remove floppy/CD/media and reboot.")); 3177 3132 } else { 3178 3133 run_program_and_log_output("sync", FALSE); … … 3189 3144 mvaddstr_and_log_it(g_currentY++, 3190 3145 0, 3191 _ 3192 ("Run complete. Please remove media and reboot.")); 3146 _("Run complete. Please remove media and reboot.")); 3193 3147 } 3194 3148 } … … 3237 3191 3238 3192 log_to_screen 3239 (_ 3240 ("Restore log copied to /tmp/mondo-restore.log on your hard disk")); 3193 (_("Restore log copied to /tmp/mondo-restore.log on your hard disk")); 3241 3194 log_to_screen(_("Mondo-restore is exiting (retval=%d)"), retval); 3242 3195
Note:
See TracChangeset
for help on using the changeset viewer.