@Override
  public void execute() throws BuildException {
    if (myInputs == null || myInputs.isEmpty()) {
      throw new BuildException("Some inputs must be specified");
    }

    if (myOutputs == null || myOutputs.isEmpty()) {
      throw new BuildException("Some outputs must be specified");
    }

    if (myStateFile == null) {
      throw new BuildException("stateFile is not set");
    }

    try {
      if (isDirty(false)) {
        nestedTask.perform();

        java.nio.file.Path stateFilePath = myStateFile.toPath();
        Files.createDirectories(stateFilePath.getParent());
        Files.writeString(stateFilePath, buildManifest(myInputs, true) + "\n" + buildManifest(myOutputs, true));

        if (isDirty(true)) {
          throw new BuildException("Not UP-TO-DATE after writing state file at " + myStateFile);
        }
      }
      else {
        log("UP-TO-DATE according to state file " + myStateFile);
      }
    }
    catch (IOException e) {
      throw new RuntimeException(e);
    }
  }
@Override
  public void execute()