Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[MRRESOURCES-102] Implement MRRESOURCES-102 #2

Closed
wants to merge 4 commits into from
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -853,7 +853,7 @@ protected boolean copyResourceIfExists( File file, String relFileName, VelocityC
}
else if ( resource.isFiltering() )
{
MavenFileFilterRequest req = setupRequest( source, file, resource.isFiltering() );
MavenFileFilterRequest req = setupRequest( source, file );

try
{
Expand Down Expand Up @@ -944,12 +944,12 @@ private void fileWriteIfDiffers( DeferredFileOutputStream outStream )
}
}

private MavenFileFilterRequest setupRequest( File source, File file, boolean isFiltering )
private MavenFileFilterRequest setupRequest( File source, File file )
{
MavenFileFilterRequest req = new MavenFileFilterRequest();
req.setFrom( source );
req.setTo( file );
req.setFiltering( isFiltering );
req.setFiltering( true );
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But this filtering always active, is that what we want?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The property useResourceFiltering is still adhered to. It's evaluated on line 1279.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@rfscholte do we need more review here?


req.setMavenProject( project );
req.setMavenSession( mavenSession );
Expand Down Expand Up @@ -1360,7 +1360,7 @@ private void filterBundleResource( ClassLoader classLoader, String bundleResourc
tmpFile = File.createTempFile( "maven-remote-resources-plugin", null );
tmpFile.deleteOnExit();
Jurrie marked this conversation as resolved.
Show resolved Hide resolved
copyBundleResource( classLoader, bundleResource, tmpFile );
MavenFileFilterRequest req = setupRequest( tmpFile, to, true );
MavenFileFilterRequest req = setupRequest( tmpFile, to );
fileFilter.copyFile( req );
}
catch ( MavenFilteringException e )
Expand Down