Source:
<code>public Trans loadTransFromFilesystem( String initialDir, String filename, String jarFilename, String base64Zip ) throws Exception { Trans trans = null; if ( !Utils.isEmpty( base64Zip ) ) { String zipName = java.util.UUID.randomUUID().toString() + ".zip"; <START> filename = "zip:file:" + File.separator + File.separator + System.getProperty( "user.dir" ) + File.separator + zipName + "!" + filename; <END> decodeBase64StringToFile( base64Zip, zipName, true ); } if ( !Utils.isEmpty( filename ) ) { String filepath = filename; if ( !KettleVFS.startsWithScheme( filename ) && !FileUtil.isFullyQualified( filename ) ) { filepath = initialDir + filename; } logDebug( "Pan.Log.LoadingTransXML", "" + filepath ); TransMeta transMeta = new TransMeta( filepath ); trans = new Trans( transMeta ); } if ( !Utils.isEmpty( jarFilename ) ) { try { logDebug( "Pan.Log.LoadingTransJar", jarFilename ); InputStream inputStream = PanCommandExecutor.class.getResourceAsStream( jarFilename ); StringBuilder xml = new StringBuilder(); int c; while ( ( c = inputStream.read() ) != -1 ) { xml.append( (char) c ); } inputStream.close(); Document document = XMLHandler.loadXMLString( xml.toString() ); TransMeta transMeta = new TransMeta( XMLHandler.getSubNode( document, "transformation" ), null ); trans = new Trans( transMeta ); } catch ( Exception e ) { System.out.println( BaseMessages.getString( getPkgClazz(), "Pan.Error.ReadingJar", e.toString() ) ); System.out.println( Const.getStackTracker( e ) ); throw e; } } if ( trans != null ) { trans.setMetaStore( getMetaStore() ); } return trans; }</code><technical_language>Const.getUserHomeDirectory() instead of System.getProperty( "user.dir" ) <LINK_0></technical_language>

Target:
public Trans loadTransFromFilesystem( String initialDir, String filename, String jarFilename, String base64Zip ) throws Exception { Trans trans = null; if ( !Utils.isEmpty( base64Zip ) ) { String zipPath = Const.getUserHomeDirectory() + File.separator + java.util.UUID.randomUUID().toString() + ".zip"; filename = "zip:file:" + File.separator + File.separator + zipPath + "!" + filename; File zipFile; try { zipFile = decodeBase64StringToFile( base64Zip, zipPath ); } catch ( IOException e ) { getLog().logError( e.toString() + "\n" ); e.printStackTrace(); return null; } zipFile.deleteOnExit(); } if ( !Utils.isEmpty( filename ) ) { String filepath = filename; if ( !KettleVFS.startsWithScheme( filename ) && !FileUtil.isFullyQualified( filename ) ) { filepath = initialDir + filename; } logDebug( "Pan.Log.LoadingTransXML", "" + filepath ); TransMeta transMeta = new TransMeta( filepath ); trans = new Trans( transMeta ); } if ( !Utils.isEmpty( jarFilename ) ) { try { logDebug( "Pan.Log.LoadingTransJar", jarFilename ); InputStream inputStream = PanCommandExecutor.class.getResourceAsStream( jarFilename ); StringBuilder xml = new StringBuilder(); int c; while ( ( c = inputStream.read() ) != -1 ) { xml.append( (char) c ); } inputStream.close(); Document document = XMLHandler.loadXMLString( xml.toString() ); TransMeta transMeta = new TransMeta( XMLHandler.getSubNode( document, "transformation" ), null ); trans = new Trans( transMeta ); } catch ( Exception e ) { System.out.println( BaseMessages.getString( getPkgClazz(), "Pan.Error.ReadingJar", e.toString() ) ); System.out.println( Const.getStackTracker( e ) ); throw e; } } if ( trans != null ) { trans.setMetaStore( getMetaStore() ); } return trans; }