Version 1
[yaffs-website] / vendor / alchemy / zippy / src / Adapter / GNUTar / TarBz2GNUTarAdapter.php
diff --git a/vendor/alchemy/zippy/src/Adapter/GNUTar/TarBz2GNUTarAdapter.php b/vendor/alchemy/zippy/src/Adapter/GNUTar/TarBz2GNUTarAdapter.php
new file mode 100644 (file)
index 0000000..d44dc25
--- /dev/null
@@ -0,0 +1,25 @@
+<?php
+
+namespace Alchemy\Zippy\Adapter\GNUTar;
+
+use Alchemy\Zippy\Adapter\Resource\ResourceInterface;
+use Alchemy\Zippy\Exception\NotSupportedException;
+
+class TarBz2GNUTarAdapter extends TarGNUTarAdapter
+{
+    /**
+     * @inheritdoc
+     */
+    protected function doAdd(ResourceInterface $resource, $files, $recursive)
+    {
+        throw new NotSupportedException('Updating a compressed tar archive is not supported.');
+    }
+
+    /**
+     * @inheritdoc
+     */
+    protected function getLocalOptions()
+    {
+        return array('--bzip2');
+    }
+}