Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
"illuminate/database": "^11.0 || ^12.0",
"illuminate/filesystem": "^11.0 || ^12.0",
"illuminate/support": "^11.0 || ^12.0",
"laravel/prompts": ">=0.3.6"
"laravel/prompts": ">=0.3.6",
"spatie/temporary-directory": "^2.3"
},
"require-dev": {
"dragon-code/codestyler": "^6.3",
Expand Down
20 changes: 10 additions & 10 deletions docs/snippets/advanced-directive-array.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,18 @@
<array_directive>

<user>
<name>Noemy Kulas</name>
<avatar>https://via.placeholder.com/640x480.png/00ccff?text=minus</avatar>
<avatar>https://via.placeholder.com/640x480.png/00cc66?text=unde</avatar>
<images name="blanditiis in qui">https://via.placeholder.com/640x480.png/00cc99?text=minus</images>
<images name="sunt odit dolores">https://via.placeholder.com/640x480.png/00aaee?text=enim</images>
<name>Dr. Mozelle Hand V</name>
<avatar>https://via.placeholder.com/640x480.png/00ddee?text=iste</avatar>
<avatar>https://via.placeholder.com/640x480.png/00aaaa?text=dolorem</avatar>
<images name="laborum tenetur non">https://via.placeholder.com/640x480.png/002288?text=quasi</images>
<images name="illum quam sit">https://via.placeholder.com/640x480.png/00aa66?text=explicabo</images>
</user>
<user>
<name>Mr. Orlando Langworth IV</name>
<avatar>https://via.placeholder.com/640x480.png/0099aa?text=ea</avatar>
<avatar>https://via.placeholder.com/640x480.png/000088?text=occaecati</avatar>
<images name="vel temporibus maxime">https://via.placeholder.com/640x480.png/009955?text=est</images>
<images name="aut nihil voluptatem">https://via.placeholder.com/640x480.png/007788?text=voluptatum</images>
<name>Lori Gislason</name>
<avatar>https://via.placeholder.com/640x480.png/001144?text=nostrum</avatar>
<avatar>https://via.placeholder.com/640x480.png/002200?text=numquam</avatar>
<images name="tempora eos tenetur">https://via.placeholder.com/640x480.png/005544?text=consequatur</images>
<images name="excepturi fuga eligendi">https://via.placeholder.com/640x480.png/0011dd?text=maiores</images>
</user>

</array_directive>
10 changes: 5 additions & 5 deletions docs/snippets/advanced-directive-attributes.xml
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
<?xml version="1.0" encoding="UTF-8"?>
<attributes_directive>

<company since="1983"/>
<company since="2018"/>
<url>https://example.com</url>

<user>
<name>Kali Schamberger</name>
<contact email="hardy.spinka@example.org" phone="555-000-1"/>
<name>Doyle Donnelly</name>
<contact email="adolphus.emard@example.net" phone="555-000-1"/>
</user>
<user>
<name>Kathleen Lynch</name>
<contact email="rossie65@example.net" phone="555-000-2"/>
<name>Sally Pagac Sr.</name>
<contact email="walsh.tyree@example.org" phone="555-000-2"/>
</user>

</attributes_directive>
8 changes: 4 additions & 4 deletions docs/snippets/advanced-directive-cdata.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@
<cdata_directive>

<user>
<name><![CDATA[<h1>Cheyanne Labadie MD</h1>]]></name>
<email>jovani.torphy@example.net</email>
<name><![CDATA[<h1>Sallie Price</h1>]]></name>
<email>ssporer@example.net</email>
</user>
<user>
<name><![CDATA[<h1>Dock Cruickshank</h1>]]></name>
<email>rhowell@example.com</email>
<name><![CDATA[<h1>Dr. Nedra Weimann</h1>]]></name>
<email>beau.feest@example.net</email>
</user>

</cdata_directive>
8 changes: 4 additions & 4 deletions docs/snippets/advanced-directive-mixed.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,17 @@
<mixed_directive>

<user>
<name>Prof. Ed Hegmann Sr.</name>
<name>Bradley Krajcik</name>
<some>
<first>Foo</first>
<second>gerlach.prince@example.com</second>
<second>alexander73@example.net</second>
</some>
</user>
<user>
<name>Dr. Torrance Kris</name>
<name>Jamil Hilpert PhD</name>
<some>
<first>Foo</first>
<second>hreichel@example.net</second>
<second>vwalsh@example.net</second>
</some>
</user>

Expand Down
8 changes: 4 additions & 4 deletions docs/snippets/advanced-directive-value.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@
<value_directive>

<user>
<name>Margaret Gottlieb</name>
<contact type="email">ferry.delilah@example.org</contact>
<name>Mr. Cyril Douglas</name>
<contact type="email">grant.kassulke@example.com</contact>
</user>
<user>
<name>Prof. Itzel Auer</name>
<contact type="email">myra00@example.com</contact>
<name>Prof. Camille Veum DVM</name>
<contact type="email">hfranecki@example.com</contact>
</user>

</value_directive>
8 changes: 4 additions & 4 deletions docs/snippets/advanced-element-attribute.xml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
<?xml version="1.0" encoding="UTF-8"?>
<attribute>

<user created_at="2025-09-14T20:47:53+00:00">
<user created_at="2025-09-16T13:25:14+00:00">
<id>1</id>
<name>Jaron Conn</name>
<name>Efren Prosacco</name>
</user>
<user created_at="2025-09-14T20:47:53+00:00">
<user created_at="2025-09-16T13:25:14+00:00">
<id>2</id>
<name>Eloisa West</name>
<name>Elwyn Kuphal DDS</name>
</user>

</attribute>
4 changes: 2 additions & 2 deletions docs/snippets/advanced-element-header-footer.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@

<user>
<id>1</id>
<name>Stanford Leffler</name>
<name>Arnaldo Mohr</name>
</user>
<user>
<id>2</id>
<name>Ellen Johns</name>
<name>Dillan Beahan</name>
</user>

</header_footer>
Expand Down
4 changes: 2 additions & 2 deletions docs/snippets/advanced-element-info-before-false.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@

<user>
<id>1</id>
<name>Miss Corrine Wehner</name>
<name>Hilton Rath</name>
</user>
<user>
<id>2</id>
<name>Prof. Annamae Gibson III</name>
<name>Prof. Juanita Oberbrunner</name>
</user>

</info_method>
4 changes: 2 additions & 2 deletions docs/snippets/advanced-element-info.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@

<user>
<id>1</id>
<name>Prof. Glennie Hessel V</name>
<name>Sigurd Mueller</name>
</user>
<user>
<id>2</id>
<name>Odie Christiansen</name>
<name>Kiera Hansen</name>
</user>

</info_method>
4 changes: 2 additions & 2 deletions docs/snippets/advanced-element-root.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@

<user>
<id>1</id>
<name>Dr. Laron Ziemann DDS</name>
<name>Darby Davis MD</name>
</user>
<user>
<id>2</id>
<name>Elton Stark</name>
<name>Dr. Mattie Rippin</name>
</user>

</foo>
4 changes: 2 additions & 2 deletions docs/snippets/receipt-instagram-feed.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<g:id>1</g:id>
<g:title><![CDATA[Some 1]]></g:title>
<g:description><![CDATA[Some description 1]]></g:description>
<g:link>https://example.com/products/sit-et-suscipit-magni-numquam-quis-qui</g:link>
<g:link>https://example.com/products/ratione-minima-officia-adipisci-ratione-consectetur</g:link>
<g:image_link>https://via.placeholder.com/640x480.png/008877?text=repudiandae</g:image_link>
<g:additional_image_link>https://via.placeholder.com/640x480.png/008877?text=repudiandae</g:additional_image_link>
<g:brand>The Best</g:brand>
Expand All @@ -31,7 +31,7 @@
<g:id>2</g:id>
<g:title><![CDATA[Some 2]]></g:title>
<g:description><![CDATA[Some description 2]]></g:description>
<g:link>https://example.com/products/quo-consequatur-earum-aut-harum-quis</g:link>
<g:link>https://example.com/products/accusamus-animi-animi-earum-quis</g:link>
<g:image_link>https://via.placeholder.com/640x480.png/009966?text=beatae</g:image_link>
<g:additional_image_link>https://via.placeholder.com/640x480.png/009966?text=beatae</g:additional_image_link>
<g:additional_image_link>https://via.placeholder.com/640x480.png/000011?text=deleniti</g:additional_image_link>
Expand Down
4 changes: 2 additions & 2 deletions docs/snippets/receipt-rss-feed.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<guid>1</guid>
<description><![CDATA[Some content 1]]></description>
<category>Some category 1</category>
<pubDate>Wed, 03 Sep 2025 06:52:54 +0000</pubDate>
<pubDate>Wed, 03 Sep 2025 13:26:59 +0000</pubDate>
<foo>bar</foo>
</item>
<item>
Expand All @@ -17,7 +17,7 @@
<guid>2</guid>
<description><![CDATA[Some content 2]]></description>
<category>Some category 2</category>
<pubDate>Wed, 03 Sep 2025 10:00:45 +0000</pubDate>
<pubDate>Wed, 03 Sep 2025 14:17:03 +0000</pubDate>
<foo>bar</foo>
</item>

Expand Down
4 changes: 2 additions & 2 deletions docs/snippets/receipt-sitemap-feed.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:image="http://www.google.com/schemas/sitemap-image/1.1" xmlns:video="http://www.google.com/schemas/sitemap-video/1.1" xmlns:news="http://www.google.com/schemas/sitemap-news/0.9">

<url>
<loc>https://example.com/products/autem-dolorem-omnis-dolore-et-corporis-voluptate-cum-rerum</loc>
<loc>https://example.com/products/dolor-culpa-reiciendis-illo-magnam-nisi-quisquam-labore-aspernatur</loc>
<lastmod>2025-08-31T20:00:00+00:00</lastmod>
<priority>0.9</priority>
</url>
<url>
<loc>https://example.com/products/eum-sint-qui-qui-porro-vel-officia-aut-qui</loc>
<loc>https://example.com/products/quas-tempora-quia-animi-veniam-tempore-et-at</loc>
<lastmod>2025-08-30T19:00:00+00:00</lastmod>
<priority>0.9</priority>
</url>
Expand Down
4 changes: 2 additions & 2 deletions docs/snippets/receipt-yandex-feed.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<offers>

<offer id="1" available="true" type="vendor.model">
<url>https://example.com/products/libero-rerum-vel-non-fugit-aspernatur</url>
<url>https://example.com/products/ipsa-maiores-odit-dicta-temporibus-et-rerum</url>
<barcode>GD-PRDCT-1</barcode>
<name>Some 1</name>
<description>Some description 1</description>
Expand All @@ -29,7 +29,7 @@
<foo>bar</foo>
</offer>
<offer id="2" available="true" type="vendor.model">
<url>https://example.com/products/ex-vero-quia-ut-ex-laudantium-quia</url>
<url>https://example.com/products/quo-rerum-qui-eos-eius-quaerat-voluptatem-et</url>
<barcode>GD-PRDCT-2</barcode>
<name>Some 2</name>
<description>Some description 2</description>
Expand Down
5 changes: 3 additions & 2 deletions src/Exceptions/OpenFeedException.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,14 @@
namespace DragonCode\LaravelFeed\Exceptions;

use RuntimeException;
use Throwable;

// @codeCoverageIgnoreStart
class OpenFeedException extends RuntimeException
{
public function __construct(string $path)
public function __construct(string $path, Throwable $e)
{
parent::__construct("Unable to open file for writing: [$path]");
parent::__construct("Unable to open file for writing: [$path]", previous: $e);
}
}
// @codeCoverageIgnoreEnd
17 changes: 17 additions & 0 deletions src/Exceptions/ResourceMetaException.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<?php

declare(strict_types=1);

namespace DragonCode\LaravelFeed\Exceptions;

use Exception;

// @codeCoverageIgnoreStart
class ResourceMetaException extends Exception
{
public function __construct()
{
parent::__construct('Unable to get a link to the file from the resource.');
}
}
// @codeCoverageIgnoreEnd
Loading