Skip to content

Commit 263cacb

Browse files
committed
Removed Directories from Fileserver, Changed Logofile
1 parent 9deb205 commit 263cacb

File tree

3 files changed

+16
-6
lines changed

3 files changed

+16
-6
lines changed

README.md

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# ConsoleTools
22
###### by Command Jo
3-
<br><br>
3+
44
ConsoleTools is a CLI that has a collection of useful tools
55
for various things in the console.
66

@@ -10,8 +10,14 @@ TO BE ADDED
1010

1111
# Functionality
1212
1. Launch the app
13-
2. It will tell you that ```to get started type "?"```
14-
3. This will show you all the information you need to work
13+
```bash
14+
java -jar ConsoleTools.jar
15+
```
16+
2. It will then tell you that
17+
```text
18+
to get started type "?"
19+
```
20+
3. Doing this will show you the Helpscreen
1521

1622

1723
# Modules

src/main/java/de/jo/web/FileServer.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,9 @@ public void addFile(File file) {
5656
* @param file The parameter "file" is of type File and represents the directory that you want to add to the server.
5757
*/
5858
public void addDirectory(File file) {
59-
this.files.addAll(Arrays.asList(Objects.requireNonNull(file.listFiles())));
59+
for(File subfile : Objects.requireNonNull(file.listFiles())) {
60+
if(!subfile.isDirectory()) this.files.add(subfile);
61+
}
6062
System.out.println(ConsoleColors.YELLOW_BRIGHT+"---------------------------------");
6163
System.out.println(ConsoleColors.YELLOW+"> "+ConsoleColors.YELLOW_BRIGHT+"Added Directory to Server: "+file.getName());
6264
System.out.println(ConsoleColors.YELLOW_BRIGHT+"---------------------------------");

src/main/resources/logo.txt

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,10 @@
1212
| \ \_______\ \ \__\ \ \_______\ \ \_______\ \ \_______\ |\_________\ |
1313
| \|________| \|__| \|_______| \|_______| \|_______| \|_________| |
1414
| |
15-
| |
16-
| to get started type "?" |
15+
| ConsoleTools by Johannes Hans @CommandJoo |
16+
| Version 1.0.5 |
17+
| https://github.com/CommandJoo/ConsoleTools |
18+
| to get started type "?" |
1719
| |
1820
| |
1921
|---------------------------------------------------------------------------------------------------------------------|

0 commit comments

Comments
 (0)