Class FindAndReplaceProcessor

All Implemented Interfaces:
DeploymentProcessor, InitializableByConfigBean, org.springframework.beans.factory.Aware, org.springframework.beans.factory.BeanNameAware

public class FindAndReplaceProcessor extends AbstractMainDeploymentProcessor
Implementation of DeploymentProcessor to replace a pattern on the content of the created or updated files of a Deployment.

Note: the files changed by this processor will not be committed to the git repository and will be discarded when the next deployment starts.

Can be configured with the following YAML properties:
  • textPattern: Regular expression to search in files
  • replacement: Expression to replace the matches
Author:
joseross
  • Field Details

    • CONFIG_KEY_TEXT_PATTERN

      protected static final String CONFIG_KEY_TEXT_PATTERN
      See Also:
    • CONFIG_KEY_REPLACEMENT

      protected static final String CONFIG_KEY_REPLACEMENT
      See Also:
    • localRepoUrl

      protected String localRepoUrl
      URL for the local git repository.
    • textPattern

      protected String textPattern
      Regular expression to search in files.
    • replacement

      protected String replacement
      Expression to replace the matches.
  • Constructor Details

    • FindAndReplaceProcessor

      public FindAndReplaceProcessor()
  • Method Details