diff --git a/.idea/misc.xml b/.idea/misc.xml index cf9abe6..b95853c 100644 --- a/.idea/misc.xml +++ b/.idea/misc.xml @@ -1,4 +1,3 @@ - diff --git a/src/HiddenSecrets.java b/src/HiddenSecrets.java index 71067b3..285d6a0 100644 --- a/src/HiddenSecrets.java +++ b/src/HiddenSecrets.java @@ -7,6 +7,9 @@ import java.io.FileInputStream; import java.io.FileNotFoundException; import java.io.IOException; +import java.nio.file.Path; +import java.nio.file.Paths; +import java.util.Scanner; // PUT YOUR IMPORTS HERE @@ -37,9 +40,13 @@ public static void getHiddenSecrets(File file) { } public static void main(String[] args) { - // Put your code to request a file path, - // read in a string from System.in, + Scanner scanner = new Scanner(System.in); + System.out.println("hey please input at file path"); + String file = scanner.nextLine(); + // read in a string from Syst // convert that string into A Path type using Paths class, + Path path = Paths.get(file); + getHiddenSecrets(path.toFile()); // and call the getHiddenSecrets method to get the file's meta-data // HERE }