From 338a59e73be724c8630524054316ddee98618a6c Mon Sep 17 00:00:00 2001 From: Or Geva Date: Sun, 18 Feb 2024 09:52:25 +0200 Subject: [PATCH] Add persistToPropertiesFile overload (#784) --- .../clientConfiguration/ArtifactoryClientConfiguration.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/build-info-extractor/src/main/java/org/jfrog/build/extractor/clientConfiguration/ArtifactoryClientConfiguration.java b/build-info-extractor/src/main/java/org/jfrog/build/extractor/clientConfiguration/ArtifactoryClientConfiguration.java index 2bb90e989..196d3be65 100644 --- a/build-info-extractor/src/main/java/org/jfrog/build/extractor/clientConfiguration/ArtifactoryClientConfiguration.java +++ b/build-info-extractor/src/main/java/org/jfrog/build/extractor/clientConfiguration/ArtifactoryClientConfiguration.java @@ -239,12 +239,15 @@ public void persistToPropertiesFile() { return; } try (FileOutputStream fos = new FileOutputStream(new File(getPropertiesFile()).getCanonicalFile())) { - preparePropertiesToPersist().store(fos, "BuildInfo configuration property file"); + persistToPropertiesFile(fos); } catch (IOException e) { throw new RuntimeException(e); } } + public void persistToPropertiesFile(OutputStream os) throws IOException { + preparePropertiesToPersist().store(os, "BuildInfo configuration property file"); + } public EncryptionKeyPair persistToEncryptedPropertiesFile(OutputStream os) throws IOException, InvalidAlgorithmParameterException, NoSuchPaddingException, IllegalBlockSizeException, NoSuchAlgorithmException, BadPaddingException, InvalidKeyException { if (StringUtils.isEmpty(getPropertiesFile())) {