public function process($source, $target, $commands)
    {
        $targetFolder = pathinfo($target, PATHINFO_DIRNAME);
        if (!file_exists($targetFolder)) {
            mkdir($targetFolder, 0777, true);
        }
        $this->image = $this->getImagineService()->open($source);
        foreach ($this->analyseCommands($commands) as $command) {
            if ($this->runCommand($command)) {
                continue;
            }
            $this->runCustomCommand($command);
        }
        
        $this->image->save($target);
    }