Пример #1
0
        private static bool VerifyFtpOptions(FtpOptions options)
        {
            if (string.IsNullOrEmpty(options.SrcFile) || !File.Exists(options.SrcFile))
            {
                Console.WriteLine($"{options.SrcFile} is not found.");
                return(false);
            }

            if (!string.IsNullOrEmpty(options.UserName) && string.IsNullOrEmpty(options.Password))
            {
                Console.Write("Password: ");
                options.Password = PasswordInput.GetPassword();
                Console.WriteLine();
            }

            return(true);
        }