private void pushExtraArgsToDevice(
    AndroidDevice device,
    SelendroidCapabilities caps
  ) {
    String devicePath = new File(
      device.getExternalStoragePath(),
      "extra_args.json"
    ).getAbsolutePath();

    // Make sure we clean the file in case we don't push a new one
    log.info("Clearing extra args file from device");
    device.runAdbCommand(String.format("shell rm %s", devicePath));

    if (!caps.hasExtraAUTArgs()) {
      return;
    }

    try {
      final String fileContents = caps.getExtraAUTArgs().toString();
      File temp = File.createTempFile("extra_args", ".json");
      FileUtils.write(temp, fileContents);

      log.info("Pushing new extra args file to device");
      device.runAdbCommand(
        String.format("push %s %s", temp.getAbsolutePath(), devicePath)
      );
    } catch(IOException e) {
      throw new RuntimeException("Error while writing extra args to disk", e);
    }
  }
This function will sign an android app and add it to the App Store. The function is made public because it also be
invoked by the Folder Monitor each time a new application dropped into this folder.

@param file
         - The file to be added to the app store
@throws AndroidSdkException
selendroid-standalone/src/main/java/io/selendroid/standalone/server/model/SelendroidStandaloneDriver.java