Lines Matching refs:to_dir
79 std::string to_dir; member
92 string_repr << "\t.to_dir = " << to_dir << ",\n"; in to_string()
102 from_dir = to_dir = "./"; in reset()
133 << "/" << Command::HARDLINK << " (default '" << command.to_dir << "').\n"; in usage()
194 bool move_files(const std::string& from_dir, const std::string& to_dir, int n_file, in move_files() argument
203 int to_dir_fd = open(to_dir.c_str(), OPEN_DIR_FLAGS); in move_files()
206 std::cerr << "Failed to open destination directory '" << to_dir << "', error '" in move_files()
226 bool hardlink_files(const std::string& from_dir, const std::string& to_dir, int n_file, in hardlink_files() argument
235 int to_dir_fd = open(to_dir.c_str(), OPEN_DIR_FLAGS); in hardlink_files()
238 std::cerr << "Failed to open destination directory '" << to_dir << "', error '" in hardlink_files()
258 bool symlink_files(std::string from_dir, const std::string& to_dir, int n_file, in symlink_files() argument
261 int to_dir_fd = open(to_dir.c_str(), OPEN_DIR_FLAGS); in symlink_files()
264 std::cerr << "Failed to open destination directory '" << to_dir << "', error '" in symlink_files()
325 if (move_files(command.from_dir, command.to_dir, command.n_file, command.from_basename, in move_workload()
329 delete_files(command.to_dir, command.n_file, command.to_basename); in move_workload()
337 if (hardlink_files(command.from_dir, command.to_dir, command.n_file, command.from_basename, in hardlink_workload()
342 delete_files(command.to_dir, command.n_file, command.to_basename); in hardlink_workload()
350 if (symlink_files(command.from_dir, command.to_dir, command.n_file, command.from_basename, in symlink_workload()
354 delete_files(command.to_dir, command.n_file, command.to_basename); in symlink_workload()
404 command.to_dir = optarg; in main()