Skip to content

Commit c58c7dc

Browse files
committed
Update default configuration to no longer save previewed pages
1 parent 4622237 commit c58c7dc

File tree

5 files changed

+4
-15
lines changed

5 files changed

+4
-15
lines changed

RELEASE_NOTES.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ This serves two purposes:
5151
- Minor: The `processing_time_ms` attribute in the `sitemap.xml` file has now been removed in https://github.com/hydephp/develop/pull/1744
5252
- Minor: Updated the `Hyde::url()` helper throw a `BadMethodCallException` instead `BaseUrlNotSetException` when no site URL is set and no path was provided to the method in https://github.com/hydephp/develop/pull/1760 and https://github.com/hydephp/develop/pull/1890
5353
- Minor: Updated the blog post layout and post feed component to use the `BlogPosting` Schema.org type instead of `Article` in https://github.com/hydephp/develop/pull/1887
54+
- Updated default configuration to no longer save previewed pages in https://github.com/hydephp/develop/pull/1995
5455
- Added more rich markup data to blog post components in https://github.com/hydephp/develop/pull/1888 (Note that this inevitably changes the HTML output of the blog post components, and that any customized templates will need to be republished to reflect these changes)
5556
- Overhauled the blog post author feature in https://github.com/hydephp/develop/pull/1782
5657
- Improved the sitemap data generation to be smarter and more dynamic in https://github.com/hydephp/develop/pull/1744

config/hyde.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -423,7 +423,7 @@
423423
'host' => env('SERVER_HOST', 'localhost'),
424424

425425
// Should preview pages be saved to the output directory?
426-
'save_preview' => true,
426+
'save_preview' => false,
427427

428428
// Should the live edit feature be enabled?
429429
'live_edit' => env('SERVER_LIVE_EDIT', true),

docs/extensions/realtime-compiler.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ The server can be configured in the `config/hyde.php` file to change the port, h
3131
'server' => [
3232
'port' => env('SERVER_PORT', 8080),
3333
'host' => env('SERVER_HOST', 'localhost'),
34-
'save_preview' => true,
34+
'save_preview' => false,
3535
],
3636
```
3737

packages/framework/config/hyde.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -423,7 +423,7 @@
423423
'host' => env('SERVER_HOST', 'localhost'),
424424

425425
// Should preview pages be saved to the output directory?
426-
'save_preview' => true,
426+
'save_preview' => false,
427427

428428
// Should the live edit feature be enabled?
429429
'live_edit' => env('SERVER_LIVE_EDIT', true),

packages/realtime-compiler/tests/RealtimeCompilerTest.php

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -49,11 +49,6 @@ public function testHandlesRoutesIndexPage()
4949
$this->assertEquals(200, $response->statusCode);
5050
$this->assertEquals('OK', $response->statusMessage);
5151
$this->assertStringContainsString('<title>Welcome to HydePHP!</title>', $response->body);
52-
53-
$this->assertFileExists(hyde()->path('_site/index.html'));
54-
$this->assertEquals($response->body, Filesystem::get('_site/index.html'));
55-
56-
Filesystem::unlink('_site/index.html');
5752
}
5853

5954
public function testHandlesRoutesCustomPages()
@@ -71,13 +66,10 @@ public function testHandlesRoutesCustomPages()
7166
$this->assertStringContainsString('<h1>Hello World!</h1>', $response->body);
7267

7368
Filesystem::unlink('_pages/foo.md');
74-
Filesystem::unlink('_site/foo.html');
7569
}
7670

7771
public function testHandlesRoutesPagesWithHtmlExtension()
7872
{
79-
$this->mockRoute('foo.html');
80-
8173
Filesystem::put('_pages/foo.md', '# Hello World!');
8274

8375
$kernel = new HttpKernel();
@@ -89,7 +81,6 @@ public function testHandlesRoutesPagesWithHtmlExtension()
8981
$this->assertStringContainsString('<h1>Hello World!</h1>', $response->body);
9082

9183
Filesystem::unlink('_pages/foo.md');
92-
Filesystem::unlink('_site/foo.html');
9384
}
9485

9586
public function testHandlesRoutesStaticAssets()
@@ -144,7 +135,6 @@ public function testTrailingSlashesAreNormalizedFromRoute()
144135
$this->assertStringContainsString('<h1>Hello World!</h1>', $response->body);
145136

146137
Filesystem::unlink('_pages/foo.md');
147-
Filesystem::unlink('_site/foo.html');
148138
}
149139

150140
public function testDocsUriPathIsReroutedToDocsIndex()
@@ -162,7 +152,6 @@ public function testDocsUriPathIsReroutedToDocsIndex()
162152
$this->assertStringContainsString('HydePHP Docs', $response->body);
163153

164154
Filesystem::unlink('_docs/index.md');
165-
Filesystem::unlink('_site/docs/index.html');
166155
}
167156

168157
public function testDocsSearchRendersSearchPage()
@@ -179,7 +168,6 @@ public function testDocsSearchRendersSearchPage()
179168
$this->assertStringContainsString('Search the documentation site', $response->body);
180169

181170
Filesystem::unlink('_docs/index.md');
182-
Filesystem::unlink('_site/docs/search.html');
183171
}
184172

185173
public function testPingRouteReturnsPingResponse()

0 commit comments

Comments
 (0)