Added more \n
This commit is contained in:
parent
6d53d93d3e
commit
ab90ca1934
1 changed files with 11 additions and 11 deletions
|
|
@ -72,18 +72,18 @@ def main():
|
||||||
|
|
||||||
# Test Folder availability
|
# Test Folder availability
|
||||||
if not os.path.exists(inpath):
|
if not os.path.exists(inpath):
|
||||||
print(f"ERROR: The input folder ({inpath}) is unavailable or non-existant.")
|
print(f"\nERROR: The input folder ({inpath}) is unavailable or non-existant.")
|
||||||
if not args.quiet:
|
if not args.quiet:
|
||||||
input("\nPress ENTER to exit...")
|
input("\nPress ENTER to exit...")
|
||||||
exit(1)
|
exit(1)
|
||||||
|
|
||||||
if not os.path.exists(outpath):
|
if not os.path.exists(outpath):
|
||||||
print(f"ERROR: The output folder ({outpath}] is unavailable or non-existant.")
|
print(f"\nERROR: The output folder ({outpath}] is unavailable or non-existant.")
|
||||||
if not args.quiet:
|
if not args.quiet:
|
||||||
input("\nPress ENTER to exit...")
|
input("\nPress ENTER to exit...")
|
||||||
exit(1)
|
exit(1)
|
||||||
|
|
||||||
print("Analyzing files. Please wait...\n")
|
print("\nAnalyzing files. Please wait...\n")
|
||||||
|
|
||||||
source = get_files(inpath)
|
source = get_files(inpath)
|
||||||
target = get_files(outpath)
|
target = get_files(outpath)
|
||||||
|
|
@ -110,13 +110,13 @@ def main():
|
||||||
|
|
||||||
if not new and not changed and not deleted:
|
if not new and not changed and not deleted:
|
||||||
if not args.quiet:
|
if not args.quiet:
|
||||||
print("No changes found.")
|
print("\nNo changes found.")
|
||||||
input("\nPress ENTER to exit...")
|
input("\nPress ENTER to exit...")
|
||||||
exit(0)
|
exit(0)
|
||||||
|
|
||||||
# Print overview
|
# Print overview
|
||||||
if not args.quiet:
|
if not args.quiet:
|
||||||
print("Found the following changes:")
|
print("\nFound the following changes:")
|
||||||
if new:
|
if new:
|
||||||
print("\nAdded:")
|
print("\nAdded:")
|
||||||
for i in new:
|
for i in new:
|
||||||
|
|
@ -137,11 +137,11 @@ def main():
|
||||||
copy_confirm = "y"
|
copy_confirm = "y"
|
||||||
else:
|
else:
|
||||||
copy_confirm = (
|
copy_confirm = (
|
||||||
input("Write new and changed files? (y/N): ").strip().lower()
|
input("\nWrite new and changed files? (y/N): ").strip().lower()
|
||||||
)
|
)
|
||||||
if copy_confirm in ["ja", "j", "yes", "y"]:
|
if copy_confirm in ["ja", "j", "yes", "y"]:
|
||||||
if not args.quiet:
|
if not args.quiet:
|
||||||
print("\nCopying files...")
|
print("\nCopying files...\n")
|
||||||
for path in new + changed:
|
for path in new + changed:
|
||||||
source_path = os.path.join(inpath, path)
|
source_path = os.path.join(inpath, path)
|
||||||
target_path = os.path.join(outpath, path)
|
target_path = os.path.join(outpath, path)
|
||||||
|
|
@ -165,23 +165,23 @@ def main():
|
||||||
]:
|
]:
|
||||||
exit(1)
|
exit(1)
|
||||||
elif not args.quiet:
|
elif not args.quiet:
|
||||||
print("\nSkipping changes...")
|
print("\nSkipping changes...\n")
|
||||||
|
|
||||||
# Delete files
|
# Delete files
|
||||||
if not args.dry_run:
|
if not args.dry_run:
|
||||||
if deleted:
|
if deleted:
|
||||||
alert = " ALERT: Some files only exist at the destination. "
|
alert = " ALERT: Some files only exist at the destination. "
|
||||||
if not args.quiet:
|
if not args.quiet:
|
||||||
print(f"{len(alert) * '*'}\n{alert}\n{len(alert) * '*'}")
|
print(f"\n{len(alert) * '*'}\n{alert}\n{len(alert) * '*'}")
|
||||||
if args.delete:
|
if args.delete:
|
||||||
delete_confirm = "y"
|
delete_confirm = "y"
|
||||||
else:
|
else:
|
||||||
delete_confirm = (
|
delete_confirm = (
|
||||||
input("Delete files on the target? (y/N): ").strip().lower()
|
input("\nDelete files on the target? (y/N): ").strip().lower()
|
||||||
)
|
)
|
||||||
if delete_confirm in ["ja", "j", "yes", "y"]:
|
if delete_confirm in ["ja", "j", "yes", "y"]:
|
||||||
if not args.quiet:
|
if not args.quiet:
|
||||||
print("\nDeleting files...")
|
print("\nDeleting files...\n")
|
||||||
for path in deleted:
|
for path in deleted:
|
||||||
target_path = os.path.join(outpath, path)
|
target_path = os.path.join(outpath, path)
|
||||||
try:
|
try:
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue