⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 tar.c

📁 gnu tar 源码包。 tar 软件是 Unix 系统下的一个打包软件
💻 C
📖 第 1 页 / 共 5 页
字号:
      if (NEWER_OPTION_INITIALIZED (newer_mtime_option))	USAGE_ERROR ((0, 0, _("More than one threshold date")));      get_date_or_file (args,			key == NEWER_MTIME_OPTION ? "--newer-mtime"			  : "--after-date", arg, &newer_mtime_option);      break;    case 'o':      args->o_option = true;      break;    case 'O':      to_stdout_option = true;      break;    case 'p':      same_permissions_option = true;      break;    case 'P':      absolute_names_option = true;      break;    case 'r':      set_subcommand_option (APPEND_SUBCOMMAND);      break;    case 'R':      /* Print block numbers for debugging bad tar archives.  */      /* It would surely make sense to exchange -B and -R, but it seems	 that -B has been used for a long while in Sun tar and most	 BSD-derived systems.  This is a consequence of the block/record	 terminology confusion.  */      block_number_option = true;      break;    case 's':      /* Names to extract are sorted.  */      same_order_option = true;      break;    case 'S':      sparse_option = true;      break;    case SPARSE_VERSION_OPTION:      sparse_option = true;      {	char *p;	tar_sparse_major = strtoul (arg, &p, 10);	if (*p)	  {	    if (*p != '.')	      USAGE_ERROR ((0, 0, _("Invalid sparse version value")));	    tar_sparse_minor = strtoul (p + 1, &p, 10);	    if (*p)	      USAGE_ERROR ((0, 0, _("Invalid sparse version value")));	  }      }      break;    case 't':      set_subcommand_option (LIST_SUBCOMMAND);      verbose_option++;      break;    case TEST_LABEL_OPTION:      set_subcommand_option (LIST_SUBCOMMAND);      test_label_option = true;      break;    case 'T':      update_argv (arg, state);      /* Indicate we've been given -T option. This is for backward	 compatibility only, so that `tar cfT archive /dev/null will	 succeed */      files_from_option = true;      break;    case 'u':      set_subcommand_option (UPDATE_SUBCOMMAND);      break;    case 'U':      old_files_option = UNLINK_FIRST_OLD_FILES;      break;    case UTC_OPTION:      utc_option = true;      break;    case 'v':      verbose_option++;      break;    case 'V':      volume_label_option = arg;      break;    case 'w':      interactive_option = true;      break;    case 'W':      verify_option = true;      break;    case 'x':      set_subcommand_option (EXTRACT_SUBCOMMAND);      break;    case 'X':      if (add_exclude_file (add_exclude, excluded, arg,			    MAKE_EXCL_OPTIONS (args), '\n')	  != 0)	{	  int e = errno;	  FATAL_ERROR ((0, e, "%s", quotearg_colon (arg)));	}      break;    case 'z':      set_use_compress_program_option ("gzip");      break;    case 'Z':      set_use_compress_program_option ("compress");      break;    case ANCHORED_OPTION:      args->matching_flags |= EXCLUDE_ANCHORED;      break;    case ATIME_PRESERVE_OPTION:      atime_preserve_option =	(arg	 ? XARGMATCH ("--atime-preserve", arg,		      atime_preserve_args, atime_preserve_types)	 : replace_atime_preserve);      if (! O_NOATIME && atime_preserve_option == system_atime_preserve)	FATAL_ERROR ((0, 0,		      _("--atime-preserve='system' is not supported"			" on this platform")));      break;    case CHECK_DEVICE_OPTION:      check_device_option = true;      break;          case NO_CHECK_DEVICE_OPTION:      check_device_option = false;      break;          case CHECKPOINT_OPTION:      if (arg)	{	  char *p;	  if (*arg == '.')	    {	      checkpoint_compile_action (".");	      arg++;	    }	  checkpoint_option = strtoul (arg, &p, 0);	  if (*p)	    FATAL_ERROR ((0, 0,			  _("--checkpoint value is not an integer")));	}      else	checkpoint_option = DEFAULT_CHECKPOINT;      break;    case CHECKPOINT_ACTION_OPTION:      checkpoint_compile_action (arg);      break;          case BACKUP_OPTION:      backup_option = true;      if (arg)	args->version_control_string = arg;      break;    case DELAY_DIRECTORY_RESTORE_OPTION:      delay_directory_restore_option = true;      break;    case NO_DELAY_DIRECTORY_RESTORE_OPTION:      delay_directory_restore_option = false;      break;    case DELETE_OPTION:      set_subcommand_option (DELETE_SUBCOMMAND);      break;    case EXCLUDE_OPTION:      add_exclude (excluded, arg, MAKE_EXCL_OPTIONS (args));      break;    case EXCLUDE_CACHES_OPTION:      add_exclusion_tag ("CACHEDIR.TAG", exclusion_tag_contents,			 cachedir_file_p);      break;    case EXCLUDE_CACHES_UNDER_OPTION:      add_exclusion_tag ("CACHEDIR.TAG", exclusion_tag_under,			 cachedir_file_p);      break;    case EXCLUDE_CACHES_ALL_OPTION:      add_exclusion_tag ("CACHEDIR.TAG", exclusion_tag_all,			 cachedir_file_p);      break;    case EXCLUDE_TAG_OPTION:      add_exclusion_tag (arg, exclusion_tag_contents, NULL);      break;    case EXCLUDE_TAG_UNDER_OPTION:      add_exclusion_tag (arg, exclusion_tag_under, NULL);      break;    case EXCLUDE_TAG_ALL_OPTION:      add_exclusion_tag (arg, exclusion_tag_all, NULL);      break;    case EXCLUDE_VCS_OPTION:      exclude_vcs_files ();      break;          case FORCE_LOCAL_OPTION:      force_local_option = true;      break;    case 'H':      set_archive_format (arg);      break;    case INDEX_FILE_OPTION:      index_file_name = arg;      break;    case IGNORE_CASE_OPTION:      args->matching_flags |= FNM_CASEFOLD;      break;    case IGNORE_COMMAND_ERROR_OPTION:      ignore_command_error_option = true;      break;    case IGNORE_FAILED_READ_OPTION:      ignore_failed_read_option = true;      break;    case KEEP_NEWER_FILES_OPTION:      old_files_option = KEEP_NEWER_FILES;      break;    case GROUP_OPTION:      if (! (strlen (arg) < GNAME_FIELD_SIZE	     && gname_to_gid (arg, &group_option)))	{	  uintmax_t g;	  if (xstrtoumax (arg, 0, 10, &g, "") == LONGINT_OK	      && g == (gid_t) g)	    group_option = g;	  else	    FATAL_ERROR ((0, 0, "%s: %s", quotearg_colon (arg),			  _("%s: Invalid group")));	}      break;    case MODE_OPTION:      mode_option = mode_compile (arg);      if (!mode_option)	FATAL_ERROR ((0, 0, _("Invalid mode given on option")));      initial_umask = umask (0);      umask (initial_umask);      break;    case NO_ANCHORED_OPTION:      args->include_anchored = 0; /* Clear the default for comman line args */      args->matching_flags &= ~ EXCLUDE_ANCHORED;      break;    case NO_IGNORE_CASE_OPTION:      args->matching_flags &= ~ FNM_CASEFOLD;      break;    case NO_IGNORE_COMMAND_ERROR_OPTION:      ignore_command_error_option = false;      break;    case NO_OVERWRITE_DIR_OPTION:      old_files_option = NO_OVERWRITE_DIR_OLD_FILES;      break;    case NO_QUOTE_CHARS_OPTION:      for (;*arg; arg++)	set_char_quoting (NULL, *arg, 0);      break;    case NO_WILDCARDS_OPTION:      args->wildcards = disable_wildcards;      break;    case NO_WILDCARDS_MATCH_SLASH_OPTION:      args->matching_flags |= FNM_FILE_NAME;      break;    case NULL_OPTION:      filename_terminator = '\0';      break;    case NUMERIC_OWNER_OPTION:      numeric_owner_option = true;      break;    case OCCURRENCE_OPTION:      if (!arg)	occurrence_option = 1;      else	{	  uintmax_t u;	  if (xstrtoumax (arg, 0, 10, &u, "") == LONGINT_OK)	    occurrence_option = u;	  else	    FATAL_ERROR ((0, 0, "%s: %s", quotearg_colon (arg),			  _("Invalid number")));	}      break;    case OVERWRITE_DIR_OPTION:      old_files_option = DEFAULT_OLD_FILES;      break;    case OVERWRITE_OPTION:      old_files_option = OVERWRITE_OLD_FILES;      break;    case OWNER_OPTION:      if (! (strlen (arg) < UNAME_FIELD_SIZE	     && uname_to_uid (arg, &owner_option)))	{	  uintmax_t u;	  if (xstrtoumax (arg, 0, 10, &u, "") == LONGINT_OK	      && u == (uid_t) u)	    owner_option = u;	  else	    FATAL_ERROR ((0, 0, "%s: %s", quotearg_colon (arg),			  _("Invalid owner")));	}      break;    case QUOTE_CHARS_OPTION:      for (;*arg; arg++)	set_char_quoting (NULL, *arg, 1);      break;    case QUOTING_STYLE_OPTION:      tar_set_quoting_style (arg);      break;    case PAX_OPTION:      args->pax_option = true;      xheader_set_option (arg);      break;    case POSIX_OPTION:      set_archive_format ("posix");      break;    case PRESERVE_OPTION:      /* FIXME: What it is good for? */      same_permissions_option = true;      same_order_option = true;      break;    case RECORD_SIZE_OPTION:      {	uintmax_t u;	if (! (xstrtoumax (arg, 0, 10, &u, "") == LONGINT_OK	       && u == (size_t) u))	  USAGE_ERROR ((0, 0, "%s: %s", quotearg_colon (arg),			_("Invalid record size")));	record_size = u;	if (record_size % BLOCKSIZE != 0)	  USAGE_ERROR ((0, 0, _("Record size must be a multiple of %d."),			BLOCKSIZE));	blocking_factor = record_size / BLOCKSIZE;      }      break;    case RECURSIVE_UNLINK_OPTION:      recursive_unlink_option = true;      break;    case REMOVE_FILES_OPTION:      remove_files_option = true;      break;    case RESTRICT_OPTION:      restrict_option = true;      break;    case RMT_COMMAND_OPTION:      rmt_command = arg;      break;    case RSH_COMMAND_OPTION:      rsh_command_option = arg;      break;    case SHOW_DEFAULTS_OPTION:      show_default_settings (stdout);      close_stdout ();      exit (0);    case STRIP_COMPONENTS_OPTION:      {	uintmax_t u;	if (! (xstrtoumax (arg, 0, 10, &u, "") == LONGINT_OK	       && u == (size_t) u))	  USAGE_ERROR ((0, 0, "%s: %s", quotearg_colon (arg),			_("Invalid number of elements")));	strip_name_components = u;      }      break;    case SHOW_OMITTED_DIRS_OPTION:      show_omitted_dirs_option = true;      break;    case SHOW_TRANSFORMED_NAMES_OPTION:      show_transformed_names_option = true;      break;    case SUFFIX_OPTION:      backup_option = true;      args->backup_suffix_string = arg;      break;    case TO_COMMAND_OPTION:      if (to_command_option)        USAGE_ERROR ((0, 0, _("Only one --to-command option allowed")));      to_command_option = arg;      break;    case TOTALS_OPTION:      if (arg)	set_stat_signal (arg);      else	totals_option = true;      break;    case TRANSFORM_OPTION:      set_transform_expr (arg);      break;    case USE_COMPRESS_PROGRAM_OPTION:      set_use_compress_program_option (arg);      break;    case VOLNO_FILE_OPTION:      volno_file_option = arg;      break;

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -