Skip to content

Commit 40b1b12

Browse files
jorsolslachiewicz
authored andcommitted
Update plexus-container-default to 2.1.1, commons-io 2.11.0
Signed-off-by: Jorge Solórzano <[email protected]>
1 parent ae29b75 commit 40b1b12

File tree

5 files changed

+26
-17
lines changed

5 files changed

+26
-17
lines changed

pom.xml

+18-10
Original file line numberDiff line numberDiff line change
@@ -49,10 +49,11 @@
4949
</contributors>
5050

5151
<dependencies>
52+
<!-- Plexus dependencies -->
5253
<dependency>
5354
<groupId>org.codehaus.plexus</groupId>
5455
<artifactId>plexus-container-default</artifactId>
55-
<version>1.0-alpha-30</version>
56+
<version>2.1.1</version>
5657
<scope>provided</scope>
5758
</dependency>
5859
<dependency>
@@ -65,37 +66,44 @@
6566
<artifactId>plexus-io</artifactId>
6667
<version>3.2.0</version>
6768
</dependency>
69+
<!-- Apache Commons dependencies -->
70+
<dependency>
71+
<groupId>commons-io</groupId>
72+
<artifactId>commons-io</artifactId>
73+
<version>2.11.0</version>
74+
</dependency>
6875
<dependency>
6976
<groupId>org.apache.commons</groupId>
7077
<artifactId>commons-compress</artifactId>
7178
<version>1.21</version>
7279
</dependency>
80+
<!-- Other dependencies -->
7381
<dependency>
7482
<groupId>org.iq80.snappy</groupId>
7583
<artifactId>snappy</artifactId>
7684
<version>0.4</version>
7785
</dependency>
7886
<dependency>
79-
<groupId>junit</groupId>
80-
<artifactId>junit</artifactId>
81-
<version>4.13.2</version>
82-
<scope>test</scope>
87+
<groupId>org.tukaani</groupId>
88+
<artifactId>xz</artifactId>
89+
<version>1.9</version>
90+
<scope>runtime</scope>
8391
</dependency>
8492
<dependency>
8593
<groupId>com.google.code.findbugs</groupId>
8694
<artifactId>jsr305</artifactId>
8795
<version>3.0.2</version>
8896
<scope>provided</scope>
8997
</dependency>
98+
<!-- Test dependencies -->
9099
<dependency>
91-
<groupId>org.tukaani</groupId>
92-
<artifactId>xz</artifactId>
93-
<version>1.9</version>
94-
<scope>runtime</scope>
100+
<groupId>junit</groupId>
101+
<artifactId>junit</artifactId>
102+
<version>4.13.2</version>
103+
<scope>test</scope>
95104
</dependency>
96105
</dependencies>
97106

98-
99107
<build>
100108
<plugins>
101109
<plugin>

src/main/java/org/codehaus/plexus/archiver/AbstractUnArchiver.java

+2-1
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
import java.util.ArrayList;
2626
import java.util.Date;
2727
import java.util.List;
28+
import java.util.Locale;
2829

2930
import org.codehaus.plexus.archiver.util.ArchiveEntryUtils;
3031
import org.codehaus.plexus.components.io.attributes.SymlinkUtils;
@@ -412,7 +413,7 @@ protected boolean shouldExtractEntry( File targetDirectory, File targetFileName,
412413
boolean fileOnDiskIsNewerThanEntry = targetFileName.lastModified() >= entryDate.getTime();
413414
boolean differentCasing = !entryName.equals( relativeCanonicalDestPath );
414415

415-
String casingMessage = String.format( "Archive entry '%s' and existing file '%s' names differ only by case."
416+
String casingMessage = String.format( Locale.ENGLISH, "Archive entry '%s' and existing file '%s' names differ only by case."
416417
+ " This may lead to an unexpected outcome on case-insensitive filesystems.", entryName, canonicalDestPath );
417418

418419
// (1)

src/main/java/org/codehaus/plexus/archiver/jar/JarToolModularJarArchiver.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
import java.util.zip.ZipOutputStream;
3737

3838
import org.apache.commons.compress.parallel.InputStreamSupplier;
39-
import org.apache.commons.io.output.NullOutputStream;
39+
import org.apache.commons.io.output.NullPrintStream;
4040
import org.codehaus.plexus.archiver.ArchiverException;
4141
import org.codehaus.plexus.archiver.zip.ConcurrentJarCreator;
4242
import org.codehaus.plexus.util.IOUtil;
@@ -294,7 +294,7 @@ private boolean isJarDateOptionSupported( Method runMethod )
294294
// Test the output code validating the --date option.
295295
String[] args = { "--date", "2099-12-31T23:59:59Z", "--version" };
296296

297-
PrintStream nullPrintStream = new PrintStream( NullOutputStream.NULL_OUTPUT_STREAM );
297+
PrintStream nullPrintStream = NullPrintStream.NULL_PRINT_STREAM;
298298
Integer result = (Integer) runMethod.invoke( jarTool, nullPrintStream, nullPrintStream, args );
299299

300300
return result != null && result.intValue() == 0;

src/main/java/org/codehaus/plexus/archiver/jar/Manifest.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -510,7 +510,7 @@ public Iterator<String> iterator()
510510
*/
511511
public Attribute getAttribute( String attributeName )
512512
{
513-
return attributes.get( attributeName.toLowerCase() );
513+
return attributes.get( attributeName.toLowerCase( Locale.ENGLISH ) );
514514
}
515515

516516
/**

src/test/java/org/codehaus/plexus/archiver/DuplicateFilesTest.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,13 @@
33
import java.io.BufferedInputStream;
44
import java.io.BufferedReader;
55
import java.io.File;
6-
import java.io.FileInputStream;
7-
import java.io.FileReader;
86
import java.nio.charset.StandardCharsets;
97
import java.nio.file.Files;
108
import java.util.Enumeration;
119

1210
import org.apache.commons.compress.archivers.tar.TarArchiveInputStream;
1311
import org.apache.commons.compress.archivers.zip.ZipArchiveEntry;
12+
import org.codehaus.plexus.DefaultPlexusContainer;
1413
import org.codehaus.plexus.PlexusTestCase;
1514
import org.codehaus.plexus.archiver.tar.TarArchiver;
1615
import org.codehaus.plexus.archiver.tar.TarLongFileMode;
@@ -34,7 +33,8 @@ public void setUp()
3433
throws Exception
3534
{
3635
super.setUp();
37-
getContainer().getLoggerManager().setThreshold( Logger.LEVEL_DEBUG );
36+
DefaultPlexusContainer container = (DefaultPlexusContainer) getContainer();
37+
container.getLoggerManager().setThreshold( Logger.LEVEL_DEBUG );
3838
}
3939

4040
public void testZipArchiver()

0 commit comments

Comments
 (0)