From 2680d2c506085dbc65990981b3dcddd5cac64878 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 18:47:24 +0200 Subject: [PATCH 001/768] Move all files to subdirectory --- .../framework/src/{ => Framework}/Actions/BladeMatterParser.php | 0 .../Actions/Constructors/FindsContentLengthForImageObject.php | 0 .../Actions/Constructors/FindsNavigationDataForPage.php | 0 .../{ => Framework}/Actions/Constructors/FindsTitleForPage.php | 0 .../src/{ => Framework}/Actions/ConvertsArrayToFrontMatter.php | 0 .../src/{ => Framework}/Actions/CreatesNewMarkdownPostFile.php | 0 .../src/{ => Framework}/Actions/CreatesNewPageSourceFile.php | 0 .../{ => Framework}/Actions/GeneratesSidebarTableOfContents.php | 0 .../framework/src/{ => Framework}/Actions/MarkdownConverter.php | 0 .../framework/src/{ => Framework}/Actions/MarkdownFileParser.php | 0 .../Actions/PostBuildTasks/GenerateBuildManifest.php | 0 .../{ => Framework}/Actions/PostBuildTasks/GenerateRssFeed.php | 0 .../src/{ => Framework}/Actions/PostBuildTasks/GenerateSearch.php | 0 .../{ => Framework}/Actions/PostBuildTasks/GenerateSitemap.php | 0 .../src/{ => Framework}/Actions/PublishesHomepageView.php | 0 .../framework/src/{ => Framework}/Actions/PublishesHydeViews.php | 0 .../framework/src/{ => Framework}/Actions/SourceFileParser.php | 0 .../framework/src/{ => Framework}/Actions/StaticPageBuilder.php | 0 .../src/{ => Framework}/Commands/HydeBuildRssFeedCommand.php | 0 .../src/{ => Framework}/Commands/HydeBuildSearchCommand.php | 0 .../src/{ => Framework}/Commands/HydeBuildSiteCommand.php | 0 .../src/{ => Framework}/Commands/HydeBuildSitemapCommand.php | 0 .../framework/src/{ => Framework}/Commands/HydeDebugCommand.php | 0 .../src/{ => Framework}/Commands/HydeMakePageCommand.php | 0 .../src/{ => Framework}/Commands/HydeMakePostCommand.php | 0 .../src/{ => Framework}/Commands/HydePackageDiscoverCommand.php | 0 .../src/{ => Framework}/Commands/HydePublishHomepageCommand.php | 0 .../src/{ => Framework}/Commands/HydePublishViewsCommand.php | 0 .../src/{ => Framework}/Commands/HydeRebuildStaticSiteCommand.php | 0 .../src/{ => Framework}/Commands/HydeRouteListCommand.php | 0 .../framework/src/{ => Framework}/Commands/HydeServeCommand.php | 0 .../src/{ => Framework}/Commands/HydeUpdateConfigsCommand.php | 0 .../src/{ => Framework}/Commands/HydeValidateCommand.php | 0 .../framework/src/{ => Framework}/Concerns/AbstractBuildTask.php | 0 .../framework/src/{ => Framework}/Concerns/BaseMarkdownPage.php | 0 packages/framework/src/{ => Framework}/Concerns/HydePage.php | 0 .../src/{ => Framework}/Concerns/InteractsWithDirectories.php | 0 .../{ => Framework}/Concerns/Internal/ConstructsPageSchemas.php | 0 .../{ => Framework}/Concerns/Internal/SetsUpMarkdownConverter.php | 0 .../src/{ => Framework}/Concerns/JsonSerializesArrayable.php | 0 .../src/{ => Framework}/Concerns/RegistersFileLocations.php | 0 .../framework/src/{ => Framework}/Concerns/ValidatesExistence.php | 0 .../framework/src/{ => Framework}/Contracts/BuildTaskContract.php | 0 .../src/{ => Framework}/Contracts/CompilableContract.php | 0 .../src/{ => Framework}/Contracts/FrontMatter/BlogPostSchema.php | 0 .../Contracts/FrontMatter/DocumentationPageSchema.php | 0 .../src/{ => Framework}/Contracts/FrontMatter/PageSchema.php | 0 .../Contracts/FrontMatter/Support/FeaturedImageSchema.php | 0 .../Contracts/FrontMatter/Support/NavigationSchema.php | 0 .../src/{ => Framework}/Contracts/MarkdownDocumentContract.php | 0 .../{ => Framework}/Contracts/MarkdownPostProcessorContract.php | 0 .../{ => Framework}/Contracts/MarkdownPreProcessorContract.php | 0 .../src/{ => Framework}/Contracts/MarkdownShortcodeContract.php | 0 .../src/{ => Framework}/Exceptions/BaseUrlNotSetException.php | 0 .../src/{ => Framework}/Exceptions/FileConflictException.php | 0 .../src/{ => Framework}/Exceptions/FileNotFoundException.php | 0 .../src/{ => Framework}/Exceptions/RouteNotFoundException.php | 0 .../{ => Framework}/Exceptions/UnsupportedPageTypeException.php | 0 packages/framework/src/{ => Framework}/Foundation/Application.php | 0 .../Foundation/Concerns/BaseFoundationCollection.php | 0 .../{ => Framework}/Foundation/Concerns/ForwardsFilesystem.php | 0 .../{ => Framework}/Foundation/Concerns/ForwardsHyperlinks.php | 0 .../Foundation/Concerns/HandlesFoundationCollections.php | 0 .../Foundation/Concerns/ImplementsStringHelpers.php | 0 .../src/{ => Framework}/Foundation/Concerns/ManagesHydeKernel.php | 0 .../src/{ => Framework}/Foundation/Concerns/ManagesViewData.php | 0 .../framework/src/{ => Framework}/Foundation/FileCollection.php | 0 packages/framework/src/{ => Framework}/Foundation/Filesystem.php | 0 packages/framework/src/{ => Framework}/Foundation/Hyperlinks.php | 0 .../framework/src/{ => Framework}/Foundation/PageCollection.php | 0 .../framework/src/{ => Framework}/Foundation/RouteCollection.php | 0 packages/framework/src/{ => Framework}/Helpers/Asset.php | 0 packages/framework/src/{ => Framework}/Helpers/Features.php | 0 packages/framework/src/{ => Framework}/Helpers/Includes.php | 0 packages/framework/src/{ => Framework}/Helpers/Meta.php | 0 packages/framework/src/{ => Framework}/Helpers/Redirect.php | 0 packages/framework/src/{ => Framework}/Hyde.php | 0 packages/framework/src/{ => Framework}/HydeKernel.php | 0 packages/framework/src/{ => Framework}/HydeServiceProvider.php | 0 .../framework/src/{ => Framework}/Models/Markdown/FrontMatter.php | 0 .../framework/src/{ => Framework}/Models/Markdown/Markdown.php | 0 .../src/{ => Framework}/Models/Markdown/MarkdownDocument.php | 0 .../{ => Framework}/Models/Navigation/DocumentationSidebar.php | 0 .../framework/src/{ => Framework}/Models/Navigation/NavItem.php | 0 .../src/{ => Framework}/Models/Navigation/NavigationData.php | 0 .../src/{ => Framework}/Models/Navigation/NavigationMenu.php | 0 packages/framework/src/{ => Framework}/Models/Pages/BladePage.php | 0 .../src/{ => Framework}/Models/Pages/DocumentationPage.php | 0 packages/framework/src/{ => Framework}/Models/Pages/HtmlPage.php | 0 .../framework/src/{ => Framework}/Models/Pages/MarkdownPage.php | 0 .../framework/src/{ => Framework}/Models/Pages/MarkdownPost.php | 0 packages/framework/src/{ => Framework}/Models/Support/Author.php | 0 .../framework/src/{ => Framework}/Models/Support/DateString.php | 0 packages/framework/src/{ => Framework}/Models/Support/File.php | 0 packages/framework/src/{ => Framework}/Models/Support/Image.php | 0 packages/framework/src/{ => Framework}/Models/Support/Route.php | 0 packages/framework/src/{ => Framework}/Models/Support/Site.php | 0 .../src/{ => Framework}/Models/Support/ValidationResult.php | 0 .../{ => Framework}/Modules/DataCollections/DataCollection.php | 0 .../Modules/DataCollections/DataCollectionServiceProvider.php | 0 .../Modules/DataCollections/Facades/MarkdownCollection.php | 0 .../src/{ => Framework}/Modules/Markdown/BladeDownProcessor.php | 0 .../Modules/Markdown/CodeblockFilepathProcessor.php | 0 .../src/{ => Framework}/Modules/Markdown/ShortcodeProcessor.php | 0 .../Modules/Markdown/Shortcodes/ColoredBlockquotes.php | 0 .../src/{ => Framework}/Modules/Metadata/GlobalMetadataBag.php | 0 .../src/{ => Framework}/Modules/Metadata/MetadataBag.php | 0 .../{ => Framework}/Modules/Metadata/MetadataElementContract.php | 0 .../src/{ => Framework}/Modules/Metadata/Models/LinkElement.php | 0 .../{ => Framework}/Modules/Metadata/Models/MetadataElement.php | 0 .../{ => Framework}/Modules/Metadata/Models/OpenGraphElement.php | 0 .../src/{ => Framework}/Modules/Metadata/PageMetadataBag.php | 0 packages/framework/src/{ => Framework}/Modules/README.md | 0 packages/framework/src/{ => Framework}/Services/AssetService.php | 0 packages/framework/src/{ => Framework}/Services/BuildService.php | 0 .../framework/src/{ => Framework}/Services/BuildTaskService.php | 0 .../framework/src/{ => Framework}/Services/ChecksumService.php | 0 .../framework/src/{ => Framework}/Services/DiscoveryService.php | 0 .../src/{ => Framework}/Services/DocumentationSearchService.php | 0 .../framework/src/{ => Framework}/Services/MarkdownService.php | 0 .../framework/src/{ => Framework}/Services/RebuildService.php | 0 .../framework/src/{ => Framework}/Services/RssFeedService.php | 0 .../src/{ => Framework}/Services/SemanticDocumentationArticle.php | 0 .../framework/src/{ => Framework}/Services/SitemapService.php | 0 .../framework/src/{ => Framework}/Services/ValidationService.php | 0 .../src/{ => Framework}/Services/YamlConfigurationService.php | 0 .../src/{ => Framework}/Views/Components/LinkComponent.php | 0 packages/framework/src/{ => Framework}/helpers.php | 0 128 files changed, 0 insertions(+), 0 deletions(-) rename packages/framework/src/{ => Framework}/Actions/BladeMatterParser.php (100%) rename packages/framework/src/{ => Framework}/Actions/Constructors/FindsContentLengthForImageObject.php (100%) rename packages/framework/src/{ => Framework}/Actions/Constructors/FindsNavigationDataForPage.php (100%) rename packages/framework/src/{ => Framework}/Actions/Constructors/FindsTitleForPage.php (100%) rename packages/framework/src/{ => Framework}/Actions/ConvertsArrayToFrontMatter.php (100%) rename packages/framework/src/{ => Framework}/Actions/CreatesNewMarkdownPostFile.php (100%) rename packages/framework/src/{ => Framework}/Actions/CreatesNewPageSourceFile.php (100%) rename packages/framework/src/{ => Framework}/Actions/GeneratesSidebarTableOfContents.php (100%) rename packages/framework/src/{ => Framework}/Actions/MarkdownConverter.php (100%) rename packages/framework/src/{ => Framework}/Actions/MarkdownFileParser.php (100%) rename packages/framework/src/{ => Framework}/Actions/PostBuildTasks/GenerateBuildManifest.php (100%) rename packages/framework/src/{ => Framework}/Actions/PostBuildTasks/GenerateRssFeed.php (100%) rename packages/framework/src/{ => Framework}/Actions/PostBuildTasks/GenerateSearch.php (100%) rename packages/framework/src/{ => Framework}/Actions/PostBuildTasks/GenerateSitemap.php (100%) rename packages/framework/src/{ => Framework}/Actions/PublishesHomepageView.php (100%) rename packages/framework/src/{ => Framework}/Actions/PublishesHydeViews.php (100%) rename packages/framework/src/{ => Framework}/Actions/SourceFileParser.php (100%) rename packages/framework/src/{ => Framework}/Actions/StaticPageBuilder.php (100%) rename packages/framework/src/{ => Framework}/Commands/HydeBuildRssFeedCommand.php (100%) rename packages/framework/src/{ => Framework}/Commands/HydeBuildSearchCommand.php (100%) rename packages/framework/src/{ => Framework}/Commands/HydeBuildSiteCommand.php (100%) rename packages/framework/src/{ => Framework}/Commands/HydeBuildSitemapCommand.php (100%) rename packages/framework/src/{ => Framework}/Commands/HydeDebugCommand.php (100%) rename packages/framework/src/{ => Framework}/Commands/HydeMakePageCommand.php (100%) rename packages/framework/src/{ => Framework}/Commands/HydeMakePostCommand.php (100%) rename packages/framework/src/{ => Framework}/Commands/HydePackageDiscoverCommand.php (100%) rename packages/framework/src/{ => Framework}/Commands/HydePublishHomepageCommand.php (100%) rename packages/framework/src/{ => Framework}/Commands/HydePublishViewsCommand.php (100%) rename packages/framework/src/{ => Framework}/Commands/HydeRebuildStaticSiteCommand.php (100%) rename packages/framework/src/{ => Framework}/Commands/HydeRouteListCommand.php (100%) rename packages/framework/src/{ => Framework}/Commands/HydeServeCommand.php (100%) rename packages/framework/src/{ => Framework}/Commands/HydeUpdateConfigsCommand.php (100%) rename packages/framework/src/{ => Framework}/Commands/HydeValidateCommand.php (100%) rename packages/framework/src/{ => Framework}/Concerns/AbstractBuildTask.php (100%) rename packages/framework/src/{ => Framework}/Concerns/BaseMarkdownPage.php (100%) rename packages/framework/src/{ => Framework}/Concerns/HydePage.php (100%) rename packages/framework/src/{ => Framework}/Concerns/InteractsWithDirectories.php (100%) rename packages/framework/src/{ => Framework}/Concerns/Internal/ConstructsPageSchemas.php (100%) rename packages/framework/src/{ => Framework}/Concerns/Internal/SetsUpMarkdownConverter.php (100%) rename packages/framework/src/{ => Framework}/Concerns/JsonSerializesArrayable.php (100%) rename packages/framework/src/{ => Framework}/Concerns/RegistersFileLocations.php (100%) rename packages/framework/src/{ => Framework}/Concerns/ValidatesExistence.php (100%) rename packages/framework/src/{ => Framework}/Contracts/BuildTaskContract.php (100%) rename packages/framework/src/{ => Framework}/Contracts/CompilableContract.php (100%) rename packages/framework/src/{ => Framework}/Contracts/FrontMatter/BlogPostSchema.php (100%) rename packages/framework/src/{ => Framework}/Contracts/FrontMatter/DocumentationPageSchema.php (100%) rename packages/framework/src/{ => Framework}/Contracts/FrontMatter/PageSchema.php (100%) rename packages/framework/src/{ => Framework}/Contracts/FrontMatter/Support/FeaturedImageSchema.php (100%) rename packages/framework/src/{ => Framework}/Contracts/FrontMatter/Support/NavigationSchema.php (100%) rename packages/framework/src/{ => Framework}/Contracts/MarkdownDocumentContract.php (100%) rename packages/framework/src/{ => Framework}/Contracts/MarkdownPostProcessorContract.php (100%) rename packages/framework/src/{ => Framework}/Contracts/MarkdownPreProcessorContract.php (100%) rename packages/framework/src/{ => Framework}/Contracts/MarkdownShortcodeContract.php (100%) rename packages/framework/src/{ => Framework}/Exceptions/BaseUrlNotSetException.php (100%) rename packages/framework/src/{ => Framework}/Exceptions/FileConflictException.php (100%) rename packages/framework/src/{ => Framework}/Exceptions/FileNotFoundException.php (100%) rename packages/framework/src/{ => Framework}/Exceptions/RouteNotFoundException.php (100%) rename packages/framework/src/{ => Framework}/Exceptions/UnsupportedPageTypeException.php (100%) rename packages/framework/src/{ => Framework}/Foundation/Application.php (100%) rename packages/framework/src/{ => Framework}/Foundation/Concerns/BaseFoundationCollection.php (100%) rename packages/framework/src/{ => Framework}/Foundation/Concerns/ForwardsFilesystem.php (100%) rename packages/framework/src/{ => Framework}/Foundation/Concerns/ForwardsHyperlinks.php (100%) rename packages/framework/src/{ => Framework}/Foundation/Concerns/HandlesFoundationCollections.php (100%) rename packages/framework/src/{ => Framework}/Foundation/Concerns/ImplementsStringHelpers.php (100%) rename packages/framework/src/{ => Framework}/Foundation/Concerns/ManagesHydeKernel.php (100%) rename packages/framework/src/{ => Framework}/Foundation/Concerns/ManagesViewData.php (100%) rename packages/framework/src/{ => Framework}/Foundation/FileCollection.php (100%) rename packages/framework/src/{ => Framework}/Foundation/Filesystem.php (100%) rename packages/framework/src/{ => Framework}/Foundation/Hyperlinks.php (100%) rename packages/framework/src/{ => Framework}/Foundation/PageCollection.php (100%) rename packages/framework/src/{ => Framework}/Foundation/RouteCollection.php (100%) rename packages/framework/src/{ => Framework}/Helpers/Asset.php (100%) rename packages/framework/src/{ => Framework}/Helpers/Features.php (100%) rename packages/framework/src/{ => Framework}/Helpers/Includes.php (100%) rename packages/framework/src/{ => Framework}/Helpers/Meta.php (100%) rename packages/framework/src/{ => Framework}/Helpers/Redirect.php (100%) rename packages/framework/src/{ => Framework}/Hyde.php (100%) rename packages/framework/src/{ => Framework}/HydeKernel.php (100%) rename packages/framework/src/{ => Framework}/HydeServiceProvider.php (100%) rename packages/framework/src/{ => Framework}/Models/Markdown/FrontMatter.php (100%) rename packages/framework/src/{ => Framework}/Models/Markdown/Markdown.php (100%) rename packages/framework/src/{ => Framework}/Models/Markdown/MarkdownDocument.php (100%) rename packages/framework/src/{ => Framework}/Models/Navigation/DocumentationSidebar.php (100%) rename packages/framework/src/{ => Framework}/Models/Navigation/NavItem.php (100%) rename packages/framework/src/{ => Framework}/Models/Navigation/NavigationData.php (100%) rename packages/framework/src/{ => Framework}/Models/Navigation/NavigationMenu.php (100%) rename packages/framework/src/{ => Framework}/Models/Pages/BladePage.php (100%) rename packages/framework/src/{ => Framework}/Models/Pages/DocumentationPage.php (100%) rename packages/framework/src/{ => Framework}/Models/Pages/HtmlPage.php (100%) rename packages/framework/src/{ => Framework}/Models/Pages/MarkdownPage.php (100%) rename packages/framework/src/{ => Framework}/Models/Pages/MarkdownPost.php (100%) rename packages/framework/src/{ => Framework}/Models/Support/Author.php (100%) rename packages/framework/src/{ => Framework}/Models/Support/DateString.php (100%) rename packages/framework/src/{ => Framework}/Models/Support/File.php (100%) rename packages/framework/src/{ => Framework}/Models/Support/Image.php (100%) rename packages/framework/src/{ => Framework}/Models/Support/Route.php (100%) rename packages/framework/src/{ => Framework}/Models/Support/Site.php (100%) rename packages/framework/src/{ => Framework}/Models/Support/ValidationResult.php (100%) rename packages/framework/src/{ => Framework}/Modules/DataCollections/DataCollection.php (100%) rename packages/framework/src/{ => Framework}/Modules/DataCollections/DataCollectionServiceProvider.php (100%) rename packages/framework/src/{ => Framework}/Modules/DataCollections/Facades/MarkdownCollection.php (100%) rename packages/framework/src/{ => Framework}/Modules/Markdown/BladeDownProcessor.php (100%) rename packages/framework/src/{ => Framework}/Modules/Markdown/CodeblockFilepathProcessor.php (100%) rename packages/framework/src/{ => Framework}/Modules/Markdown/ShortcodeProcessor.php (100%) rename packages/framework/src/{ => Framework}/Modules/Markdown/Shortcodes/ColoredBlockquotes.php (100%) rename packages/framework/src/{ => Framework}/Modules/Metadata/GlobalMetadataBag.php (100%) rename packages/framework/src/{ => Framework}/Modules/Metadata/MetadataBag.php (100%) rename packages/framework/src/{ => Framework}/Modules/Metadata/MetadataElementContract.php (100%) rename packages/framework/src/{ => Framework}/Modules/Metadata/Models/LinkElement.php (100%) rename packages/framework/src/{ => Framework}/Modules/Metadata/Models/MetadataElement.php (100%) rename packages/framework/src/{ => Framework}/Modules/Metadata/Models/OpenGraphElement.php (100%) rename packages/framework/src/{ => Framework}/Modules/Metadata/PageMetadataBag.php (100%) rename packages/framework/src/{ => Framework}/Modules/README.md (100%) rename packages/framework/src/{ => Framework}/Services/AssetService.php (100%) rename packages/framework/src/{ => Framework}/Services/BuildService.php (100%) rename packages/framework/src/{ => Framework}/Services/BuildTaskService.php (100%) rename packages/framework/src/{ => Framework}/Services/ChecksumService.php (100%) rename packages/framework/src/{ => Framework}/Services/DiscoveryService.php (100%) rename packages/framework/src/{ => Framework}/Services/DocumentationSearchService.php (100%) rename packages/framework/src/{ => Framework}/Services/MarkdownService.php (100%) rename packages/framework/src/{ => Framework}/Services/RebuildService.php (100%) rename packages/framework/src/{ => Framework}/Services/RssFeedService.php (100%) rename packages/framework/src/{ => Framework}/Services/SemanticDocumentationArticle.php (100%) rename packages/framework/src/{ => Framework}/Services/SitemapService.php (100%) rename packages/framework/src/{ => Framework}/Services/ValidationService.php (100%) rename packages/framework/src/{ => Framework}/Services/YamlConfigurationService.php (100%) rename packages/framework/src/{ => Framework}/Views/Components/LinkComponent.php (100%) rename packages/framework/src/{ => Framework}/helpers.php (100%) diff --git a/packages/framework/src/Actions/BladeMatterParser.php b/packages/framework/src/Framework/Actions/BladeMatterParser.php similarity index 100% rename from packages/framework/src/Actions/BladeMatterParser.php rename to packages/framework/src/Framework/Actions/BladeMatterParser.php diff --git a/packages/framework/src/Actions/Constructors/FindsContentLengthForImageObject.php b/packages/framework/src/Framework/Actions/Constructors/FindsContentLengthForImageObject.php similarity index 100% rename from packages/framework/src/Actions/Constructors/FindsContentLengthForImageObject.php rename to packages/framework/src/Framework/Actions/Constructors/FindsContentLengthForImageObject.php diff --git a/packages/framework/src/Actions/Constructors/FindsNavigationDataForPage.php b/packages/framework/src/Framework/Actions/Constructors/FindsNavigationDataForPage.php similarity index 100% rename from packages/framework/src/Actions/Constructors/FindsNavigationDataForPage.php rename to packages/framework/src/Framework/Actions/Constructors/FindsNavigationDataForPage.php diff --git a/packages/framework/src/Actions/Constructors/FindsTitleForPage.php b/packages/framework/src/Framework/Actions/Constructors/FindsTitleForPage.php similarity index 100% rename from packages/framework/src/Actions/Constructors/FindsTitleForPage.php rename to packages/framework/src/Framework/Actions/Constructors/FindsTitleForPage.php diff --git a/packages/framework/src/Actions/ConvertsArrayToFrontMatter.php b/packages/framework/src/Framework/Actions/ConvertsArrayToFrontMatter.php similarity index 100% rename from packages/framework/src/Actions/ConvertsArrayToFrontMatter.php rename to packages/framework/src/Framework/Actions/ConvertsArrayToFrontMatter.php diff --git a/packages/framework/src/Actions/CreatesNewMarkdownPostFile.php b/packages/framework/src/Framework/Actions/CreatesNewMarkdownPostFile.php similarity index 100% rename from packages/framework/src/Actions/CreatesNewMarkdownPostFile.php rename to packages/framework/src/Framework/Actions/CreatesNewMarkdownPostFile.php diff --git a/packages/framework/src/Actions/CreatesNewPageSourceFile.php b/packages/framework/src/Framework/Actions/CreatesNewPageSourceFile.php similarity index 100% rename from packages/framework/src/Actions/CreatesNewPageSourceFile.php rename to packages/framework/src/Framework/Actions/CreatesNewPageSourceFile.php diff --git a/packages/framework/src/Actions/GeneratesSidebarTableOfContents.php b/packages/framework/src/Framework/Actions/GeneratesSidebarTableOfContents.php similarity index 100% rename from packages/framework/src/Actions/GeneratesSidebarTableOfContents.php rename to packages/framework/src/Framework/Actions/GeneratesSidebarTableOfContents.php diff --git a/packages/framework/src/Actions/MarkdownConverter.php b/packages/framework/src/Framework/Actions/MarkdownConverter.php similarity index 100% rename from packages/framework/src/Actions/MarkdownConverter.php rename to packages/framework/src/Framework/Actions/MarkdownConverter.php diff --git a/packages/framework/src/Actions/MarkdownFileParser.php b/packages/framework/src/Framework/Actions/MarkdownFileParser.php similarity index 100% rename from packages/framework/src/Actions/MarkdownFileParser.php rename to packages/framework/src/Framework/Actions/MarkdownFileParser.php diff --git a/packages/framework/src/Actions/PostBuildTasks/GenerateBuildManifest.php b/packages/framework/src/Framework/Actions/PostBuildTasks/GenerateBuildManifest.php similarity index 100% rename from packages/framework/src/Actions/PostBuildTasks/GenerateBuildManifest.php rename to packages/framework/src/Framework/Actions/PostBuildTasks/GenerateBuildManifest.php diff --git a/packages/framework/src/Actions/PostBuildTasks/GenerateRssFeed.php b/packages/framework/src/Framework/Actions/PostBuildTasks/GenerateRssFeed.php similarity index 100% rename from packages/framework/src/Actions/PostBuildTasks/GenerateRssFeed.php rename to packages/framework/src/Framework/Actions/PostBuildTasks/GenerateRssFeed.php diff --git a/packages/framework/src/Actions/PostBuildTasks/GenerateSearch.php b/packages/framework/src/Framework/Actions/PostBuildTasks/GenerateSearch.php similarity index 100% rename from packages/framework/src/Actions/PostBuildTasks/GenerateSearch.php rename to packages/framework/src/Framework/Actions/PostBuildTasks/GenerateSearch.php diff --git a/packages/framework/src/Actions/PostBuildTasks/GenerateSitemap.php b/packages/framework/src/Framework/Actions/PostBuildTasks/GenerateSitemap.php similarity index 100% rename from packages/framework/src/Actions/PostBuildTasks/GenerateSitemap.php rename to packages/framework/src/Framework/Actions/PostBuildTasks/GenerateSitemap.php diff --git a/packages/framework/src/Actions/PublishesHomepageView.php b/packages/framework/src/Framework/Actions/PublishesHomepageView.php similarity index 100% rename from packages/framework/src/Actions/PublishesHomepageView.php rename to packages/framework/src/Framework/Actions/PublishesHomepageView.php diff --git a/packages/framework/src/Actions/PublishesHydeViews.php b/packages/framework/src/Framework/Actions/PublishesHydeViews.php similarity index 100% rename from packages/framework/src/Actions/PublishesHydeViews.php rename to packages/framework/src/Framework/Actions/PublishesHydeViews.php diff --git a/packages/framework/src/Actions/SourceFileParser.php b/packages/framework/src/Framework/Actions/SourceFileParser.php similarity index 100% rename from packages/framework/src/Actions/SourceFileParser.php rename to packages/framework/src/Framework/Actions/SourceFileParser.php diff --git a/packages/framework/src/Actions/StaticPageBuilder.php b/packages/framework/src/Framework/Actions/StaticPageBuilder.php similarity index 100% rename from packages/framework/src/Actions/StaticPageBuilder.php rename to packages/framework/src/Framework/Actions/StaticPageBuilder.php diff --git a/packages/framework/src/Commands/HydeBuildRssFeedCommand.php b/packages/framework/src/Framework/Commands/HydeBuildRssFeedCommand.php similarity index 100% rename from packages/framework/src/Commands/HydeBuildRssFeedCommand.php rename to packages/framework/src/Framework/Commands/HydeBuildRssFeedCommand.php diff --git a/packages/framework/src/Commands/HydeBuildSearchCommand.php b/packages/framework/src/Framework/Commands/HydeBuildSearchCommand.php similarity index 100% rename from packages/framework/src/Commands/HydeBuildSearchCommand.php rename to packages/framework/src/Framework/Commands/HydeBuildSearchCommand.php diff --git a/packages/framework/src/Commands/HydeBuildSiteCommand.php b/packages/framework/src/Framework/Commands/HydeBuildSiteCommand.php similarity index 100% rename from packages/framework/src/Commands/HydeBuildSiteCommand.php rename to packages/framework/src/Framework/Commands/HydeBuildSiteCommand.php diff --git a/packages/framework/src/Commands/HydeBuildSitemapCommand.php b/packages/framework/src/Framework/Commands/HydeBuildSitemapCommand.php similarity index 100% rename from packages/framework/src/Commands/HydeBuildSitemapCommand.php rename to packages/framework/src/Framework/Commands/HydeBuildSitemapCommand.php diff --git a/packages/framework/src/Commands/HydeDebugCommand.php b/packages/framework/src/Framework/Commands/HydeDebugCommand.php similarity index 100% rename from packages/framework/src/Commands/HydeDebugCommand.php rename to packages/framework/src/Framework/Commands/HydeDebugCommand.php diff --git a/packages/framework/src/Commands/HydeMakePageCommand.php b/packages/framework/src/Framework/Commands/HydeMakePageCommand.php similarity index 100% rename from packages/framework/src/Commands/HydeMakePageCommand.php rename to packages/framework/src/Framework/Commands/HydeMakePageCommand.php diff --git a/packages/framework/src/Commands/HydeMakePostCommand.php b/packages/framework/src/Framework/Commands/HydeMakePostCommand.php similarity index 100% rename from packages/framework/src/Commands/HydeMakePostCommand.php rename to packages/framework/src/Framework/Commands/HydeMakePostCommand.php diff --git a/packages/framework/src/Commands/HydePackageDiscoverCommand.php b/packages/framework/src/Framework/Commands/HydePackageDiscoverCommand.php similarity index 100% rename from packages/framework/src/Commands/HydePackageDiscoverCommand.php rename to packages/framework/src/Framework/Commands/HydePackageDiscoverCommand.php diff --git a/packages/framework/src/Commands/HydePublishHomepageCommand.php b/packages/framework/src/Framework/Commands/HydePublishHomepageCommand.php similarity index 100% rename from packages/framework/src/Commands/HydePublishHomepageCommand.php rename to packages/framework/src/Framework/Commands/HydePublishHomepageCommand.php diff --git a/packages/framework/src/Commands/HydePublishViewsCommand.php b/packages/framework/src/Framework/Commands/HydePublishViewsCommand.php similarity index 100% rename from packages/framework/src/Commands/HydePublishViewsCommand.php rename to packages/framework/src/Framework/Commands/HydePublishViewsCommand.php diff --git a/packages/framework/src/Commands/HydeRebuildStaticSiteCommand.php b/packages/framework/src/Framework/Commands/HydeRebuildStaticSiteCommand.php similarity index 100% rename from packages/framework/src/Commands/HydeRebuildStaticSiteCommand.php rename to packages/framework/src/Framework/Commands/HydeRebuildStaticSiteCommand.php diff --git a/packages/framework/src/Commands/HydeRouteListCommand.php b/packages/framework/src/Framework/Commands/HydeRouteListCommand.php similarity index 100% rename from packages/framework/src/Commands/HydeRouteListCommand.php rename to packages/framework/src/Framework/Commands/HydeRouteListCommand.php diff --git a/packages/framework/src/Commands/HydeServeCommand.php b/packages/framework/src/Framework/Commands/HydeServeCommand.php similarity index 100% rename from packages/framework/src/Commands/HydeServeCommand.php rename to packages/framework/src/Framework/Commands/HydeServeCommand.php diff --git a/packages/framework/src/Commands/HydeUpdateConfigsCommand.php b/packages/framework/src/Framework/Commands/HydeUpdateConfigsCommand.php similarity index 100% rename from packages/framework/src/Commands/HydeUpdateConfigsCommand.php rename to packages/framework/src/Framework/Commands/HydeUpdateConfigsCommand.php diff --git a/packages/framework/src/Commands/HydeValidateCommand.php b/packages/framework/src/Framework/Commands/HydeValidateCommand.php similarity index 100% rename from packages/framework/src/Commands/HydeValidateCommand.php rename to packages/framework/src/Framework/Commands/HydeValidateCommand.php diff --git a/packages/framework/src/Concerns/AbstractBuildTask.php b/packages/framework/src/Framework/Concerns/AbstractBuildTask.php similarity index 100% rename from packages/framework/src/Concerns/AbstractBuildTask.php rename to packages/framework/src/Framework/Concerns/AbstractBuildTask.php diff --git a/packages/framework/src/Concerns/BaseMarkdownPage.php b/packages/framework/src/Framework/Concerns/BaseMarkdownPage.php similarity index 100% rename from packages/framework/src/Concerns/BaseMarkdownPage.php rename to packages/framework/src/Framework/Concerns/BaseMarkdownPage.php diff --git a/packages/framework/src/Concerns/HydePage.php b/packages/framework/src/Framework/Concerns/HydePage.php similarity index 100% rename from packages/framework/src/Concerns/HydePage.php rename to packages/framework/src/Framework/Concerns/HydePage.php diff --git a/packages/framework/src/Concerns/InteractsWithDirectories.php b/packages/framework/src/Framework/Concerns/InteractsWithDirectories.php similarity index 100% rename from packages/framework/src/Concerns/InteractsWithDirectories.php rename to packages/framework/src/Framework/Concerns/InteractsWithDirectories.php diff --git a/packages/framework/src/Concerns/Internal/ConstructsPageSchemas.php b/packages/framework/src/Framework/Concerns/Internal/ConstructsPageSchemas.php similarity index 100% rename from packages/framework/src/Concerns/Internal/ConstructsPageSchemas.php rename to packages/framework/src/Framework/Concerns/Internal/ConstructsPageSchemas.php diff --git a/packages/framework/src/Concerns/Internal/SetsUpMarkdownConverter.php b/packages/framework/src/Framework/Concerns/Internal/SetsUpMarkdownConverter.php similarity index 100% rename from packages/framework/src/Concerns/Internal/SetsUpMarkdownConverter.php rename to packages/framework/src/Framework/Concerns/Internal/SetsUpMarkdownConverter.php diff --git a/packages/framework/src/Concerns/JsonSerializesArrayable.php b/packages/framework/src/Framework/Concerns/JsonSerializesArrayable.php similarity index 100% rename from packages/framework/src/Concerns/JsonSerializesArrayable.php rename to packages/framework/src/Framework/Concerns/JsonSerializesArrayable.php diff --git a/packages/framework/src/Concerns/RegistersFileLocations.php b/packages/framework/src/Framework/Concerns/RegistersFileLocations.php similarity index 100% rename from packages/framework/src/Concerns/RegistersFileLocations.php rename to packages/framework/src/Framework/Concerns/RegistersFileLocations.php diff --git a/packages/framework/src/Concerns/ValidatesExistence.php b/packages/framework/src/Framework/Concerns/ValidatesExistence.php similarity index 100% rename from packages/framework/src/Concerns/ValidatesExistence.php rename to packages/framework/src/Framework/Concerns/ValidatesExistence.php diff --git a/packages/framework/src/Contracts/BuildTaskContract.php b/packages/framework/src/Framework/Contracts/BuildTaskContract.php similarity index 100% rename from packages/framework/src/Contracts/BuildTaskContract.php rename to packages/framework/src/Framework/Contracts/BuildTaskContract.php diff --git a/packages/framework/src/Contracts/CompilableContract.php b/packages/framework/src/Framework/Contracts/CompilableContract.php similarity index 100% rename from packages/framework/src/Contracts/CompilableContract.php rename to packages/framework/src/Framework/Contracts/CompilableContract.php diff --git a/packages/framework/src/Contracts/FrontMatter/BlogPostSchema.php b/packages/framework/src/Framework/Contracts/FrontMatter/BlogPostSchema.php similarity index 100% rename from packages/framework/src/Contracts/FrontMatter/BlogPostSchema.php rename to packages/framework/src/Framework/Contracts/FrontMatter/BlogPostSchema.php diff --git a/packages/framework/src/Contracts/FrontMatter/DocumentationPageSchema.php b/packages/framework/src/Framework/Contracts/FrontMatter/DocumentationPageSchema.php similarity index 100% rename from packages/framework/src/Contracts/FrontMatter/DocumentationPageSchema.php rename to packages/framework/src/Framework/Contracts/FrontMatter/DocumentationPageSchema.php diff --git a/packages/framework/src/Contracts/FrontMatter/PageSchema.php b/packages/framework/src/Framework/Contracts/FrontMatter/PageSchema.php similarity index 100% rename from packages/framework/src/Contracts/FrontMatter/PageSchema.php rename to packages/framework/src/Framework/Contracts/FrontMatter/PageSchema.php diff --git a/packages/framework/src/Contracts/FrontMatter/Support/FeaturedImageSchema.php b/packages/framework/src/Framework/Contracts/FrontMatter/Support/FeaturedImageSchema.php similarity index 100% rename from packages/framework/src/Contracts/FrontMatter/Support/FeaturedImageSchema.php rename to packages/framework/src/Framework/Contracts/FrontMatter/Support/FeaturedImageSchema.php diff --git a/packages/framework/src/Contracts/FrontMatter/Support/NavigationSchema.php b/packages/framework/src/Framework/Contracts/FrontMatter/Support/NavigationSchema.php similarity index 100% rename from packages/framework/src/Contracts/FrontMatter/Support/NavigationSchema.php rename to packages/framework/src/Framework/Contracts/FrontMatter/Support/NavigationSchema.php diff --git a/packages/framework/src/Contracts/MarkdownDocumentContract.php b/packages/framework/src/Framework/Contracts/MarkdownDocumentContract.php similarity index 100% rename from packages/framework/src/Contracts/MarkdownDocumentContract.php rename to packages/framework/src/Framework/Contracts/MarkdownDocumentContract.php diff --git a/packages/framework/src/Contracts/MarkdownPostProcessorContract.php b/packages/framework/src/Framework/Contracts/MarkdownPostProcessorContract.php similarity index 100% rename from packages/framework/src/Contracts/MarkdownPostProcessorContract.php rename to packages/framework/src/Framework/Contracts/MarkdownPostProcessorContract.php diff --git a/packages/framework/src/Contracts/MarkdownPreProcessorContract.php b/packages/framework/src/Framework/Contracts/MarkdownPreProcessorContract.php similarity index 100% rename from packages/framework/src/Contracts/MarkdownPreProcessorContract.php rename to packages/framework/src/Framework/Contracts/MarkdownPreProcessorContract.php diff --git a/packages/framework/src/Contracts/MarkdownShortcodeContract.php b/packages/framework/src/Framework/Contracts/MarkdownShortcodeContract.php similarity index 100% rename from packages/framework/src/Contracts/MarkdownShortcodeContract.php rename to packages/framework/src/Framework/Contracts/MarkdownShortcodeContract.php diff --git a/packages/framework/src/Exceptions/BaseUrlNotSetException.php b/packages/framework/src/Framework/Exceptions/BaseUrlNotSetException.php similarity index 100% rename from packages/framework/src/Exceptions/BaseUrlNotSetException.php rename to packages/framework/src/Framework/Exceptions/BaseUrlNotSetException.php diff --git a/packages/framework/src/Exceptions/FileConflictException.php b/packages/framework/src/Framework/Exceptions/FileConflictException.php similarity index 100% rename from packages/framework/src/Exceptions/FileConflictException.php rename to packages/framework/src/Framework/Exceptions/FileConflictException.php diff --git a/packages/framework/src/Exceptions/FileNotFoundException.php b/packages/framework/src/Framework/Exceptions/FileNotFoundException.php similarity index 100% rename from packages/framework/src/Exceptions/FileNotFoundException.php rename to packages/framework/src/Framework/Exceptions/FileNotFoundException.php diff --git a/packages/framework/src/Exceptions/RouteNotFoundException.php b/packages/framework/src/Framework/Exceptions/RouteNotFoundException.php similarity index 100% rename from packages/framework/src/Exceptions/RouteNotFoundException.php rename to packages/framework/src/Framework/Exceptions/RouteNotFoundException.php diff --git a/packages/framework/src/Exceptions/UnsupportedPageTypeException.php b/packages/framework/src/Framework/Exceptions/UnsupportedPageTypeException.php similarity index 100% rename from packages/framework/src/Exceptions/UnsupportedPageTypeException.php rename to packages/framework/src/Framework/Exceptions/UnsupportedPageTypeException.php diff --git a/packages/framework/src/Foundation/Application.php b/packages/framework/src/Framework/Foundation/Application.php similarity index 100% rename from packages/framework/src/Foundation/Application.php rename to packages/framework/src/Framework/Foundation/Application.php diff --git a/packages/framework/src/Foundation/Concerns/BaseFoundationCollection.php b/packages/framework/src/Framework/Foundation/Concerns/BaseFoundationCollection.php similarity index 100% rename from packages/framework/src/Foundation/Concerns/BaseFoundationCollection.php rename to packages/framework/src/Framework/Foundation/Concerns/BaseFoundationCollection.php diff --git a/packages/framework/src/Foundation/Concerns/ForwardsFilesystem.php b/packages/framework/src/Framework/Foundation/Concerns/ForwardsFilesystem.php similarity index 100% rename from packages/framework/src/Foundation/Concerns/ForwardsFilesystem.php rename to packages/framework/src/Framework/Foundation/Concerns/ForwardsFilesystem.php diff --git a/packages/framework/src/Foundation/Concerns/ForwardsHyperlinks.php b/packages/framework/src/Framework/Foundation/Concerns/ForwardsHyperlinks.php similarity index 100% rename from packages/framework/src/Foundation/Concerns/ForwardsHyperlinks.php rename to packages/framework/src/Framework/Foundation/Concerns/ForwardsHyperlinks.php diff --git a/packages/framework/src/Foundation/Concerns/HandlesFoundationCollections.php b/packages/framework/src/Framework/Foundation/Concerns/HandlesFoundationCollections.php similarity index 100% rename from packages/framework/src/Foundation/Concerns/HandlesFoundationCollections.php rename to packages/framework/src/Framework/Foundation/Concerns/HandlesFoundationCollections.php diff --git a/packages/framework/src/Foundation/Concerns/ImplementsStringHelpers.php b/packages/framework/src/Framework/Foundation/Concerns/ImplementsStringHelpers.php similarity index 100% rename from packages/framework/src/Foundation/Concerns/ImplementsStringHelpers.php rename to packages/framework/src/Framework/Foundation/Concerns/ImplementsStringHelpers.php diff --git a/packages/framework/src/Foundation/Concerns/ManagesHydeKernel.php b/packages/framework/src/Framework/Foundation/Concerns/ManagesHydeKernel.php similarity index 100% rename from packages/framework/src/Foundation/Concerns/ManagesHydeKernel.php rename to packages/framework/src/Framework/Foundation/Concerns/ManagesHydeKernel.php diff --git a/packages/framework/src/Foundation/Concerns/ManagesViewData.php b/packages/framework/src/Framework/Foundation/Concerns/ManagesViewData.php similarity index 100% rename from packages/framework/src/Foundation/Concerns/ManagesViewData.php rename to packages/framework/src/Framework/Foundation/Concerns/ManagesViewData.php diff --git a/packages/framework/src/Foundation/FileCollection.php b/packages/framework/src/Framework/Foundation/FileCollection.php similarity index 100% rename from packages/framework/src/Foundation/FileCollection.php rename to packages/framework/src/Framework/Foundation/FileCollection.php diff --git a/packages/framework/src/Foundation/Filesystem.php b/packages/framework/src/Framework/Foundation/Filesystem.php similarity index 100% rename from packages/framework/src/Foundation/Filesystem.php rename to packages/framework/src/Framework/Foundation/Filesystem.php diff --git a/packages/framework/src/Foundation/Hyperlinks.php b/packages/framework/src/Framework/Foundation/Hyperlinks.php similarity index 100% rename from packages/framework/src/Foundation/Hyperlinks.php rename to packages/framework/src/Framework/Foundation/Hyperlinks.php diff --git a/packages/framework/src/Foundation/PageCollection.php b/packages/framework/src/Framework/Foundation/PageCollection.php similarity index 100% rename from packages/framework/src/Foundation/PageCollection.php rename to packages/framework/src/Framework/Foundation/PageCollection.php diff --git a/packages/framework/src/Foundation/RouteCollection.php b/packages/framework/src/Framework/Foundation/RouteCollection.php similarity index 100% rename from packages/framework/src/Foundation/RouteCollection.php rename to packages/framework/src/Framework/Foundation/RouteCollection.php diff --git a/packages/framework/src/Helpers/Asset.php b/packages/framework/src/Framework/Helpers/Asset.php similarity index 100% rename from packages/framework/src/Helpers/Asset.php rename to packages/framework/src/Framework/Helpers/Asset.php diff --git a/packages/framework/src/Helpers/Features.php b/packages/framework/src/Framework/Helpers/Features.php similarity index 100% rename from packages/framework/src/Helpers/Features.php rename to packages/framework/src/Framework/Helpers/Features.php diff --git a/packages/framework/src/Helpers/Includes.php b/packages/framework/src/Framework/Helpers/Includes.php similarity index 100% rename from packages/framework/src/Helpers/Includes.php rename to packages/framework/src/Framework/Helpers/Includes.php diff --git a/packages/framework/src/Helpers/Meta.php b/packages/framework/src/Framework/Helpers/Meta.php similarity index 100% rename from packages/framework/src/Helpers/Meta.php rename to packages/framework/src/Framework/Helpers/Meta.php diff --git a/packages/framework/src/Helpers/Redirect.php b/packages/framework/src/Framework/Helpers/Redirect.php similarity index 100% rename from packages/framework/src/Helpers/Redirect.php rename to packages/framework/src/Framework/Helpers/Redirect.php diff --git a/packages/framework/src/Hyde.php b/packages/framework/src/Framework/Hyde.php similarity index 100% rename from packages/framework/src/Hyde.php rename to packages/framework/src/Framework/Hyde.php diff --git a/packages/framework/src/HydeKernel.php b/packages/framework/src/Framework/HydeKernel.php similarity index 100% rename from packages/framework/src/HydeKernel.php rename to packages/framework/src/Framework/HydeKernel.php diff --git a/packages/framework/src/HydeServiceProvider.php b/packages/framework/src/Framework/HydeServiceProvider.php similarity index 100% rename from packages/framework/src/HydeServiceProvider.php rename to packages/framework/src/Framework/HydeServiceProvider.php diff --git a/packages/framework/src/Models/Markdown/FrontMatter.php b/packages/framework/src/Framework/Models/Markdown/FrontMatter.php similarity index 100% rename from packages/framework/src/Models/Markdown/FrontMatter.php rename to packages/framework/src/Framework/Models/Markdown/FrontMatter.php diff --git a/packages/framework/src/Models/Markdown/Markdown.php b/packages/framework/src/Framework/Models/Markdown/Markdown.php similarity index 100% rename from packages/framework/src/Models/Markdown/Markdown.php rename to packages/framework/src/Framework/Models/Markdown/Markdown.php diff --git a/packages/framework/src/Models/Markdown/MarkdownDocument.php b/packages/framework/src/Framework/Models/Markdown/MarkdownDocument.php similarity index 100% rename from packages/framework/src/Models/Markdown/MarkdownDocument.php rename to packages/framework/src/Framework/Models/Markdown/MarkdownDocument.php diff --git a/packages/framework/src/Models/Navigation/DocumentationSidebar.php b/packages/framework/src/Framework/Models/Navigation/DocumentationSidebar.php similarity index 100% rename from packages/framework/src/Models/Navigation/DocumentationSidebar.php rename to packages/framework/src/Framework/Models/Navigation/DocumentationSidebar.php diff --git a/packages/framework/src/Models/Navigation/NavItem.php b/packages/framework/src/Framework/Models/Navigation/NavItem.php similarity index 100% rename from packages/framework/src/Models/Navigation/NavItem.php rename to packages/framework/src/Framework/Models/Navigation/NavItem.php diff --git a/packages/framework/src/Models/Navigation/NavigationData.php b/packages/framework/src/Framework/Models/Navigation/NavigationData.php similarity index 100% rename from packages/framework/src/Models/Navigation/NavigationData.php rename to packages/framework/src/Framework/Models/Navigation/NavigationData.php diff --git a/packages/framework/src/Models/Navigation/NavigationMenu.php b/packages/framework/src/Framework/Models/Navigation/NavigationMenu.php similarity index 100% rename from packages/framework/src/Models/Navigation/NavigationMenu.php rename to packages/framework/src/Framework/Models/Navigation/NavigationMenu.php diff --git a/packages/framework/src/Models/Pages/BladePage.php b/packages/framework/src/Framework/Models/Pages/BladePage.php similarity index 100% rename from packages/framework/src/Models/Pages/BladePage.php rename to packages/framework/src/Framework/Models/Pages/BladePage.php diff --git a/packages/framework/src/Models/Pages/DocumentationPage.php b/packages/framework/src/Framework/Models/Pages/DocumentationPage.php similarity index 100% rename from packages/framework/src/Models/Pages/DocumentationPage.php rename to packages/framework/src/Framework/Models/Pages/DocumentationPage.php diff --git a/packages/framework/src/Models/Pages/HtmlPage.php b/packages/framework/src/Framework/Models/Pages/HtmlPage.php similarity index 100% rename from packages/framework/src/Models/Pages/HtmlPage.php rename to packages/framework/src/Framework/Models/Pages/HtmlPage.php diff --git a/packages/framework/src/Models/Pages/MarkdownPage.php b/packages/framework/src/Framework/Models/Pages/MarkdownPage.php similarity index 100% rename from packages/framework/src/Models/Pages/MarkdownPage.php rename to packages/framework/src/Framework/Models/Pages/MarkdownPage.php diff --git a/packages/framework/src/Models/Pages/MarkdownPost.php b/packages/framework/src/Framework/Models/Pages/MarkdownPost.php similarity index 100% rename from packages/framework/src/Models/Pages/MarkdownPost.php rename to packages/framework/src/Framework/Models/Pages/MarkdownPost.php diff --git a/packages/framework/src/Models/Support/Author.php b/packages/framework/src/Framework/Models/Support/Author.php similarity index 100% rename from packages/framework/src/Models/Support/Author.php rename to packages/framework/src/Framework/Models/Support/Author.php diff --git a/packages/framework/src/Models/Support/DateString.php b/packages/framework/src/Framework/Models/Support/DateString.php similarity index 100% rename from packages/framework/src/Models/Support/DateString.php rename to packages/framework/src/Framework/Models/Support/DateString.php diff --git a/packages/framework/src/Models/Support/File.php b/packages/framework/src/Framework/Models/Support/File.php similarity index 100% rename from packages/framework/src/Models/Support/File.php rename to packages/framework/src/Framework/Models/Support/File.php diff --git a/packages/framework/src/Models/Support/Image.php b/packages/framework/src/Framework/Models/Support/Image.php similarity index 100% rename from packages/framework/src/Models/Support/Image.php rename to packages/framework/src/Framework/Models/Support/Image.php diff --git a/packages/framework/src/Models/Support/Route.php b/packages/framework/src/Framework/Models/Support/Route.php similarity index 100% rename from packages/framework/src/Models/Support/Route.php rename to packages/framework/src/Framework/Models/Support/Route.php diff --git a/packages/framework/src/Models/Support/Site.php b/packages/framework/src/Framework/Models/Support/Site.php similarity index 100% rename from packages/framework/src/Models/Support/Site.php rename to packages/framework/src/Framework/Models/Support/Site.php diff --git a/packages/framework/src/Models/Support/ValidationResult.php b/packages/framework/src/Framework/Models/Support/ValidationResult.php similarity index 100% rename from packages/framework/src/Models/Support/ValidationResult.php rename to packages/framework/src/Framework/Models/Support/ValidationResult.php diff --git a/packages/framework/src/Modules/DataCollections/DataCollection.php b/packages/framework/src/Framework/Modules/DataCollections/DataCollection.php similarity index 100% rename from packages/framework/src/Modules/DataCollections/DataCollection.php rename to packages/framework/src/Framework/Modules/DataCollections/DataCollection.php diff --git a/packages/framework/src/Modules/DataCollections/DataCollectionServiceProvider.php b/packages/framework/src/Framework/Modules/DataCollections/DataCollectionServiceProvider.php similarity index 100% rename from packages/framework/src/Modules/DataCollections/DataCollectionServiceProvider.php rename to packages/framework/src/Framework/Modules/DataCollections/DataCollectionServiceProvider.php diff --git a/packages/framework/src/Modules/DataCollections/Facades/MarkdownCollection.php b/packages/framework/src/Framework/Modules/DataCollections/Facades/MarkdownCollection.php similarity index 100% rename from packages/framework/src/Modules/DataCollections/Facades/MarkdownCollection.php rename to packages/framework/src/Framework/Modules/DataCollections/Facades/MarkdownCollection.php diff --git a/packages/framework/src/Modules/Markdown/BladeDownProcessor.php b/packages/framework/src/Framework/Modules/Markdown/BladeDownProcessor.php similarity index 100% rename from packages/framework/src/Modules/Markdown/BladeDownProcessor.php rename to packages/framework/src/Framework/Modules/Markdown/BladeDownProcessor.php diff --git a/packages/framework/src/Modules/Markdown/CodeblockFilepathProcessor.php b/packages/framework/src/Framework/Modules/Markdown/CodeblockFilepathProcessor.php similarity index 100% rename from packages/framework/src/Modules/Markdown/CodeblockFilepathProcessor.php rename to packages/framework/src/Framework/Modules/Markdown/CodeblockFilepathProcessor.php diff --git a/packages/framework/src/Modules/Markdown/ShortcodeProcessor.php b/packages/framework/src/Framework/Modules/Markdown/ShortcodeProcessor.php similarity index 100% rename from packages/framework/src/Modules/Markdown/ShortcodeProcessor.php rename to packages/framework/src/Framework/Modules/Markdown/ShortcodeProcessor.php diff --git a/packages/framework/src/Modules/Markdown/Shortcodes/ColoredBlockquotes.php b/packages/framework/src/Framework/Modules/Markdown/Shortcodes/ColoredBlockquotes.php similarity index 100% rename from packages/framework/src/Modules/Markdown/Shortcodes/ColoredBlockquotes.php rename to packages/framework/src/Framework/Modules/Markdown/Shortcodes/ColoredBlockquotes.php diff --git a/packages/framework/src/Modules/Metadata/GlobalMetadataBag.php b/packages/framework/src/Framework/Modules/Metadata/GlobalMetadataBag.php similarity index 100% rename from packages/framework/src/Modules/Metadata/GlobalMetadataBag.php rename to packages/framework/src/Framework/Modules/Metadata/GlobalMetadataBag.php diff --git a/packages/framework/src/Modules/Metadata/MetadataBag.php b/packages/framework/src/Framework/Modules/Metadata/MetadataBag.php similarity index 100% rename from packages/framework/src/Modules/Metadata/MetadataBag.php rename to packages/framework/src/Framework/Modules/Metadata/MetadataBag.php diff --git a/packages/framework/src/Modules/Metadata/MetadataElementContract.php b/packages/framework/src/Framework/Modules/Metadata/MetadataElementContract.php similarity index 100% rename from packages/framework/src/Modules/Metadata/MetadataElementContract.php rename to packages/framework/src/Framework/Modules/Metadata/MetadataElementContract.php diff --git a/packages/framework/src/Modules/Metadata/Models/LinkElement.php b/packages/framework/src/Framework/Modules/Metadata/Models/LinkElement.php similarity index 100% rename from packages/framework/src/Modules/Metadata/Models/LinkElement.php rename to packages/framework/src/Framework/Modules/Metadata/Models/LinkElement.php diff --git a/packages/framework/src/Modules/Metadata/Models/MetadataElement.php b/packages/framework/src/Framework/Modules/Metadata/Models/MetadataElement.php similarity index 100% rename from packages/framework/src/Modules/Metadata/Models/MetadataElement.php rename to packages/framework/src/Framework/Modules/Metadata/Models/MetadataElement.php diff --git a/packages/framework/src/Modules/Metadata/Models/OpenGraphElement.php b/packages/framework/src/Framework/Modules/Metadata/Models/OpenGraphElement.php similarity index 100% rename from packages/framework/src/Modules/Metadata/Models/OpenGraphElement.php rename to packages/framework/src/Framework/Modules/Metadata/Models/OpenGraphElement.php diff --git a/packages/framework/src/Modules/Metadata/PageMetadataBag.php b/packages/framework/src/Framework/Modules/Metadata/PageMetadataBag.php similarity index 100% rename from packages/framework/src/Modules/Metadata/PageMetadataBag.php rename to packages/framework/src/Framework/Modules/Metadata/PageMetadataBag.php diff --git a/packages/framework/src/Modules/README.md b/packages/framework/src/Framework/Modules/README.md similarity index 100% rename from packages/framework/src/Modules/README.md rename to packages/framework/src/Framework/Modules/README.md diff --git a/packages/framework/src/Services/AssetService.php b/packages/framework/src/Framework/Services/AssetService.php similarity index 100% rename from packages/framework/src/Services/AssetService.php rename to packages/framework/src/Framework/Services/AssetService.php diff --git a/packages/framework/src/Services/BuildService.php b/packages/framework/src/Framework/Services/BuildService.php similarity index 100% rename from packages/framework/src/Services/BuildService.php rename to packages/framework/src/Framework/Services/BuildService.php diff --git a/packages/framework/src/Services/BuildTaskService.php b/packages/framework/src/Framework/Services/BuildTaskService.php similarity index 100% rename from packages/framework/src/Services/BuildTaskService.php rename to packages/framework/src/Framework/Services/BuildTaskService.php diff --git a/packages/framework/src/Services/ChecksumService.php b/packages/framework/src/Framework/Services/ChecksumService.php similarity index 100% rename from packages/framework/src/Services/ChecksumService.php rename to packages/framework/src/Framework/Services/ChecksumService.php diff --git a/packages/framework/src/Services/DiscoveryService.php b/packages/framework/src/Framework/Services/DiscoveryService.php similarity index 100% rename from packages/framework/src/Services/DiscoveryService.php rename to packages/framework/src/Framework/Services/DiscoveryService.php diff --git a/packages/framework/src/Services/DocumentationSearchService.php b/packages/framework/src/Framework/Services/DocumentationSearchService.php similarity index 100% rename from packages/framework/src/Services/DocumentationSearchService.php rename to packages/framework/src/Framework/Services/DocumentationSearchService.php diff --git a/packages/framework/src/Services/MarkdownService.php b/packages/framework/src/Framework/Services/MarkdownService.php similarity index 100% rename from packages/framework/src/Services/MarkdownService.php rename to packages/framework/src/Framework/Services/MarkdownService.php diff --git a/packages/framework/src/Services/RebuildService.php b/packages/framework/src/Framework/Services/RebuildService.php similarity index 100% rename from packages/framework/src/Services/RebuildService.php rename to packages/framework/src/Framework/Services/RebuildService.php diff --git a/packages/framework/src/Services/RssFeedService.php b/packages/framework/src/Framework/Services/RssFeedService.php similarity index 100% rename from packages/framework/src/Services/RssFeedService.php rename to packages/framework/src/Framework/Services/RssFeedService.php diff --git a/packages/framework/src/Services/SemanticDocumentationArticle.php b/packages/framework/src/Framework/Services/SemanticDocumentationArticle.php similarity index 100% rename from packages/framework/src/Services/SemanticDocumentationArticle.php rename to packages/framework/src/Framework/Services/SemanticDocumentationArticle.php diff --git a/packages/framework/src/Services/SitemapService.php b/packages/framework/src/Framework/Services/SitemapService.php similarity index 100% rename from packages/framework/src/Services/SitemapService.php rename to packages/framework/src/Framework/Services/SitemapService.php diff --git a/packages/framework/src/Services/ValidationService.php b/packages/framework/src/Framework/Services/ValidationService.php similarity index 100% rename from packages/framework/src/Services/ValidationService.php rename to packages/framework/src/Framework/Services/ValidationService.php diff --git a/packages/framework/src/Services/YamlConfigurationService.php b/packages/framework/src/Framework/Services/YamlConfigurationService.php similarity index 100% rename from packages/framework/src/Services/YamlConfigurationService.php rename to packages/framework/src/Framework/Services/YamlConfigurationService.php diff --git a/packages/framework/src/Views/Components/LinkComponent.php b/packages/framework/src/Framework/Views/Components/LinkComponent.php similarity index 100% rename from packages/framework/src/Views/Components/LinkComponent.php rename to packages/framework/src/Framework/Views/Components/LinkComponent.php diff --git a/packages/framework/src/helpers.php b/packages/framework/src/Framework/helpers.php similarity index 100% rename from packages/framework/src/helpers.php rename to packages/framework/src/Framework/helpers.php From 4050b5b8889c507bf104ba29ff53a2dd9741761c Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 18:47:48 +0200 Subject: [PATCH 002/768] Update namespace mapping --- packages/framework/composer.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/framework/composer.json b/packages/framework/composer.json index e2a637bd149..01cd127ead2 100644 --- a/packages/framework/composer.json +++ b/packages/framework/composer.json @@ -4,10 +4,10 @@ "license": "MIT", "autoload": { "psr-4": { - "Hyde\\Framework\\": "src/" + "Hyde\\": "src/" }, "files": [ - "src/helpers.php" + "src/Framework/helpers.php" ] }, "autoload-dev": { From 089abf7d3bd8d57252b767d75f5c63f8bfa70d46 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 18:54:50 +0200 Subject: [PATCH 003/768] Update composer.lock --- composer.lock | 96 +++++++++++++++++++++++++-------------------------- 1 file changed, 48 insertions(+), 48 deletions(-) diff --git a/composer.lock b/composer.lock index 3f334fc890a..62617ccfa8a 100644 --- a/composer.lock +++ b/composer.lock @@ -707,16 +707,16 @@ }, { "name": "guzzlehttp/psr7", - "version": "2.4.1", + "version": "2.4.3", "source": { "type": "git", "url": "https://github.com/guzzle/psr7.git", - "reference": "69568e4293f4fa993f3b0e51c9723e1e17c41379" + "reference": "67c26b443f348a51926030c83481b85718457d3d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/psr7/zipball/69568e4293f4fa993f3b0e51c9723e1e17c41379", - "reference": "69568e4293f4fa993f3b0e51c9723e1e17c41379", + "url": "https://api.github.com/repos/guzzle/psr7/zipball/67c26b443f348a51926030c83481b85718457d3d", + "reference": "67c26b443f348a51926030c83481b85718457d3d", "shasum": "" }, "require": { @@ -806,7 +806,7 @@ ], "support": { "issues": "https://github.com/guzzle/psr7/issues", - "source": "https://github.com/guzzle/psr7/tree/2.4.1" + "source": "https://github.com/guzzle/psr7/tree/2.4.3" }, "funding": [ { @@ -822,7 +822,7 @@ "type": "tidelift" } ], - "time": "2022-08-28T14:45:39+00:00" + "time": "2022-10-26T14:07:24+00:00" }, { "name": "hyde/framework", @@ -830,7 +830,7 @@ "dist": { "type": "path", "url": "./packages/framework", - "reference": "d94d45d9d9ccbb6948656eee2c15e60dc02f437b" + "reference": "322dce9cf80a72175eb027dbc9d151accabcb42c" }, "require": { "illuminate/support": "^9.5", @@ -849,10 +849,10 @@ "type": "library", "autoload": { "psr-4": { - "Hyde\\Framework\\": "src/" + "Hyde\\": "src/" }, "files": [ - "src/helpers.php" + "src/Framework/helpers.php" ] }, "autoload-dev": { @@ -876,7 +876,7 @@ }, { "name": "illuminate/bus", - "version": "v9.36.4", + "version": "v9.37.0", "source": { "type": "git", "url": "https://github.com/illuminate/bus.git", @@ -929,7 +929,7 @@ }, { "name": "illuminate/cache", - "version": "v9.36.4", + "version": "v9.37.0", "source": { "type": "git", "url": "https://github.com/illuminate/cache.git", @@ -989,7 +989,7 @@ }, { "name": "illuminate/collections", - "version": "v9.36.4", + "version": "v9.37.0", "source": { "type": "git", "url": "https://github.com/illuminate/collections.git", @@ -1044,7 +1044,7 @@ }, { "name": "illuminate/conditionable", - "version": "v9.36.4", + "version": "v9.37.0", "source": { "type": "git", "url": "https://github.com/illuminate/conditionable.git", @@ -1090,7 +1090,7 @@ }, { "name": "illuminate/config", - "version": "v9.36.4", + "version": "v9.37.0", "source": { "type": "git", "url": "https://github.com/illuminate/config.git", @@ -1138,7 +1138,7 @@ }, { "name": "illuminate/console", - "version": "v9.36.4", + "version": "v9.37.0", "source": { "type": "git", "url": "https://github.com/illuminate/console.git", @@ -1200,7 +1200,7 @@ }, { "name": "illuminate/container", - "version": "v9.36.4", + "version": "v9.37.0", "source": { "type": "git", "url": "https://github.com/illuminate/container.git", @@ -1251,7 +1251,7 @@ }, { "name": "illuminate/contracts", - "version": "v9.36.4", + "version": "v9.37.0", "source": { "type": "git", "url": "https://github.com/illuminate/contracts.git", @@ -1299,7 +1299,7 @@ }, { "name": "illuminate/events", - "version": "v9.36.4", + "version": "v9.37.0", "source": { "type": "git", "url": "https://github.com/illuminate/events.git", @@ -1354,16 +1354,16 @@ }, { "name": "illuminate/filesystem", - "version": "v9.36.4", + "version": "v9.37.0", "source": { "type": "git", "url": "https://github.com/illuminate/filesystem.git", - "reference": "bdd396ccfe64a3dabe55cc06acf5971a027b7af5" + "reference": "05fdbbb60fa0bb17209d43ce231aa0a0bdf5465d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/illuminate/filesystem/zipball/bdd396ccfe64a3dabe55cc06acf5971a027b7af5", - "reference": "bdd396ccfe64a3dabe55cc06acf5971a027b7af5", + "url": "https://api.github.com/repos/illuminate/filesystem/zipball/05fdbbb60fa0bb17209d43ce231aa0a0bdf5465d", + "reference": "05fdbbb60fa0bb17209d43ce231aa0a0bdf5465d", "shasum": "" }, "require": { @@ -1412,20 +1412,20 @@ "issues": "https://github.com/laravel/framework/issues", "source": "https://github.com/laravel/framework" }, - "time": "2022-10-19T19:17:03+00:00" + "time": "2022-10-24T08:47:15+00:00" }, { "name": "illuminate/http", - "version": "v9.36.4", + "version": "v9.37.0", "source": { "type": "git", "url": "https://github.com/illuminate/http.git", - "reference": "3b9b03794016b3b8574d75d89936fad114ac13ff" + "reference": "211d9d77707adc1773ead9dba30537ad571c3c8e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/illuminate/http/zipball/3b9b03794016b3b8574d75d89936fad114ac13ff", - "reference": "3b9b03794016b3b8574d75d89936fad114ac13ff", + "url": "https://api.github.com/repos/illuminate/http/zipball/211d9d77707adc1773ead9dba30537ad571c3c8e", + "reference": "211d9d77707adc1773ead9dba30537ad571c3c8e", "shasum": "" }, "require": { @@ -1471,11 +1471,11 @@ "issues": "https://github.com/laravel/framework/issues", "source": "https://github.com/laravel/framework" }, - "time": "2022-10-20T13:48:43+00:00" + "time": "2022-10-24T13:29:55+00:00" }, { "name": "illuminate/macroable", - "version": "v9.36.4", + "version": "v9.37.0", "source": { "type": "git", "url": "https://github.com/illuminate/macroable.git", @@ -1521,7 +1521,7 @@ }, { "name": "illuminate/pipeline", - "version": "v9.36.4", + "version": "v9.37.0", "source": { "type": "git", "url": "https://github.com/illuminate/pipeline.git", @@ -1569,7 +1569,7 @@ }, { "name": "illuminate/session", - "version": "v9.36.4", + "version": "v9.37.0", "source": { "type": "git", "url": "https://github.com/illuminate/session.git", @@ -1625,16 +1625,16 @@ }, { "name": "illuminate/support", - "version": "v9.36.4", + "version": "v9.37.0", "source": { "type": "git", "url": "https://github.com/illuminate/support.git", - "reference": "9cb95dbb30af8ee2fba58e732c0c472f7f77ade6" + "reference": "f194a3b1435ed4f2542d127efb8652c7d41980ea" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/illuminate/support/zipball/9cb95dbb30af8ee2fba58e732c0c472f7f77ade6", - "reference": "9cb95dbb30af8ee2fba58e732c0c472f7f77ade6", + "url": "https://api.github.com/repos/illuminate/support/zipball/f194a3b1435ed4f2542d127efb8652c7d41980ea", + "reference": "f194a3b1435ed4f2542d127efb8652c7d41980ea", "shasum": "" }, "require": { @@ -1691,20 +1691,20 @@ "issues": "https://github.com/laravel/framework/issues", "source": "https://github.com/laravel/framework" }, - "time": "2022-10-20T13:35:15+00:00" + "time": "2022-10-24T09:54:34+00:00" }, { "name": "illuminate/testing", - "version": "v9.36.4", + "version": "v9.37.0", "source": { "type": "git", "url": "https://github.com/illuminate/testing.git", - "reference": "8f4458aab2539496e411eb8bdf5cc8bfc60beec4" + "reference": "86e6618722fefa1059fb32518268199e6f267782" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/illuminate/testing/zipball/8f4458aab2539496e411eb8bdf5cc8bfc60beec4", - "reference": "8f4458aab2539496e411eb8bdf5cc8bfc60beec4", + "url": "https://api.github.com/repos/illuminate/testing/zipball/86e6618722fefa1059fb32518268199e6f267782", + "reference": "86e6618722fefa1059fb32518268199e6f267782", "shasum": "" }, "require": { @@ -1749,11 +1749,11 @@ "issues": "https://github.com/laravel/framework/issues", "source": "https://github.com/laravel/framework" }, - "time": "2022-10-17T13:59:30+00:00" + "time": "2022-10-25T13:12:24+00:00" }, { "name": "illuminate/view", - "version": "v9.36.4", + "version": "v9.37.0", "source": { "type": "git", "url": "https://github.com/illuminate/view.git", @@ -2202,16 +2202,16 @@ }, { "name": "league/flysystem", - "version": "3.10.1", + "version": "3.10.2", "source": { "type": "git", "url": "https://github.com/thephpleague/flysystem.git", - "reference": "9857d7208a94fc63c7bf09caf223280e59ac7274" + "reference": "b9bd194b016114d6ff6765c09d40c7d427e4e3f6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/thephpleague/flysystem/zipball/9857d7208a94fc63c7bf09caf223280e59ac7274", - "reference": "9857d7208a94fc63c7bf09caf223280e59ac7274", + "url": "https://api.github.com/repos/thephpleague/flysystem/zipball/b9bd194b016114d6ff6765c09d40c7d427e4e3f6", + "reference": "b9bd194b016114d6ff6765c09d40c7d427e4e3f6", "shasum": "" }, "require": { @@ -2273,7 +2273,7 @@ ], "support": { "issues": "https://github.com/thephpleague/flysystem/issues", - "source": "https://github.com/thephpleague/flysystem/tree/3.10.1" + "source": "https://github.com/thephpleague/flysystem/tree/3.10.2" }, "funding": [ { @@ -2289,7 +2289,7 @@ "type": "tidelift" } ], - "time": "2022-10-21T18:57:47+00:00" + "time": "2022-10-25T07:01:47+00:00" }, { "name": "league/mime-type-detection", From e08e6e999deb8e43bb4f8f186585fa3db4cfddc6 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 19:05:26 +0200 Subject: [PATCH 004/768] Update sources --- .idea/develop.iml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.idea/develop.iml b/.idea/develop.iml index 5fc0fdeda3f..f3fc5e568d0 100644 --- a/.idea/develop.iml +++ b/.idea/develop.iml @@ -3,7 +3,7 @@ - + From 36deeade7f386559a06c2243bff2a2aac79f6709 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 19:06:19 +0200 Subject: [PATCH 005/768] Move main Hyde facade to root Hyde namespace --- config/app.php | 4 ++-- config/hyde.php | 2 +- packages/framework/config/hyde.php | 2 +- .../framework/src/Framework/Actions/BladeMatterParser.php | 2 +- .../Actions/Constructors/FindsContentLengthForImageObject.php | 2 +- .../src/Framework/Actions/Constructors/FindsTitleForPage.php | 2 +- .../src/Framework/Actions/CreatesNewMarkdownPostFile.php | 2 +- .../src/Framework/Actions/CreatesNewPageSourceFile.php | 2 +- .../framework/src/Framework/Actions/MarkdownFileParser.php | 2 +- .../Actions/PostBuildTasks/GenerateBuildManifest.php | 2 +- .../src/Framework/Actions/PostBuildTasks/GenerateRssFeed.php | 2 +- .../src/Framework/Actions/PostBuildTasks/GenerateSitemap.php | 2 +- .../framework/src/Framework/Actions/PublishesHomepageView.php | 2 +- .../framework/src/Framework/Actions/PublishesHydeViews.php | 2 +- .../framework/src/Framework/Actions/StaticPageBuilder.php | 2 +- .../framework/src/Framework/Commands/HydeBuildSiteCommand.php | 2 +- .../framework/src/Framework/Commands/HydeDebugCommand.php | 2 +- .../src/Framework/Commands/HydePackageDiscoverCommand.php | 2 +- .../src/Framework/Commands/HydePublishHomepageCommand.php | 2 +- .../src/Framework/Commands/HydePublishViewsCommand.php | 2 +- .../src/Framework/Commands/HydeRebuildStaticSiteCommand.php | 2 +- .../framework/src/Framework/Commands/HydeRouteListCommand.php | 2 +- .../framework/src/Framework/Commands/HydeServeCommand.php | 2 +- .../src/Framework/Commands/HydeUpdateConfigsCommand.php | 2 +- .../framework/src/Framework/Concerns/AbstractBuildTask.php | 2 +- .../framework/src/Framework/Concerns/BaseMarkdownPage.php | 2 +- packages/framework/src/Framework/Concerns/HydePage.php | 2 +- .../src/Framework/Concerns/Internal/ConstructsPageSchemas.php | 2 +- .../framework/src/Framework/Concerns/ValidatesExistence.php | 2 +- packages/framework/src/Framework/Foundation/Filesystem.php | 2 +- packages/framework/src/Framework/Helpers/Features.php | 2 +- packages/framework/src/Framework/Helpers/Includes.php | 2 +- packages/framework/src/Framework/Helpers/Redirect.php | 2 +- packages/framework/src/Framework/HydeKernel.php | 2 +- packages/framework/src/Framework/HydeServiceProvider.php | 1 + .../src/Framework/Models/Navigation/DocumentationSidebar.php | 2 +- .../framework/src/Framework/Models/Navigation/NavItem.php | 2 +- .../src/Framework/Models/Navigation/NavigationMenu.php | 2 +- packages/framework/src/Framework/Models/Support/File.php | 2 +- packages/framework/src/Framework/Models/Support/Image.php | 2 +- packages/framework/src/Framework/Models/Support/Route.php | 2 +- .../src/Framework/Modules/DataCollections/DataCollection.php | 2 +- .../Modules/DataCollections/DataCollectionServiceProvider.php | 2 +- .../src/Framework/Modules/Metadata/GlobalMetadataBag.php | 2 +- packages/framework/src/Framework/Services/AssetService.php | 2 +- packages/framework/src/Framework/Services/BuildService.php | 2 +- .../framework/src/Framework/Services/BuildTaskService.php | 2 +- packages/framework/src/Framework/Services/ChecksumService.php | 2 +- .../framework/src/Framework/Services/DiscoveryService.php | 2 +- .../src/Framework/Services/DocumentationSearchService.php | 2 +- packages/framework/src/Framework/Services/RebuildService.php | 2 +- packages/framework/src/Framework/Services/RssFeedService.php | 2 +- packages/framework/src/Framework/Services/SitemapService.php | 2 +- .../framework/src/Framework/Services/ValidationService.php | 2 +- .../src/Framework/Services/YamlConfigurationService.php | 2 +- .../src/Framework/Views/Components/LinkComponent.php | 2 +- packages/framework/src/{Framework => }/Hyde.php | 3 ++- .../tests/Feature/Actions/CreatesNewPageSourceFileTest.php | 2 +- .../tests/Feature/Actions/PublishesHomepageViewTest.php | 2 +- .../tests/Feature/Actions/PublishesHydeViewsTest.php | 2 +- packages/framework/tests/Feature/AssetServiceTest.php | 2 +- .../framework/tests/Feature/AuthorPostsIntegrationTest.php | 2 +- .../tests/Feature/BuildOutputDirectoryCanBeChangedTest.php | 2 +- .../tests/Feature/Commands/HydeBuildRssFeedCommandTest.php | 2 +- .../tests/Feature/Commands/HydeBuildSearchCommandTest.php | 2 +- .../tests/Feature/Commands/HydeBuildSitemapCommandTest.php | 2 +- .../tests/Feature/Commands/HydeMakePageCommandTest.php | 2 +- .../tests/Feature/Commands/HydePackageDiscoverCommandTest.php | 2 +- .../tests/Feature/Commands/HydePublishHomepageCommandTest.php | 2 +- .../tests/Feature/Commands/HydePublishViewsCommandTest.php | 2 +- .../Feature/Commands/HydeRebuildStaticSiteCommandTest.php | 2 +- .../tests/Feature/Commands/HydeUpdateConfigsCommandTest.php | 2 +- .../framework/tests/Feature/Commands/MakePostCommandTest.php | 2 +- .../Feature/Commands/StaticSiteBuilderPostModuleTest.php | 2 +- packages/framework/tests/Feature/DataCollectionTest.php | 2 +- packages/framework/tests/Feature/DiscoveryServiceTest.php | 2 +- packages/framework/tests/Feature/FileCollectionTest.php | 2 +- packages/framework/tests/Feature/FileTest.php | 2 +- .../framework/tests/Feature/Foundation/FilesystemTest.php | 2 +- packages/framework/tests/Feature/HelpersTest.php | 2 +- packages/framework/tests/Feature/HydeKernelTest.php | 4 ++-- packages/framework/tests/Feature/HydePageTest.php | 2 +- packages/framework/tests/Feature/IncludesFacadeTest.php | 2 +- packages/framework/tests/Feature/MarkdownFileParserTest.php | 2 +- packages/framework/tests/Feature/MarkdownPageTest.php | 2 +- packages/framework/tests/Feature/MetadataViewTest.php | 2 +- packages/framework/tests/Feature/NavigationMenuTest.php | 2 +- packages/framework/tests/Feature/PageCollectionTest.php | 2 +- .../framework/tests/Feature/PageModelConstructorsTest.php | 2 +- packages/framework/tests/Feature/RedirectTest.php | 2 +- packages/framework/tests/Feature/RouteCollectionTest.php | 2 +- packages/framework/tests/Feature/RouteTest.php | 2 +- .../framework/tests/Feature/Services/BuildTaskServiceTest.php | 2 +- .../framework/tests/Feature/Services/ChecksumServiceTest.php | 2 +- .../tests/Feature/Services/DocumentationSearchServiceTest.php | 2 +- .../tests/Feature/Services/DocumentationSidebarTest.php | 2 +- .../framework/tests/Feature/Services/HydeSmartDocsTest.php | 2 +- .../framework/tests/Feature/Services/RssFeedServiceTest.php | 2 +- .../framework/tests/Feature/Services/SitemapServiceTest.php | 2 +- .../tests/Feature/Services/ValidationServiceTest.php | 2 +- .../tests/Feature/SourceDirectoriesCanBeChangedTest.php | 2 +- packages/framework/tests/Feature/StaticPageBuilderTest.php | 2 +- packages/framework/tests/Feature/StaticSiteServiceTest.php | 2 +- .../tests/Unit/BlogPostFrontMatterIsOptionalTest.php | 2 +- packages/framework/tests/Unit/DocumentationPageTest.php | 2 +- .../Unit/Foundation/HyperlinkFileHelperRelativeLinkTest.php | 2 +- .../tests/Unit/Foundation/HyperlinkFormatHtmlPathTest.php | 2 +- packages/framework/tests/Unit/GenerateBuildManifestTest.php | 2 +- packages/framework/tests/Unit/GetLatestMarkdownPostsTest.php | 2 +- .../framework/tests/Unit/HydeBasePathCanBeChangedTest.php | 2 +- .../framework/tests/Unit/HydeConfigFilesAreMatchingTest.php | 2 +- packages/framework/tests/Unit/HydeFileHelpersTest.php | 2 +- .../framework/tests/Unit/HydeGetBasePathHasFallbackTest.php | 2 +- .../framework/tests/Unit/HydeHelperFacadeMakeTitleTest.php | 2 +- packages/framework/tests/Unit/HydeHelperFacadeTest.php | 2 +- packages/framework/tests/Unit/HydePathHelperTest.php | 2 +- packages/framework/tests/Unit/HydeServiceProviderTest.php | 2 +- packages/framework/tests/Unit/HydeVendorPathHelperTest.php | 2 +- .../tests/Unit/InteractsWithDirectoriesConcernTest.php | 2 +- packages/framework/tests/Unit/MarkdownDocumentTest.php | 2 +- packages/framework/tests/Unit/MarkdownPostParserTest.php | 2 +- .../framework/tests/Unit/PageModelGetAllFilesHelperTest.php | 2 +- packages/framework/tests/Unit/PageModelGetHelperTest.php | 2 +- packages/framework/tests/Unit/PageModelParseHelperTest.php | 2 +- .../Unit/RelativeLinksAcrossPagesRetainsIntegrityTest.php | 2 +- .../Unit/SourceFilesInCustomDirectoriesCanBeCompiledTest.php | 2 +- .../TestBuildStaticSiteCommandFlagToEnablePrettyUrlsTest.php | 2 +- .../framework/tests/Unit/Views/ArticleExcerptViewTest.php | 2 +- .../framework/tests/Unit/Views/NavigationMenuViewTest.php | 2 +- .../framework/tests/Unit/Views/ScriptsComponentViewTest.php | 2 +- .../framework/tests/Unit/Views/StylesComponentViewTest.php | 2 +- packages/realtime-compiler/src/Actions/RendersSearchPage.php | 2 +- packages/testing/src/CreatesApplication.php | 2 +- packages/testing/src/ResetsApplication.php | 2 +- packages/testing/src/TestCase.php | 2 +- projects/shelf/admin/src/AdminServiceProvider.php | 2 +- projects/shelf/single-file-dashboard/dashboard.php | 2 +- tests/Benchmarks/PageParserBenchmark.php | 2 +- tests/Benchmarks/SearchIndexBenchmark.php | 2 +- tests/Benchmarks/StaticSiteBuilderBenchmark.php | 2 +- tests/Browser/HighLevelViewTest.php | 2 +- tests/Hyde/Feature/DefaultContentTest.php | 2 +- tests/Hyde/Feature/StaticSiteBuilderTest.php | 2 +- 143 files changed, 146 insertions(+), 144 deletions(-) rename packages/framework/src/{Framework => }/Hyde.php (98%) diff --git a/config/app.php b/config/app.php index b96a32051fa..f59506d3d44 100644 --- a/config/app.php +++ b/config/app.php @@ -45,7 +45,7 @@ | */ - 'version' => Hyde\Framework\Hyde::version(), + 'version' => Hyde\Hyde::version(), /* |-------------------------------------------------------------------------- @@ -93,7 +93,7 @@ */ 'aliases' => [ - 'Hyde' => Hyde\Framework\Hyde::class, + 'Hyde' => Hyde\Hyde::class, 'Asset' => Hyde\Framework\Helpers\Asset::class, 'Site' => \Hyde\Framework\Models\Support\Site::class, 'Route' => \Hyde\Framework\Models\Support\Route::class, diff --git a/config/hyde.php b/config/hyde.php index 6cfb626a1ff..986c339ac89 100644 --- a/config/hyde.php +++ b/config/hyde.php @@ -36,7 +36,7 @@ // Meta::name('twitter:creator', '@HydeFramework'), // Meta::name('description', 'My Hyde Blog'), // Meta::name('keywords', 'Static Sites, Blogs, Documentation'), - Meta::name('generator', 'HydePHP '.Hyde\Framework\Hyde::version()), + Meta::name('generator', 'HydePHP '. Hyde\Hyde::version()), Meta::property('site_name', config('site.name', 'HydePHP')), ], diff --git a/packages/framework/config/hyde.php b/packages/framework/config/hyde.php index 6cfb626a1ff..986c339ac89 100644 --- a/packages/framework/config/hyde.php +++ b/packages/framework/config/hyde.php @@ -36,7 +36,7 @@ // Meta::name('twitter:creator', '@HydeFramework'), // Meta::name('description', 'My Hyde Blog'), // Meta::name('keywords', 'Static Sites, Blogs, Documentation'), - Meta::name('generator', 'HydePHP '.Hyde\Framework\Hyde::version()), + Meta::name('generator', 'HydePHP '. Hyde\Hyde::version()), Meta::property('site_name', config('site.name', 'HydePHP')), ], diff --git a/packages/framework/src/Framework/Actions/BladeMatterParser.php b/packages/framework/src/Framework/Actions/BladeMatterParser.php index f111a1e2de4..fba0c0132b5 100644 --- a/packages/framework/src/Framework/Actions/BladeMatterParser.php +++ b/packages/framework/src/Framework/Actions/BladeMatterParser.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Actions; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use RuntimeException; /** diff --git a/packages/framework/src/Framework/Actions/Constructors/FindsContentLengthForImageObject.php b/packages/framework/src/Framework/Actions/Constructors/FindsContentLengthForImageObject.php index 17ee71be2a0..218121bbca7 100644 --- a/packages/framework/src/Framework/Actions/Constructors/FindsContentLengthForImageObject.php +++ b/packages/framework/src/Framework/Actions/Constructors/FindsContentLengthForImageObject.php @@ -4,8 +4,8 @@ namespace Hyde\Framework\Actions\Constructors; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Support\Image; +use Hyde\Hyde; use Illuminate\Support\Facades\Http; use Symfony\Component\Console\Output\ConsoleOutput; use Symfony\Component\Console\Output\OutputInterface; diff --git a/packages/framework/src/Framework/Actions/Constructors/FindsTitleForPage.php b/packages/framework/src/Framework/Actions/Constructors/FindsTitleForPage.php index 6a478599a89..439285139ba 100644 --- a/packages/framework/src/Framework/Actions/Constructors/FindsTitleForPage.php +++ b/packages/framework/src/Framework/Actions/Constructors/FindsTitleForPage.php @@ -6,7 +6,7 @@ use Hyde\Framework\Concerns\BaseMarkdownPage; use Hyde\Framework\Concerns\HydePage; -use Hyde\Framework\Hyde; +use Hyde\Hyde; /** * @see \Hyde\Framework\Testing\Feature\PageModelConstructorsTest diff --git a/packages/framework/src/Framework/Actions/CreatesNewMarkdownPostFile.php b/packages/framework/src/Framework/Actions/CreatesNewMarkdownPostFile.php index f6b2370c9ee..724e5832d1b 100644 --- a/packages/framework/src/Framework/Actions/CreatesNewMarkdownPostFile.php +++ b/packages/framework/src/Framework/Actions/CreatesNewMarkdownPostFile.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Actions; use Hyde\Framework\Exceptions\FileConflictException; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Illuminate\Support\Str; /** diff --git a/packages/framework/src/Framework/Actions/CreatesNewPageSourceFile.php b/packages/framework/src/Framework/Actions/CreatesNewPageSourceFile.php index fae26e10d66..be4f3530a66 100644 --- a/packages/framework/src/Framework/Actions/CreatesNewPageSourceFile.php +++ b/packages/framework/src/Framework/Actions/CreatesNewPageSourceFile.php @@ -7,10 +7,10 @@ use Hyde\Framework\Concerns\InteractsWithDirectories; use Hyde\Framework\Exceptions\FileConflictException; use Hyde\Framework\Exceptions\UnsupportedPageTypeException; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; +use Hyde\Hyde; use Illuminate\Support\Str; /** diff --git a/packages/framework/src/Framework/Actions/MarkdownFileParser.php b/packages/framework/src/Framework/Actions/MarkdownFileParser.php index 568bb3256c2..8ed7e87a774 100644 --- a/packages/framework/src/Framework/Actions/MarkdownFileParser.php +++ b/packages/framework/src/Framework/Actions/MarkdownFileParser.php @@ -4,8 +4,8 @@ namespace Hyde\Framework\Actions; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Markdown\MarkdownDocument; +use Hyde\Hyde; use Spatie\YamlFrontMatter\YamlFrontMatter; /** diff --git a/packages/framework/src/Framework/Actions/PostBuildTasks/GenerateBuildManifest.php b/packages/framework/src/Framework/Actions/PostBuildTasks/GenerateBuildManifest.php index cf9738a8ce2..ddc3483ff7f 100644 --- a/packages/framework/src/Framework/Actions/PostBuildTasks/GenerateBuildManifest.php +++ b/packages/framework/src/Framework/Actions/PostBuildTasks/GenerateBuildManifest.php @@ -6,8 +6,8 @@ use Hyde\Framework\Concerns\AbstractBuildTask; use Hyde\Framework\Concerns\HydePage; -use Hyde\Framework\Hyde; use Hyde\Framework\Services\ChecksumService; +use Hyde\Hyde; use Illuminate\Console\OutputStyle; use Illuminate\Support\Collection; diff --git a/packages/framework/src/Framework/Actions/PostBuildTasks/GenerateRssFeed.php b/packages/framework/src/Framework/Actions/PostBuildTasks/GenerateRssFeed.php index 732b9b97eb2..746643b37ad 100644 --- a/packages/framework/src/Framework/Actions/PostBuildTasks/GenerateRssFeed.php +++ b/packages/framework/src/Framework/Actions/PostBuildTasks/GenerateRssFeed.php @@ -5,8 +5,8 @@ namespace Hyde\Framework\Actions\PostBuildTasks; use Hyde\Framework\Concerns\AbstractBuildTask; -use Hyde\Framework\Hyde; use Hyde\Framework\Services\RssFeedService; +use Hyde\Hyde; class GenerateRssFeed extends AbstractBuildTask { diff --git a/packages/framework/src/Framework/Actions/PostBuildTasks/GenerateSitemap.php b/packages/framework/src/Framework/Actions/PostBuildTasks/GenerateSitemap.php index 48bac93486d..54ce9bbd704 100644 --- a/packages/framework/src/Framework/Actions/PostBuildTasks/GenerateSitemap.php +++ b/packages/framework/src/Framework/Actions/PostBuildTasks/GenerateSitemap.php @@ -5,8 +5,8 @@ namespace Hyde\Framework\Actions\PostBuildTasks; use Hyde\Framework\Concerns\AbstractBuildTask; -use Hyde\Framework\Hyde; use Hyde\Framework\Services\SitemapService; +use Hyde\Hyde; class GenerateSitemap extends AbstractBuildTask { diff --git a/packages/framework/src/Framework/Actions/PublishesHomepageView.php b/packages/framework/src/Framework/Actions/PublishesHomepageView.php index 58145ed170b..1040f91ef98 100644 --- a/packages/framework/src/Framework/Actions/PublishesHomepageView.php +++ b/packages/framework/src/Framework/Actions/PublishesHomepageView.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Actions; -use Hyde\Framework\Hyde; +use Hyde\Hyde; /** * Publish one of the Hyde homepages. diff --git a/packages/framework/src/Framework/Actions/PublishesHydeViews.php b/packages/framework/src/Framework/Actions/PublishesHydeViews.php index cf487124a4f..ec1195e5635 100644 --- a/packages/framework/src/Framework/Actions/PublishesHydeViews.php +++ b/packages/framework/src/Framework/Actions/PublishesHydeViews.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Actions; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Illuminate\Support\Facades\File; /* diff --git a/packages/framework/src/Framework/Actions/StaticPageBuilder.php b/packages/framework/src/Framework/Actions/StaticPageBuilder.php index 605af0d4cfc..b295e194fc1 100644 --- a/packages/framework/src/Framework/Actions/StaticPageBuilder.php +++ b/packages/framework/src/Framework/Actions/StaticPageBuilder.php @@ -6,7 +6,7 @@ use Hyde\Framework\Concerns\HydePage; use Hyde\Framework\Concerns\InteractsWithDirectories; -use Hyde\Framework\Hyde; +use Hyde\Hyde; /** * Converts a Page Model into a static HTML page. diff --git a/packages/framework/src/Framework/Commands/HydeBuildSiteCommand.php b/packages/framework/src/Framework/Commands/HydeBuildSiteCommand.php index 0fa5d9f0ee8..3d40639c7e1 100644 --- a/packages/framework/src/Framework/Commands/HydeBuildSiteCommand.php +++ b/packages/framework/src/Framework/Commands/HydeBuildSiteCommand.php @@ -9,10 +9,10 @@ use Hyde\Framework\Actions\PostBuildTasks\GenerateSearch; use Hyde\Framework\Actions\PostBuildTasks\GenerateSitemap; use Hyde\Framework\Helpers\Features; -use Hyde\Framework\Hyde; use Hyde\Framework\Services\BuildService; use Hyde\Framework\Services\BuildTaskService; use Hyde\Framework\Services\DiscoveryService; +use Hyde\Hyde; use Illuminate\Support\Facades\Config; use LaravelZero\Framework\Commands\Command; diff --git a/packages/framework/src/Framework/Commands/HydeDebugCommand.php b/packages/framework/src/Framework/Commands/HydeDebugCommand.php index 0a7fb8d7489..0b2868cf356 100644 --- a/packages/framework/src/Framework/Commands/HydeDebugCommand.php +++ b/packages/framework/src/Framework/Commands/HydeDebugCommand.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Commands; use Composer\InstalledVersions; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use LaravelZero\Framework\Commands\Command; /** diff --git a/packages/framework/src/Framework/Commands/HydePackageDiscoverCommand.php b/packages/framework/src/Framework/Commands/HydePackageDiscoverCommand.php index d0fff93a017..fd15ceb064d 100644 --- a/packages/framework/src/Framework/Commands/HydePackageDiscoverCommand.php +++ b/packages/framework/src/Framework/Commands/HydePackageDiscoverCommand.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Commands; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Illuminate\Foundation\Console\PackageDiscoverCommand as BaseCommand; use Illuminate\Foundation\PackageManifest; diff --git a/packages/framework/src/Framework/Commands/HydePublishHomepageCommand.php b/packages/framework/src/Framework/Commands/HydePublishHomepageCommand.php index 94a3e62a3af..de05387d985 100644 --- a/packages/framework/src/Framework/Commands/HydePublishHomepageCommand.php +++ b/packages/framework/src/Framework/Commands/HydePublishHomepageCommand.php @@ -5,8 +5,8 @@ namespace Hyde\Framework\Commands; use Hyde\Framework\Actions\PublishesHomepageView; -use Hyde\Framework\Hyde; use Hyde\Framework\Services\ChecksumService; +use Hyde\Hyde; use Illuminate\Support\Facades\Artisan; use LaravelZero\Framework\Commands\Command; diff --git a/packages/framework/src/Framework/Commands/HydePublishViewsCommand.php b/packages/framework/src/Framework/Commands/HydePublishViewsCommand.php index bb172485326..6cb8d1faff8 100644 --- a/packages/framework/src/Framework/Commands/HydePublishViewsCommand.php +++ b/packages/framework/src/Framework/Commands/HydePublishViewsCommand.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Commands; use Hyde\Framework\Actions\PublishesHydeViews; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use LaravelZero\Framework\Commands\Command; /** diff --git a/packages/framework/src/Framework/Commands/HydeRebuildStaticSiteCommand.php b/packages/framework/src/Framework/Commands/HydeRebuildStaticSiteCommand.php index 769c5771a28..808295b7270 100644 --- a/packages/framework/src/Framework/Commands/HydeRebuildStaticSiteCommand.php +++ b/packages/framework/src/Framework/Commands/HydeRebuildStaticSiteCommand.php @@ -5,10 +5,10 @@ namespace Hyde\Framework\Commands; use Exception; -use Hyde\Framework\Hyde; use Hyde\Framework\Services\BuildService; use Hyde\Framework\Services\DiscoveryService; use Hyde\Framework\Services\RebuildService; +use Hyde\Hyde; use LaravelZero\Framework\Commands\Command; /** diff --git a/packages/framework/src/Framework/Commands/HydeRouteListCommand.php b/packages/framework/src/Framework/Commands/HydeRouteListCommand.php index 3f2e1bd040f..e1bb9cc2101 100644 --- a/packages/framework/src/Framework/Commands/HydeRouteListCommand.php +++ b/packages/framework/src/Framework/Commands/HydeRouteListCommand.php @@ -4,8 +4,8 @@ namespace Hyde\Framework\Commands; -use Hyde\Framework\Hyde; use Hyde\Framework\Services\DiscoveryService; +use Hyde\Hyde; use LaravelZero\Framework\Commands\Command; /** diff --git a/packages/framework/src/Framework/Commands/HydeServeCommand.php b/packages/framework/src/Framework/Commands/HydeServeCommand.php index e7146137aa4..b1247ca8469 100644 --- a/packages/framework/src/Framework/Commands/HydeServeCommand.php +++ b/packages/framework/src/Framework/Commands/HydeServeCommand.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Commands; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use LaravelZero\Framework\Commands\Command; /** diff --git a/packages/framework/src/Framework/Commands/HydeUpdateConfigsCommand.php b/packages/framework/src/Framework/Commands/HydeUpdateConfigsCommand.php index 5bb45f7f0d8..7e395691841 100644 --- a/packages/framework/src/Framework/Commands/HydeUpdateConfigsCommand.php +++ b/packages/framework/src/Framework/Commands/HydeUpdateConfigsCommand.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Commands; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Illuminate\Support\Facades\File; use LaravelZero\Framework\Commands\Command; diff --git a/packages/framework/src/Framework/Concerns/AbstractBuildTask.php b/packages/framework/src/Framework/Concerns/AbstractBuildTask.php index 2545c980636..eb2843aa648 100644 --- a/packages/framework/src/Framework/Concerns/AbstractBuildTask.php +++ b/packages/framework/src/Framework/Concerns/AbstractBuildTask.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Concerns; use Hyde\Framework\Contracts\BuildTaskContract; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Illuminate\Console\Concerns\InteractsWithIO; use Illuminate\Console\OutputStyle; use Throwable; diff --git a/packages/framework/src/Framework/Concerns/BaseMarkdownPage.php b/packages/framework/src/Framework/Concerns/BaseMarkdownPage.php index 3fc8ddd4946..957fbb4e0b8 100644 --- a/packages/framework/src/Framework/Concerns/BaseMarkdownPage.php +++ b/packages/framework/src/Framework/Concerns/BaseMarkdownPage.php @@ -5,9 +5,9 @@ namespace Hyde\Framework\Concerns; use Hyde\Framework\Contracts\MarkdownDocumentContract; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Markdown\FrontMatter; use Hyde\Framework\Models\Markdown\Markdown; +use Hyde\Hyde; /** * The base class for all Markdown-based page models. diff --git a/packages/framework/src/Framework/Concerns/HydePage.php b/packages/framework/src/Framework/Concerns/HydePage.php index 7b3f028984e..9c9f80793ab 100644 --- a/packages/framework/src/Framework/Concerns/HydePage.php +++ b/packages/framework/src/Framework/Concerns/HydePage.php @@ -9,12 +9,12 @@ use Hyde\Framework\Contracts\CompilableContract; use Hyde\Framework\Contracts\FrontMatter\PageSchema; use Hyde\Framework\Foundation\PageCollection; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Markdown\FrontMatter; use Hyde\Framework\Models\Navigation\NavigationData; use Hyde\Framework\Models\Support\Route; use Hyde\Framework\Modules\Metadata\PageMetadataBag; use Hyde\Framework\Services\DiscoveryService; +use Hyde\Hyde; use Illuminate\Support\Arr; /** diff --git a/packages/framework/src/Framework/Concerns/Internal/ConstructsPageSchemas.php b/packages/framework/src/Framework/Concerns/Internal/ConstructsPageSchemas.php index 9ca87b96ace..e948d04fad0 100644 --- a/packages/framework/src/Framework/Concerns/Internal/ConstructsPageSchemas.php +++ b/packages/framework/src/Framework/Concerns/Internal/ConstructsPageSchemas.php @@ -7,11 +7,11 @@ use Hyde\Framework\Actions\Constructors\FindsNavigationDataForPage; use Hyde\Framework\Actions\Constructors\FindsTitleForPage; use Hyde\Framework\Contracts\FrontMatter\BlogPostSchema; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\MarkdownPost; use Hyde\Framework\Models\Support\Author; use Hyde\Framework\Models\Support\DateString; use Hyde\Framework\Models\Support\Image; +use Hyde\Hyde; trait ConstructsPageSchemas { diff --git a/packages/framework/src/Framework/Concerns/ValidatesExistence.php b/packages/framework/src/Framework/Concerns/ValidatesExistence.php index 92ef194c000..a544da69bb0 100644 --- a/packages/framework/src/Framework/Concerns/ValidatesExistence.php +++ b/packages/framework/src/Framework/Concerns/ValidatesExistence.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Concerns; use Hyde\Framework\Exceptions\FileNotFoundException; -use Hyde\Framework\Hyde; +use Hyde\Hyde; /** * Validate the existence of a Page model's source file. diff --git a/packages/framework/src/Framework/Foundation/Filesystem.php b/packages/framework/src/Framework/Foundation/Filesystem.php index aed1118361d..7fe9f9b98a5 100644 --- a/packages/framework/src/Framework/Foundation/Filesystem.php +++ b/packages/framework/src/Framework/Foundation/Filesystem.php @@ -4,7 +4,6 @@ namespace Hyde\Framework\Foundation; -use Hyde\Framework\Hyde; use Hyde\Framework\HydeKernel; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; @@ -12,6 +11,7 @@ use Hyde\Framework\Models\Pages\MarkdownPost; use Hyde\Framework\Models\Support\Site; use Hyde\Framework\Services\DiscoveryService; +use Hyde\Hyde; /** * File helper methods, bound to the HydeKernel instance, and is an integral part of the framework. diff --git a/packages/framework/src/Framework/Helpers/Features.php b/packages/framework/src/Framework/Helpers/Features.php index 3c64e785f26..42f4092ebc5 100644 --- a/packages/framework/src/Framework/Helpers/Features.php +++ b/packages/framework/src/Framework/Helpers/Features.php @@ -5,8 +5,8 @@ namespace Hyde\Framework\Helpers; use Hyde\Framework\Concerns\JsonSerializesArrayable; -use Hyde\Framework\Hyde; use Hyde\Framework\Services\DiscoveryService; +use Hyde\Hyde; use Illuminate\Contracts\Support\Arrayable; use Illuminate\Support\Str; use JsonSerializable; diff --git a/packages/framework/src/Framework/Helpers/Includes.php b/packages/framework/src/Framework/Helpers/Includes.php index d5933db2f49..5f16aec6888 100644 --- a/packages/framework/src/Framework/Helpers/Includes.php +++ b/packages/framework/src/Framework/Helpers/Includes.php @@ -4,8 +4,8 @@ namespace Hyde\Framework\Helpers; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Markdown\Markdown; +use Hyde\Hyde; use Illuminate\Support\Facades\Blade; class Includes diff --git a/packages/framework/src/Framework/Helpers/Redirect.php b/packages/framework/src/Framework/Helpers/Redirect.php index c944580b536..3d5a8f3e9bd 100644 --- a/packages/framework/src/Framework/Helpers/Redirect.php +++ b/packages/framework/src/Framework/Helpers/Redirect.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Helpers; -use Hyde\Framework\Hyde; +use Hyde\Hyde; /** * A basic redirect page. Is not discoverable by Hyde, instead you manually need to create the pages. diff --git a/packages/framework/src/Framework/HydeKernel.php b/packages/framework/src/Framework/HydeKernel.php index 99009b5cc74..3f53aa99d6c 100644 --- a/packages/framework/src/Framework/HydeKernel.php +++ b/packages/framework/src/Framework/HydeKernel.php @@ -18,7 +18,7 @@ /** * Encapsulates a HydePHP project, providing helpful methods for interacting with it. * - * @see \Hyde\Framework\Hyde for the facade commonly used to access this class. + * @see \Hyde\Hyde for the facade commonly used to access this class. * * @author Caen De Silva * @copyright 2022 Caen De Silva diff --git a/packages/framework/src/Framework/HydeServiceProvider.php b/packages/framework/src/Framework/HydeServiceProvider.php index 8c35905879d..f5323259c35 100644 --- a/packages/framework/src/Framework/HydeServiceProvider.php +++ b/packages/framework/src/Framework/HydeServiceProvider.php @@ -13,6 +13,7 @@ use Hyde\Framework\Services\AssetService; use Hyde\Framework\Services\YamlConfigurationService; use Hyde\Framework\Views\Components\LinkComponent; +use Hyde\Hyde; use Illuminate\Support\Facades\Blade; use Illuminate\Support\ServiceProvider; diff --git a/packages/framework/src/Framework/Models/Navigation/DocumentationSidebar.php b/packages/framework/src/Framework/Models/Navigation/DocumentationSidebar.php index d27092aade5..a811c6be301 100644 --- a/packages/framework/src/Framework/Models/Navigation/DocumentationSidebar.php +++ b/packages/framework/src/Framework/Models/Navigation/DocumentationSidebar.php @@ -4,9 +4,9 @@ namespace Hyde\Framework\Models\Navigation; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Support\Route; +use Hyde\Hyde; use Illuminate\Support\Collection; use Illuminate\Support\Str; diff --git a/packages/framework/src/Framework/Models/Navigation/NavItem.php b/packages/framework/src/Framework/Models/Navigation/NavItem.php index 3e9d4e78d90..cf8411ef4aa 100644 --- a/packages/framework/src/Framework/Models/Navigation/NavItem.php +++ b/packages/framework/src/Framework/Models/Navigation/NavItem.php @@ -5,8 +5,8 @@ namespace Hyde\Framework\Models\Navigation; use Hyde\Framework\Concerns\HydePage; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Support\Route; +use Hyde\Hyde; use Illuminate\Support\Str; use Stringable; diff --git a/packages/framework/src/Framework/Models/Navigation/NavigationMenu.php b/packages/framework/src/Framework/Models/Navigation/NavigationMenu.php index 3e42957fa99..f0c9c1fc10b 100644 --- a/packages/framework/src/Framework/Models/Navigation/NavigationMenu.php +++ b/packages/framework/src/Framework/Models/Navigation/NavigationMenu.php @@ -4,9 +4,9 @@ namespace Hyde\Framework\Models\Navigation; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Support\Route; +use Hyde\Hyde; use Illuminate\Support\Collection; /** diff --git a/packages/framework/src/Framework/Models/Support/File.php b/packages/framework/src/Framework/Models/Support/File.php index cebc88f9da4..93f93ad44c4 100644 --- a/packages/framework/src/Framework/Models/Support/File.php +++ b/packages/framework/src/Framework/Models/Support/File.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Models\Support; use Hyde\Framework\Concerns\JsonSerializesArrayable; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Illuminate\Contracts\Support\Arrayable; use JsonSerializable; use Stringable; diff --git a/packages/framework/src/Framework/Models/Support/Image.php b/packages/framework/src/Framework/Models/Support/Image.php index b15317558ae..e0aff73cfc8 100644 --- a/packages/framework/src/Framework/Models/Support/Image.php +++ b/packages/framework/src/Framework/Models/Support/Image.php @@ -7,7 +7,7 @@ use Exception; use Hyde\Framework\Actions\Constructors\FindsContentLengthForImageObject; use Hyde\Framework\Contracts\FrontMatter\Support\FeaturedImageSchema; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Stringable; /** diff --git a/packages/framework/src/Framework/Models/Support/Route.php b/packages/framework/src/Framework/Models/Support/Route.php index dc92a76511f..a9e8f91559d 100644 --- a/packages/framework/src/Framework/Models/Support/Route.php +++ b/packages/framework/src/Framework/Models/Support/Route.php @@ -8,7 +8,7 @@ use Hyde\Framework\Concerns\JsonSerializesArrayable; use Hyde\Framework\Exceptions\RouteNotFoundException; use Hyde\Framework\Foundation\RouteCollection; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Illuminate\Contracts\Support\Arrayable; use JsonSerializable; use Stringable; diff --git a/packages/framework/src/Framework/Modules/DataCollections/DataCollection.php b/packages/framework/src/Framework/Modules/DataCollections/DataCollection.php index f40d146219d..d5aca948094 100644 --- a/packages/framework/src/Framework/Modules/DataCollections/DataCollection.php +++ b/packages/framework/src/Framework/Modules/DataCollections/DataCollection.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Modules\DataCollections; use Hyde\Framework\Actions\MarkdownFileParser; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Illuminate\Support\Collection; /** diff --git a/packages/framework/src/Framework/Modules/DataCollections/DataCollectionServiceProvider.php b/packages/framework/src/Framework/Modules/DataCollections/DataCollectionServiceProvider.php index bbb07b4e33c..5469c0002cd 100644 --- a/packages/framework/src/Framework/Modules/DataCollections/DataCollectionServiceProvider.php +++ b/packages/framework/src/Framework/Modules/DataCollections/DataCollectionServiceProvider.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Modules\DataCollections; use Hyde\Framework\Helpers\Features; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Illuminate\Foundation\AliasLoader; use Illuminate\Support\ServiceProvider; diff --git a/packages/framework/src/Framework/Modules/Metadata/GlobalMetadataBag.php b/packages/framework/src/Framework/Modules/Metadata/GlobalMetadataBag.php index 9d7ba9c1c6e..5cf22843f57 100644 --- a/packages/framework/src/Framework/Modules/Metadata/GlobalMetadataBag.php +++ b/packages/framework/src/Framework/Modules/Metadata/GlobalMetadataBag.php @@ -7,8 +7,8 @@ use Hyde\Framework\Concerns\HydePage; use Hyde\Framework\Helpers\Features; use Hyde\Framework\Helpers\Meta; -use Hyde\Framework\Hyde; use Hyde\Framework\Services\RssFeedService; +use Hyde\Hyde; use Illuminate\Support\Facades\View; /** diff --git a/packages/framework/src/Framework/Services/AssetService.php b/packages/framework/src/Framework/Services/AssetService.php index d681ecc9ba6..67cb9dbc4fe 100644 --- a/packages/framework/src/Framework/Services/AssetService.php +++ b/packages/framework/src/Framework/Services/AssetService.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Services; -use Hyde\Framework\Hyde; +use Hyde\Hyde; /** * Handles the retrieval of core asset files. Commonly used through the Asset facade. diff --git a/packages/framework/src/Framework/Services/BuildService.php b/packages/framework/src/Framework/Services/BuildService.php index 0b2a222097c..7346ade646c 100644 --- a/packages/framework/src/Framework/Services/BuildService.php +++ b/packages/framework/src/Framework/Services/BuildService.php @@ -8,9 +8,9 @@ use Hyde\Framework\Actions\StaticPageBuilder; use Hyde\Framework\Concerns\InteractsWithDirectories; use Hyde\Framework\Foundation\RouteCollection; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Support\Route; use Hyde\Framework\Models\Support\Site; +use Hyde\Hyde; use Illuminate\Console\Concerns\InteractsWithIO; use Illuminate\Console\OutputStyle; use Illuminate\Support\Facades\File; diff --git a/packages/framework/src/Framework/Services/BuildTaskService.php b/packages/framework/src/Framework/Services/BuildTaskService.php index 88842322706..0d00f67c684 100644 --- a/packages/framework/src/Framework/Services/BuildTaskService.php +++ b/packages/framework/src/Framework/Services/BuildTaskService.php @@ -6,7 +6,7 @@ use Hyde\Framework\Actions\PostBuildTasks\GenerateBuildManifest; use Hyde\Framework\Contracts\BuildTaskContract; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Illuminate\Console\OutputStyle; /** diff --git a/packages/framework/src/Framework/Services/ChecksumService.php b/packages/framework/src/Framework/Services/ChecksumService.php index 3ec812bfe7f..014edcfa764 100644 --- a/packages/framework/src/Framework/Services/ChecksumService.php +++ b/packages/framework/src/Framework/Services/ChecksumService.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Services; -use Hyde\Framework\Hyde; +use Hyde\Hyde; /** * Helper methods to interact with the filecache. The filecache is used to compare diff --git a/packages/framework/src/Framework/Services/DiscoveryService.php b/packages/framework/src/Framework/Services/DiscoveryService.php index 017beab2586..d694cb5f412 100644 --- a/packages/framework/src/Framework/Services/DiscoveryService.php +++ b/packages/framework/src/Framework/Services/DiscoveryService.php @@ -6,12 +6,12 @@ use Hyde\Framework\Concerns\HydePage; use Hyde\Framework\Exceptions\UnsupportedPageTypeException; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; use Hyde\Framework\Models\Pages\MarkdownPost; use Hyde\Framework\Models\Support\File; +use Hyde\Hyde; /** * The core service that powers all HydePHP file auto-discovery. diff --git a/packages/framework/src/Framework/Services/DocumentationSearchService.php b/packages/framework/src/Framework/Services/DocumentationSearchService.php index 57c0f4b0699..6bc5299d9b1 100644 --- a/packages/framework/src/Framework/Services/DocumentationSearchService.php +++ b/packages/framework/src/Framework/Services/DocumentationSearchService.php @@ -5,8 +5,8 @@ namespace Hyde\Framework\Services; use Hyde\Framework\Concerns\InteractsWithDirectories; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\DocumentationPage; +use Hyde\Hyde; use Illuminate\Support\Collection; use Illuminate\Support\Str; use JetBrains\PhpStorm\ArrayShape; diff --git a/packages/framework/src/Framework/Services/RebuildService.php b/packages/framework/src/Framework/Services/RebuildService.php index 071f3bfc519..78c00f68933 100644 --- a/packages/framework/src/Framework/Services/RebuildService.php +++ b/packages/framework/src/Framework/Services/RebuildService.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Services; use Hyde\Framework\Actions\StaticPageBuilder; -use Hyde\Framework\Hyde; +use Hyde\Hyde; /** * Build static pages, but intelligently. diff --git a/packages/framework/src/Framework/Services/RssFeedService.php b/packages/framework/src/Framework/Services/RssFeedService.php index 24c1ade9b4a..1582c007cd8 100644 --- a/packages/framework/src/Framework/Services/RssFeedService.php +++ b/packages/framework/src/Framework/Services/RssFeedService.php @@ -8,8 +8,8 @@ namespace Hyde\Framework\Services; use Exception; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\MarkdownPost; +use Hyde\Hyde; use SimpleXMLElement; /** diff --git a/packages/framework/src/Framework/Services/SitemapService.php b/packages/framework/src/Framework/Services/SitemapService.php index d3b5334dc25..7f993e4e04a 100644 --- a/packages/framework/src/Framework/Services/SitemapService.php +++ b/packages/framework/src/Framework/Services/SitemapService.php @@ -7,12 +7,12 @@ namespace Hyde\Framework\Services; use Exception; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; use Hyde\Framework\Models\Pages\MarkdownPost; use Hyde\Framework\Models\Support\Route; +use Hyde\Hyde; use SimpleXMLElement; /** diff --git a/packages/framework/src/Framework/Services/ValidationService.php b/packages/framework/src/Framework/Services/ValidationService.php index 0aabab41698..ce4f7be07a5 100644 --- a/packages/framework/src/Framework/Services/ValidationService.php +++ b/packages/framework/src/Framework/Services/ValidationService.php @@ -5,8 +5,8 @@ namespace Hyde\Framework\Services; use Hyde\Framework\Helpers\Features; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Support\ValidationResult as Result; +use Hyde\Hyde; /** * @see \Hyde\Framework\Testing\Feature\Services\ValidationServiceTest diff --git a/packages/framework/src/Framework/Services/YamlConfigurationService.php b/packages/framework/src/Framework/Services/YamlConfigurationService.php index cdc12ee5087..81d99d36399 100644 --- a/packages/framework/src/Framework/Services/YamlConfigurationService.php +++ b/packages/framework/src/Framework/Services/YamlConfigurationService.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Services; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Illuminate\Support\Facades\Config; use Symfony\Component\Yaml\Yaml; diff --git a/packages/framework/src/Framework/Views/Components/LinkComponent.php b/packages/framework/src/Framework/Views/Components/LinkComponent.php index e6db699c1ba..2e51ddcd21a 100644 --- a/packages/framework/src/Framework/Views/Components/LinkComponent.php +++ b/packages/framework/src/Framework/Views/Components/LinkComponent.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Views\Components; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Illuminate\Contracts\View\Factory; use Illuminate\Contracts\View\View; use Illuminate\View\Component; diff --git a/packages/framework/src/Framework/Hyde.php b/packages/framework/src/Hyde.php similarity index 98% rename from packages/framework/src/Framework/Hyde.php rename to packages/framework/src/Hyde.php index 9da5096ba4d..e3dbacddcdc 100644 --- a/packages/framework/src/Framework/Hyde.php +++ b/packages/framework/src/Hyde.php @@ -2,13 +2,14 @@ declare(strict_types=1); -namespace Hyde\Framework; +namespace Hyde; use Hyde\Framework\Concerns\HydePage; use Hyde\Framework\Foundation\FileCollection; use Hyde\Framework\Foundation\PageCollection; use Hyde\Framework\Foundation\RouteCollection; use Hyde\Framework\Helpers\Features; +use Hyde\Framework\HydeKernel; use Hyde\Framework\Models\Support\Route; use Illuminate\Support\Facades\Facade; diff --git a/packages/framework/tests/Feature/Actions/CreatesNewPageSourceFileTest.php b/packages/framework/tests/Feature/Actions/CreatesNewPageSourceFileTest.php index a21c26a64fa..18d95fef9e0 100644 --- a/packages/framework/tests/Feature/Actions/CreatesNewPageSourceFileTest.php +++ b/packages/framework/tests/Feature/Actions/CreatesNewPageSourceFileTest.php @@ -7,9 +7,9 @@ use Hyde\Framework\Actions\CreatesNewPageSourceFile; use Hyde\Framework\Exceptions\FileConflictException; use Hyde\Framework\Exceptions\UnsupportedPageTypeException; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/Actions/PublishesHomepageViewTest.php b/packages/framework/tests/Feature/Actions/PublishesHomepageViewTest.php index f00aec56b52..d2dffcd52c1 100644 --- a/packages/framework/tests/Feature/Actions/PublishesHomepageViewTest.php +++ b/packages/framework/tests/Feature/Actions/PublishesHomepageViewTest.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Testing\Feature\Actions; use Hyde\Framework\Actions\PublishesHomepageView; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/Actions/PublishesHydeViewsTest.php b/packages/framework/tests/Feature/Actions/PublishesHydeViewsTest.php index 8e116ac5b5e..93034f1678a 100644 --- a/packages/framework/tests/Feature/Actions/PublishesHydeViewsTest.php +++ b/packages/framework/tests/Feature/Actions/PublishesHydeViewsTest.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Testing\Feature\Actions; use Hyde\Framework\Actions\PublishesHydeViews; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/AssetServiceTest.php b/packages/framework/tests/Feature/AssetServiceTest.php index 671fe746dde..0250046c1ba 100644 --- a/packages/framework/tests/Feature/AssetServiceTest.php +++ b/packages/framework/tests/Feature/AssetServiceTest.php @@ -4,8 +4,8 @@ namespace Hyde\Framework\Testing\Feature; -use Hyde\Framework\Hyde; use Hyde\Framework\Services\AssetService; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/AuthorPostsIntegrationTest.php b/packages/framework/tests/Feature/AuthorPostsIntegrationTest.php index 8a8d0e08129..2bc63aa2146 100644 --- a/packages/framework/tests/Feature/AuthorPostsIntegrationTest.php +++ b/packages/framework/tests/Feature/AuthorPostsIntegrationTest.php @@ -5,8 +5,8 @@ namespace Hyde\Framework\Testing\Feature; use Hyde\Framework\Actions\CreatesNewMarkdownPostFile; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Support\Author; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\Config; diff --git a/packages/framework/tests/Feature/BuildOutputDirectoryCanBeChangedTest.php b/packages/framework/tests/Feature/BuildOutputDirectoryCanBeChangedTest.php index d19ea7994f4..b8d7e24fa04 100644 --- a/packages/framework/tests/Feature/BuildOutputDirectoryCanBeChangedTest.php +++ b/packages/framework/tests/Feature/BuildOutputDirectoryCanBeChangedTest.php @@ -4,10 +4,10 @@ namespace Hyde\Framework\Testing\Feature; -use Hyde\Framework\Hyde; use Hyde\Framework\HydeServiceProvider; use Hyde\Framework\Models\Support\Site; use Hyde\Framework\Services\RebuildService; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\File; diff --git a/packages/framework/tests/Feature/Commands/HydeBuildRssFeedCommandTest.php b/packages/framework/tests/Feature/Commands/HydeBuildRssFeedCommandTest.php index d710b593ecc..24826a9ffaa 100644 --- a/packages/framework/tests/Feature/Commands/HydeBuildRssFeedCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeBuildRssFeedCommandTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Feature\Commands; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/Commands/HydeBuildSearchCommandTest.php b/packages/framework/tests/Feature/Commands/HydeBuildSearchCommandTest.php index 67c905d3230..867b68d923b 100644 --- a/packages/framework/tests/Feature/Commands/HydeBuildSearchCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeBuildSearchCommandTest.php @@ -5,9 +5,9 @@ namespace Hyde\Framework\Testing\Feature\Commands; use Hyde\Framework\Actions\PostBuildTasks\GenerateSearch; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Support\Site; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/Commands/HydeBuildSitemapCommandTest.php b/packages/framework/tests/Feature/Commands/HydeBuildSitemapCommandTest.php index ae34a071173..3e8007b5d48 100644 --- a/packages/framework/tests/Feature/Commands/HydeBuildSitemapCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeBuildSitemapCommandTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Feature\Commands; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/Commands/HydeMakePageCommandTest.php b/packages/framework/tests/Feature/Commands/HydeMakePageCommandTest.php index 420d3e872a8..b20970261dc 100644 --- a/packages/framework/tests/Feature/Commands/HydeMakePageCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeMakePageCommandTest.php @@ -6,7 +6,7 @@ use Exception; use Hyde\Framework\Exceptions\FileConflictException; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/Commands/HydePackageDiscoverCommandTest.php b/packages/framework/tests/Feature/Commands/HydePackageDiscoverCommandTest.php index e984cb654cc..f6cdde9fff3 100644 --- a/packages/framework/tests/Feature/Commands/HydePackageDiscoverCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydePackageDiscoverCommandTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Feature\Commands; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Foundation\PackageManifest; diff --git a/packages/framework/tests/Feature/Commands/HydePublishHomepageCommandTest.php b/packages/framework/tests/Feature/Commands/HydePublishHomepageCommandTest.php index 27493a48ba8..99a153984e5 100644 --- a/packages/framework/tests/Feature/Commands/HydePublishHomepageCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydePublishHomepageCommandTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Feature\Commands; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/Commands/HydePublishViewsCommandTest.php b/packages/framework/tests/Feature/Commands/HydePublishViewsCommandTest.php index 95d6339fd01..1b6b2f5e11a 100644 --- a/packages/framework/tests/Feature/Commands/HydePublishViewsCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydePublishViewsCommandTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Feature\Commands; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/Commands/HydeRebuildStaticSiteCommandTest.php b/packages/framework/tests/Feature/Commands/HydeRebuildStaticSiteCommandTest.php index 30273d50fc4..457ee191f46 100644 --- a/packages/framework/tests/Feature/Commands/HydeRebuildStaticSiteCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeRebuildStaticSiteCommandTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Feature\Commands; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/Commands/HydeUpdateConfigsCommandTest.php b/packages/framework/tests/Feature/Commands/HydeUpdateConfigsCommandTest.php index de59adf956c..70ed94fa9fd 100644 --- a/packages/framework/tests/Feature/Commands/HydeUpdateConfigsCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeUpdateConfigsCommandTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Feature\Commands; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\File; diff --git a/packages/framework/tests/Feature/Commands/MakePostCommandTest.php b/packages/framework/tests/Feature/Commands/MakePostCommandTest.php index be2c038189e..e4c957a5388 100644 --- a/packages/framework/tests/Feature/Commands/MakePostCommandTest.php +++ b/packages/framework/tests/Feature/Commands/MakePostCommandTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Feature\Commands; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; class MakePostCommandTest extends TestCase diff --git a/packages/framework/tests/Feature/Commands/StaticSiteBuilderPostModuleTest.php b/packages/framework/tests/Feature/Commands/StaticSiteBuilderPostModuleTest.php index 0d19bf5e096..be5c8086a61 100644 --- a/packages/framework/tests/Feature/Commands/StaticSiteBuilderPostModuleTest.php +++ b/packages/framework/tests/Feature/Commands/StaticSiteBuilderPostModuleTest.php @@ -5,8 +5,8 @@ namespace Hyde\Framework\Testing\Feature\Commands; use Hyde\Framework\Actions\StaticPageBuilder; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\MarkdownPost; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/DataCollectionTest.php b/packages/framework/tests/Feature/DataCollectionTest.php index c1d22f64a1a..88b038b849b 100644 --- a/packages/framework/tests/Feature/DataCollectionTest.php +++ b/packages/framework/tests/Feature/DataCollectionTest.php @@ -5,11 +5,11 @@ namespace Hyde\Framework\Testing\Feature; use Hyde\Framework\Helpers\Features; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Markdown\MarkdownDocument; use Hyde\Framework\Modules\DataCollections\DataCollection; use Hyde\Framework\Modules\DataCollections\DataCollectionServiceProvider; use Hyde\Framework\Modules\DataCollections\Facades\MarkdownCollection; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Foundation\AliasLoader; use Illuminate\Support\Collection; diff --git a/packages/framework/tests/Feature/DiscoveryServiceTest.php b/packages/framework/tests/Feature/DiscoveryServiceTest.php index 079fd8dc9cb..db7221c541d 100644 --- a/packages/framework/tests/Feature/DiscoveryServiceTest.php +++ b/packages/framework/tests/Feature/DiscoveryServiceTest.php @@ -5,12 +5,12 @@ namespace Hyde\Framework\Testing\Feature; use Hyde\Framework\Exceptions\UnsupportedPageTypeException; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; use Hyde\Framework\Models\Pages\MarkdownPost; use Hyde\Framework\Services\DiscoveryService; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\File; diff --git a/packages/framework/tests/Feature/FileCollectionTest.php b/packages/framework/tests/Feature/FileCollectionTest.php index d5d22ab86e7..185580a4602 100644 --- a/packages/framework/tests/Feature/FileCollectionTest.php +++ b/packages/framework/tests/Feature/FileCollectionTest.php @@ -5,12 +5,12 @@ namespace Hyde\Framework\Testing\Feature; use Hyde\Framework\Foundation\FileCollection; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; use Hyde\Framework\Models\Pages\MarkdownPost; use Hyde\Framework\Models\Support\File; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Collection; diff --git a/packages/framework/tests/Feature/FileTest.php b/packages/framework/tests/Feature/FileTest.php index 256a1e066e1..ad400c99dfa 100644 --- a/packages/framework/tests/Feature/FileTest.php +++ b/packages/framework/tests/Feature/FileTest.php @@ -4,9 +4,9 @@ namespace Hyde\Framework\Testing\Feature; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\MarkdownPage; use Hyde\Framework\Models\Support\File; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/Foundation/FilesystemTest.php b/packages/framework/tests/Feature/Foundation/FilesystemTest.php index d6026660d96..af592fca386 100644 --- a/packages/framework/tests/Feature/Foundation/FilesystemTest.php +++ b/packages/framework/tests/Feature/Foundation/FilesystemTest.php @@ -5,11 +5,11 @@ namespace Hyde\Framework\Testing\Feature\Foundation; use Hyde\Framework\Foundation\Filesystem; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; use Hyde\Framework\Models\Pages\MarkdownPost; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/HelpersTest.php b/packages/framework/tests/Feature/HelpersTest.php index 7a572f41326..ba9e4ee5260 100644 --- a/packages/framework/tests/Feature/HelpersTest.php +++ b/packages/framework/tests/Feature/HelpersTest.php @@ -4,8 +4,8 @@ namespace Hyde\Framework\Testing\Feature; -use Hyde\Framework\Hyde; use Hyde\Framework\HydeKernel; +use Hyde\Hyde; use Hyde\Testing\TestCase; class HelpersTest extends TestCase diff --git a/packages/framework/tests/Feature/HydeKernelTest.php b/packages/framework/tests/Feature/HydeKernelTest.php index 1f8b406fe82..0a75e8c956c 100644 --- a/packages/framework/tests/Feature/HydeKernelTest.php +++ b/packages/framework/tests/Feature/HydeKernelTest.php @@ -6,13 +6,13 @@ use Composer\InstalledVersions; use Hyde\Framework\Helpers\Features; -use Hyde\Framework\Hyde; use Hyde\Framework\HydeKernel; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; use Hyde\Framework\Models\Pages\MarkdownPost; use Hyde\Framework\Models\Support\Route; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\Config; use Illuminate\Support\Facades\View; @@ -22,7 +22,7 @@ * as most of the logic actually resides in linked service classes. * * @covers \Hyde\Framework\HydeKernel - * @covers \Hyde\Framework\Hyde + * @covers \Hyde\Hyde * * @see \Hyde\Framework\Testing\Unit\HydeHelperFacadeMakeTitleTest */ diff --git a/packages/framework/tests/Feature/HydePageTest.php b/packages/framework/tests/Feature/HydePageTest.php index c156ff5fc02..869bf7fe982 100644 --- a/packages/framework/tests/Feature/HydePageTest.php +++ b/packages/framework/tests/Feature/HydePageTest.php @@ -6,13 +6,13 @@ use Hyde\Framework\Concerns\BaseMarkdownPage; use Hyde\Framework\Concerns\HydePage; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Markdown\Markdown; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; use Hyde\Framework\Models\Pages\MarkdownPost; use Hyde\Framework\Models\Support\Route; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/IncludesFacadeTest.php b/packages/framework/tests/Feature/IncludesFacadeTest.php index f530eea7b21..fa4eaa0a1ba 100644 --- a/packages/framework/tests/Feature/IncludesFacadeTest.php +++ b/packages/framework/tests/Feature/IncludesFacadeTest.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Testing\Feature; use Hyde\Framework\Helpers\Includes; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\File; diff --git a/packages/framework/tests/Feature/MarkdownFileParserTest.php b/packages/framework/tests/Feature/MarkdownFileParserTest.php index aab72451d42..14373b48716 100644 --- a/packages/framework/tests/Feature/MarkdownFileParserTest.php +++ b/packages/framework/tests/Feature/MarkdownFileParserTest.php @@ -5,9 +5,9 @@ namespace Hyde\Framework\Testing\Feature; use Hyde\Framework\Actions\MarkdownFileParser; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Markdown\FrontMatter; use Hyde\Framework\Models\Markdown\MarkdownDocument; +use Hyde\Hyde; use Hyde\Testing\TestCase; class MarkdownFileParserTest extends TestCase diff --git a/packages/framework/tests/Feature/MarkdownPageTest.php b/packages/framework/tests/Feature/MarkdownPageTest.php index 71d3dc95420..de075e31f32 100644 --- a/packages/framework/tests/Feature/MarkdownPageTest.php +++ b/packages/framework/tests/Feature/MarkdownPageTest.php @@ -4,9 +4,9 @@ namespace Hyde\Framework\Testing\Feature; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\MarkdownPage; use Hyde\Framework\Services\DiscoveryService; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\File; diff --git a/packages/framework/tests/Feature/MetadataViewTest.php b/packages/framework/tests/Feature/MetadataViewTest.php index 44fe3283dd1..517de89d529 100644 --- a/packages/framework/tests/Feature/MetadataViewTest.php +++ b/packages/framework/tests/Feature/MetadataViewTest.php @@ -4,8 +4,8 @@ namespace Hyde\Framework\Testing\Feature; -use Hyde\Framework\Hyde; use Hyde\Framework\HydeKernel; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/NavigationMenuTest.php b/packages/framework/tests/Feature/NavigationMenuTest.php index 17f91eecdff..6d63b0f69f0 100644 --- a/packages/framework/tests/Feature/NavigationMenuTest.php +++ b/packages/framework/tests/Feature/NavigationMenuTest.php @@ -4,10 +4,10 @@ namespace Hyde\Framework\Testing\Feature; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Navigation\NavigationMenu; use Hyde\Framework\Models\Navigation\NavItem; use Hyde\Framework\Models\Support\Route; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Collection; diff --git a/packages/framework/tests/Feature/PageCollectionTest.php b/packages/framework/tests/Feature/PageCollectionTest.php index 5fb01794bf6..e32c3f0eaf8 100644 --- a/packages/framework/tests/Feature/PageCollectionTest.php +++ b/packages/framework/tests/Feature/PageCollectionTest.php @@ -5,11 +5,11 @@ namespace Hyde\Framework\Testing\Feature; use Hyde\Framework\Foundation\PageCollection; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; use Hyde\Framework\Models\Pages\MarkdownPost; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Collection; use Illuminate\Support\Facades\File; diff --git a/packages/framework/tests/Feature/PageModelConstructorsTest.php b/packages/framework/tests/Feature/PageModelConstructorsTest.php index fb2d13c125e..f5e910d9a4e 100644 --- a/packages/framework/tests/Feature/PageModelConstructorsTest.php +++ b/packages/framework/tests/Feature/PageModelConstructorsTest.php @@ -4,9 +4,9 @@ namespace Hyde\Framework\Testing\Feature; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/RedirectTest.php b/packages/framework/tests/Feature/RedirectTest.php index 4983f06625b..66fdabfc207 100644 --- a/packages/framework/tests/Feature/RedirectTest.php +++ b/packages/framework/tests/Feature/RedirectTest.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Testing\Feature; use Hyde\Framework\Helpers\Redirect; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/RouteCollectionTest.php b/packages/framework/tests/Feature/RouteCollectionTest.php index fc0758d4b5c..0d64d6f6b30 100644 --- a/packages/framework/tests/Feature/RouteCollectionTest.php +++ b/packages/framework/tests/Feature/RouteCollectionTest.php @@ -5,12 +5,12 @@ namespace Hyde\Framework\Testing\Feature; use Hyde\Framework\Foundation\RouteCollection; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; use Hyde\Framework\Models\Pages\MarkdownPost; use Hyde\Framework\Models\Support\Route; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Collection; diff --git a/packages/framework/tests/Feature/RouteTest.php b/packages/framework/tests/Feature/RouteTest.php index 8326934c0a0..3d8b9d2c4b9 100644 --- a/packages/framework/tests/Feature/RouteTest.php +++ b/packages/framework/tests/Feature/RouteTest.php @@ -6,12 +6,12 @@ use Hyde\Framework\Exceptions\BaseUrlNotSetException; use Hyde\Framework\Exceptions\RouteNotFoundException; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; use Hyde\Framework\Models\Pages\MarkdownPost; use Hyde\Framework\Models\Support\Route; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/Services/BuildTaskServiceTest.php b/packages/framework/tests/Feature/Services/BuildTaskServiceTest.php index 454a8aba2e1..ef039917c1c 100644 --- a/packages/framework/tests/Feature/Services/BuildTaskServiceTest.php +++ b/packages/framework/tests/Feature/Services/BuildTaskServiceTest.php @@ -5,8 +5,8 @@ namespace Hyde\Framework\Testing\Feature\Services; use Hyde\Framework\Concerns\AbstractBuildTask; -use Hyde\Framework\Hyde; use Hyde\Framework\Services\BuildTaskService; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\File; diff --git a/packages/framework/tests/Feature/Services/ChecksumServiceTest.php b/packages/framework/tests/Feature/Services/ChecksumServiceTest.php index c9314132c22..e04cc1d02df 100644 --- a/packages/framework/tests/Feature/Services/ChecksumServiceTest.php +++ b/packages/framework/tests/Feature/Services/ChecksumServiceTest.php @@ -4,8 +4,8 @@ namespace Hyde\Framework\Testing\Feature\Services; -use Hyde\Framework\Hyde; use Hyde\Framework\Services\ChecksumService; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/Services/DocumentationSearchServiceTest.php b/packages/framework/tests/Feature/Services/DocumentationSearchServiceTest.php index 226ef4225e1..c013228b181 100644 --- a/packages/framework/tests/Feature/Services/DocumentationSearchServiceTest.php +++ b/packages/framework/tests/Feature/Services/DocumentationSearchServiceTest.php @@ -4,9 +4,9 @@ namespace Hyde\Framework\Testing\Feature\Services; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Services\DocumentationSearchService as Service; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/Services/DocumentationSidebarTest.php b/packages/framework/tests/Feature/Services/DocumentationSidebarTest.php index 20830de3e28..c2c779a41c4 100644 --- a/packages/framework/tests/Feature/Services/DocumentationSidebarTest.php +++ b/packages/framework/tests/Feature/Services/DocumentationSidebarTest.php @@ -5,10 +5,10 @@ namespace Hyde\Framework\Testing\Feature\Services; use Hyde\Framework\Actions\ConvertsArrayToFrontMatter; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Navigation\DocumentationSidebar; use Hyde\Framework\Models\Navigation\NavItem; use Hyde\Framework\Models\Support\Route; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\Config; use Illuminate\Support\Facades\File; diff --git a/packages/framework/tests/Feature/Services/HydeSmartDocsTest.php b/packages/framework/tests/Feature/Services/HydeSmartDocsTest.php index e08b9e5159e..42e2ec17361 100644 --- a/packages/framework/tests/Feature/Services/HydeSmartDocsTest.php +++ b/packages/framework/tests/Feature/Services/HydeSmartDocsTest.php @@ -4,10 +4,10 @@ namespace Hyde\Framework\Testing\Feature\Services; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Markdown\Markdown; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Services\SemanticDocumentationArticle; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/Services/RssFeedServiceTest.php b/packages/framework/tests/Feature/Services/RssFeedServiceTest.php index bc76cccfe12..55816480958 100644 --- a/packages/framework/tests/Feature/Services/RssFeedServiceTest.php +++ b/packages/framework/tests/Feature/Services/RssFeedServiceTest.php @@ -5,8 +5,8 @@ namespace Hyde\Framework\Testing\Feature\Services; use Hyde\Framework\Helpers\Features; -use Hyde\Framework\Hyde; use Hyde\Framework\Services\RssFeedService; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/Services/SitemapServiceTest.php b/packages/framework/tests/Feature/Services/SitemapServiceTest.php index 185e8eca2fa..e27a09d4a96 100644 --- a/packages/framework/tests/Feature/Services/SitemapServiceTest.php +++ b/packages/framework/tests/Feature/Services/SitemapServiceTest.php @@ -4,8 +4,8 @@ namespace Hyde\Framework\Testing\Feature\Services; -use Hyde\Framework\Hyde; use Hyde\Framework\Services\SitemapService; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\File; diff --git a/packages/framework/tests/Feature/Services/ValidationServiceTest.php b/packages/framework/tests/Feature/Services/ValidationServiceTest.php index 755ba5c88ac..6fd2a11bb7d 100644 --- a/packages/framework/tests/Feature/Services/ValidationServiceTest.php +++ b/packages/framework/tests/Feature/Services/ValidationServiceTest.php @@ -4,9 +4,9 @@ namespace Hyde\Framework\Testing\Feature\Services; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Support\ValidationResult; use Hyde\Framework\Services\ValidationService; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/SourceDirectoriesCanBeChangedTest.php b/packages/framework/tests/Feature/SourceDirectoriesCanBeChangedTest.php index 2d35687bd80..77d6b6f0dbe 100644 --- a/packages/framework/tests/Feature/SourceDirectoriesCanBeChangedTest.php +++ b/packages/framework/tests/Feature/SourceDirectoriesCanBeChangedTest.php @@ -4,12 +4,12 @@ namespace Hyde\Framework\Testing\Feature; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; use Hyde\Framework\Models\Pages\MarkdownPost; use Hyde\Framework\Services\DiscoveryService; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/StaticPageBuilderTest.php b/packages/framework/tests/Feature/StaticPageBuilderTest.php index 37e4ac1ff25..2c0150aebf5 100644 --- a/packages/framework/tests/Feature/StaticPageBuilderTest.php +++ b/packages/framework/tests/Feature/StaticPageBuilderTest.php @@ -5,7 +5,6 @@ namespace Hyde\Framework\Testing\Feature; use Hyde\Framework\Actions\StaticPageBuilder; -use Hyde\Framework\Hyde; use Hyde\Framework\HydeServiceProvider; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; @@ -13,6 +12,7 @@ use Hyde\Framework\Models\Pages\MarkdownPage; use Hyde\Framework\Models\Pages\MarkdownPost; use Hyde\Framework\Models\Support\Site; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\Config; use Illuminate\Support\Facades\File; diff --git a/packages/framework/tests/Feature/StaticSiteServiceTest.php b/packages/framework/tests/Feature/StaticSiteServiceTest.php index 5ab3d3c0b11..60f3460129c 100644 --- a/packages/framework/tests/Feature/StaticSiteServiceTest.php +++ b/packages/framework/tests/Feature/StaticSiteServiceTest.php @@ -4,8 +4,8 @@ namespace Hyde\Framework\Testing\Feature; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Support\Site; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\File; diff --git a/packages/framework/tests/Unit/BlogPostFrontMatterIsOptionalTest.php b/packages/framework/tests/Unit/BlogPostFrontMatterIsOptionalTest.php index 60457b8aa04..3d470195aab 100644 --- a/packages/framework/tests/Unit/BlogPostFrontMatterIsOptionalTest.php +++ b/packages/framework/tests/Unit/BlogPostFrontMatterIsOptionalTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Unit; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\Artisan; diff --git a/packages/framework/tests/Unit/DocumentationPageTest.php b/packages/framework/tests/Unit/DocumentationPageTest.php index 5d7e6c0bc24..6ba72fb4f39 100644 --- a/packages/framework/tests/Unit/DocumentationPageTest.php +++ b/packages/framework/tests/Unit/DocumentationPageTest.php @@ -4,10 +4,10 @@ namespace Hyde\Framework\Testing\Unit; -use Hyde\Framework\Hyde; use Hyde\Framework\HydeServiceProvider; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Support\Route; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\Config; use Illuminate\Support\Facades\File; diff --git a/packages/framework/tests/Unit/Foundation/HyperlinkFileHelperRelativeLinkTest.php b/packages/framework/tests/Unit/Foundation/HyperlinkFileHelperRelativeLinkTest.php index 37947a4b52f..31363e22232 100644 --- a/packages/framework/tests/Unit/Foundation/HyperlinkFileHelperRelativeLinkTest.php +++ b/packages/framework/tests/Unit/Foundation/HyperlinkFileHelperRelativeLinkTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Unit\Foundation; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Unit/Foundation/HyperlinkFormatHtmlPathTest.php b/packages/framework/tests/Unit/Foundation/HyperlinkFormatHtmlPathTest.php index fbcf18e96ae..06e7295a806 100644 --- a/packages/framework/tests/Unit/Foundation/HyperlinkFormatHtmlPathTest.php +++ b/packages/framework/tests/Unit/Foundation/HyperlinkFormatHtmlPathTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Unit\Foundation; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Unit/GenerateBuildManifestTest.php b/packages/framework/tests/Unit/GenerateBuildManifestTest.php index 6b4e9e96ada..8834e8b28d1 100644 --- a/packages/framework/tests/Unit/GenerateBuildManifestTest.php +++ b/packages/framework/tests/Unit/GenerateBuildManifestTest.php @@ -5,8 +5,8 @@ namespace Hyde\Framework\Testing\Unit; use Hyde\Framework\Actions\PostBuildTasks\GenerateBuildManifest; -use Hyde\Framework\Hyde; use Hyde\Framework\Services\ChecksumService; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Unit/GetLatestMarkdownPostsTest.php b/packages/framework/tests/Unit/GetLatestMarkdownPostsTest.php index 8cddecfbc82..e7f0a82ed38 100644 --- a/packages/framework/tests/Unit/GetLatestMarkdownPostsTest.php +++ b/packages/framework/tests/Unit/GetLatestMarkdownPostsTest.php @@ -4,8 +4,8 @@ namespace Hyde\Framework\Testing\Unit; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\MarkdownPost; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Collection; diff --git a/packages/framework/tests/Unit/HydeBasePathCanBeChangedTest.php b/packages/framework/tests/Unit/HydeBasePathCanBeChangedTest.php index d0531251f26..93b5e110f1e 100644 --- a/packages/framework/tests/Unit/HydeBasePathCanBeChangedTest.php +++ b/packages/framework/tests/Unit/HydeBasePathCanBeChangedTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Unit; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Unit/HydeConfigFilesAreMatchingTest.php b/packages/framework/tests/Unit/HydeConfigFilesAreMatchingTest.php index c2bfbabdda5..3b398a979bc 100644 --- a/packages/framework/tests/Unit/HydeConfigFilesAreMatchingTest.php +++ b/packages/framework/tests/Unit/HydeConfigFilesAreMatchingTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Unit; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; use PHPUnit\Framework\Constraint\IsEqual; diff --git a/packages/framework/tests/Unit/HydeFileHelpersTest.php b/packages/framework/tests/Unit/HydeFileHelpersTest.php index 3985c18767b..adbd3c56221 100644 --- a/packages/framework/tests/Unit/HydeFileHelpersTest.php +++ b/packages/framework/tests/Unit/HydeFileHelpersTest.php @@ -4,8 +4,8 @@ namespace Hyde\Framework\Testing\Unit; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Support\Route; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Unit/HydeGetBasePathHasFallbackTest.php b/packages/framework/tests/Unit/HydeGetBasePathHasFallbackTest.php index dfbdfa029f0..a811a2868e0 100644 --- a/packages/framework/tests/Unit/HydeGetBasePathHasFallbackTest.php +++ b/packages/framework/tests/Unit/HydeGetBasePathHasFallbackTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Unit; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Unit/HydeHelperFacadeMakeTitleTest.php b/packages/framework/tests/Unit/HydeHelperFacadeMakeTitleTest.php index 98c68e24bf6..cbd872e3a65 100644 --- a/packages/framework/tests/Unit/HydeHelperFacadeMakeTitleTest.php +++ b/packages/framework/tests/Unit/HydeHelperFacadeMakeTitleTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Unit; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; class HydeHelperFacadeMakeTitleTest extends TestCase diff --git a/packages/framework/tests/Unit/HydeHelperFacadeTest.php b/packages/framework/tests/Unit/HydeHelperFacadeTest.php index c5ea0611b53..f6ecb0a835f 100644 --- a/packages/framework/tests/Unit/HydeHelperFacadeTest.php +++ b/packages/framework/tests/Unit/HydeHelperFacadeTest.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Testing\Unit; use Hyde\Framework\Helpers\Features; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Unit/HydePathHelperTest.php b/packages/framework/tests/Unit/HydePathHelperTest.php index 3e846b3b569..65cef938b33 100644 --- a/packages/framework/tests/Unit/HydePathHelperTest.php +++ b/packages/framework/tests/Unit/HydePathHelperTest.php @@ -4,8 +4,8 @@ namespace Hyde\Framework\Testing\Unit; -use Hyde\Framework\Hyde; use Hyde\Framework\HydeKernel; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Unit/HydeServiceProviderTest.php b/packages/framework/tests/Unit/HydeServiceProviderTest.php index e1ccf7f5ba4..8adb469ef30 100644 --- a/packages/framework/tests/Unit/HydeServiceProviderTest.php +++ b/packages/framework/tests/Unit/HydeServiceProviderTest.php @@ -4,7 +4,6 @@ namespace Hyde\Framework\Testing\Unit; -use Hyde\Framework\Hyde; use Hyde\Framework\HydeServiceProvider; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; @@ -13,6 +12,7 @@ use Hyde\Framework\Models\Support\Site; use Hyde\Framework\Modules\DataCollections\DataCollectionServiceProvider; use Hyde\Framework\Services\AssetService; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\Artisan; diff --git a/packages/framework/tests/Unit/HydeVendorPathHelperTest.php b/packages/framework/tests/Unit/HydeVendorPathHelperTest.php index 6520f6c87a5..a23506b7ede 100644 --- a/packages/framework/tests/Unit/HydeVendorPathHelperTest.php +++ b/packages/framework/tests/Unit/HydeVendorPathHelperTest.php @@ -4,8 +4,8 @@ namespace Hyde\Framework\Testing\Unit; -use Hyde\Framework\Hyde; use Hyde\Framework\HydeKernel; +use Hyde\Hyde; use Hyde\Testing\TestCase; class HydeVendorPathHelperTest extends TestCase diff --git a/packages/framework/tests/Unit/InteractsWithDirectoriesConcernTest.php b/packages/framework/tests/Unit/InteractsWithDirectoriesConcernTest.php index d8f41cc58c0..77aa529ae82 100644 --- a/packages/framework/tests/Unit/InteractsWithDirectoriesConcernTest.php +++ b/packages/framework/tests/Unit/InteractsWithDirectoriesConcernTest.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Testing\Unit; use Hyde\Framework\Concerns\InteractsWithDirectories; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\File; diff --git a/packages/framework/tests/Unit/MarkdownDocumentTest.php b/packages/framework/tests/Unit/MarkdownDocumentTest.php index 39edf339fb8..4378ab90a30 100644 --- a/packages/framework/tests/Unit/MarkdownDocumentTest.php +++ b/packages/framework/tests/Unit/MarkdownDocumentTest.php @@ -4,10 +4,10 @@ namespace Hyde\Framework\Testing\Unit; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Markdown\FrontMatter; use Hyde\Framework\Models\Markdown\Markdown; use Hyde\Framework\Models\Markdown\MarkdownDocument; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Unit/MarkdownPostParserTest.php b/packages/framework/tests/Unit/MarkdownPostParserTest.php index 99b30398979..0d5f81c6fc1 100644 --- a/packages/framework/tests/Unit/MarkdownPostParserTest.php +++ b/packages/framework/tests/Unit/MarkdownPostParserTest.php @@ -4,10 +4,10 @@ namespace Hyde\Framework\Testing\Unit; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Markdown\FrontMatter; use Hyde\Framework\Models\Markdown\Markdown; use Hyde\Framework\Models\Pages\MarkdownPost; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Unit/PageModelGetAllFilesHelperTest.php b/packages/framework/tests/Unit/PageModelGetAllFilesHelperTest.php index ad267a912d3..7f2f124e61c 100644 --- a/packages/framework/tests/Unit/PageModelGetAllFilesHelperTest.php +++ b/packages/framework/tests/Unit/PageModelGetAllFilesHelperTest.php @@ -4,11 +4,11 @@ namespace Hyde\Framework\Testing\Unit; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; use Hyde\Framework\Models\Pages\MarkdownPost; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Unit/PageModelGetHelperTest.php b/packages/framework/tests/Unit/PageModelGetHelperTest.php index cba529a08fb..6f3be829cda 100644 --- a/packages/framework/tests/Unit/PageModelGetHelperTest.php +++ b/packages/framework/tests/Unit/PageModelGetHelperTest.php @@ -4,11 +4,11 @@ namespace Hyde\Framework\Testing\Unit; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; use Hyde\Framework\Models\Pages\MarkdownPost; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Collection; diff --git a/packages/framework/tests/Unit/PageModelParseHelperTest.php b/packages/framework/tests/Unit/PageModelParseHelperTest.php index acdb9011f77..bcc75f01bf1 100644 --- a/packages/framework/tests/Unit/PageModelParseHelperTest.php +++ b/packages/framework/tests/Unit/PageModelParseHelperTest.php @@ -4,11 +4,11 @@ namespace Hyde\Framework\Testing\Unit; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; use Hyde\Framework\Models\Pages\MarkdownPost; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Unit/RelativeLinksAcrossPagesRetainsIntegrityTest.php b/packages/framework/tests/Unit/RelativeLinksAcrossPagesRetainsIntegrityTest.php index abc8fdb5406..4366d2d12e8 100644 --- a/packages/framework/tests/Unit/RelativeLinksAcrossPagesRetainsIntegrityTest.php +++ b/packages/framework/tests/Unit/RelativeLinksAcrossPagesRetainsIntegrityTest.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Testing\Unit; use Hyde\Framework\Concerns\InteractsWithDirectories; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\File; diff --git a/packages/framework/tests/Unit/SourceFilesInCustomDirectoriesCanBeCompiledTest.php b/packages/framework/tests/Unit/SourceFilesInCustomDirectoriesCanBeCompiledTest.php index cfc9134921a..63337682905 100644 --- a/packages/framework/tests/Unit/SourceFilesInCustomDirectoriesCanBeCompiledTest.php +++ b/packages/framework/tests/Unit/SourceFilesInCustomDirectoriesCanBeCompiledTest.php @@ -5,11 +5,11 @@ namespace Hyde\Framework\Testing\Unit; use Hyde\Framework\Actions\StaticPageBuilder; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; use Hyde\Framework\Models\Pages\MarkdownPost; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\Config; use Illuminate\Support\Facades\File; diff --git a/packages/framework/tests/Unit/TestBuildStaticSiteCommandFlagToEnablePrettyUrlsTest.php b/packages/framework/tests/Unit/TestBuildStaticSiteCommandFlagToEnablePrettyUrlsTest.php index c52c1ace911..d4e1e4984e4 100644 --- a/packages/framework/tests/Unit/TestBuildStaticSiteCommandFlagToEnablePrettyUrlsTest.php +++ b/packages/framework/tests/Unit/TestBuildStaticSiteCommandFlagToEnablePrettyUrlsTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Unit; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\File; diff --git a/packages/framework/tests/Unit/Views/ArticleExcerptViewTest.php b/packages/framework/tests/Unit/Views/ArticleExcerptViewTest.php index 4a7efe4d901..d4c166188db 100644 --- a/packages/framework/tests/Unit/Views/ArticleExcerptViewTest.php +++ b/packages/framework/tests/Unit/Views/ArticleExcerptViewTest.php @@ -4,8 +4,8 @@ namespace Hyde\Framework\Testing\Unit\Views; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\MarkdownPost; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\Blade; diff --git a/packages/framework/tests/Unit/Views/NavigationMenuViewTest.php b/packages/framework/tests/Unit/Views/NavigationMenuViewTest.php index a46f69f7daf..d348e71939d 100644 --- a/packages/framework/tests/Unit/Views/NavigationMenuViewTest.php +++ b/packages/framework/tests/Unit/Views/NavigationMenuViewTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Unit\Views; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Unit/Views/ScriptsComponentViewTest.php b/packages/framework/tests/Unit/Views/ScriptsComponentViewTest.php index eee5c9570f2..7c1214d319b 100644 --- a/packages/framework/tests/Unit/Views/ScriptsComponentViewTest.php +++ b/packages/framework/tests/Unit/Views/ScriptsComponentViewTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Unit\Views; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\Blade; diff --git a/packages/framework/tests/Unit/Views/StylesComponentViewTest.php b/packages/framework/tests/Unit/Views/StylesComponentViewTest.php index f39b2ccd865..67f86c5b1ce 100644 --- a/packages/framework/tests/Unit/Views/StylesComponentViewTest.php +++ b/packages/framework/tests/Unit/Views/StylesComponentViewTest.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Testing\Unit\Views; use Hyde\Framework\Helpers\Asset; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\Blade; diff --git a/packages/realtime-compiler/src/Actions/RendersSearchPage.php b/packages/realtime-compiler/src/Actions/RendersSearchPage.php index f783d03dc96..18b8ae34aea 100644 --- a/packages/realtime-compiler/src/Actions/RendersSearchPage.php +++ b/packages/realtime-compiler/src/Actions/RendersSearchPage.php @@ -2,7 +2,7 @@ namespace Hyde\RealtimeCompiler\Actions; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\RealtimeCompiler\Concerns\InteractsWithLaravel; use Illuminate\Support\Facades\Blade; diff --git a/packages/testing/src/CreatesApplication.php b/packages/testing/src/CreatesApplication.php index 8f5e25c0156..e480a8d7a24 100644 --- a/packages/testing/src/CreatesApplication.php +++ b/packages/testing/src/CreatesApplication.php @@ -2,8 +2,8 @@ namespace Hyde\Testing; -use Hyde\Framework\Hyde; use Hyde\Framework\HydeKernel; +use Hyde\Hyde; use Illuminate\Contracts\Console\Kernel; use Illuminate\Foundation\Application; diff --git a/packages/testing/src/ResetsApplication.php b/packages/testing/src/ResetsApplication.php index 040ae5b73f6..eacdee6698d 100644 --- a/packages/testing/src/ResetsApplication.php +++ b/packages/testing/src/ResetsApplication.php @@ -2,7 +2,7 @@ namespace Hyde\Testing; -use Hyde\Framework\Hyde; +use Hyde\Hyde; /** * @internal diff --git a/packages/testing/src/TestCase.php b/packages/testing/src/TestCase.php index 9d89eafa364..7209185bc94 100644 --- a/packages/testing/src/TestCase.php +++ b/packages/testing/src/TestCase.php @@ -4,9 +4,9 @@ use Hyde\Framework\Actions\ConvertsArrayToFrontMatter; use Hyde\Framework\Concerns\HydePage; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\MarkdownPage; use Hyde\Framework\Models\Support\Route; +use Hyde\Hyde; use Illuminate\View\Component; use LaravelZero\Framework\Testing\TestCase as BaseTestCase; diff --git a/projects/shelf/admin/src/AdminServiceProvider.php b/projects/shelf/admin/src/AdminServiceProvider.php index f5b7dd1450e..5e71791df80 100644 --- a/projects/shelf/admin/src/AdminServiceProvider.php +++ b/projects/shelf/admin/src/AdminServiceProvider.php @@ -2,7 +2,7 @@ namespace Hyde\Admin; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Illuminate\Support\ServiceProvider; class AdminServiceProvider extends ServiceProvider diff --git a/projects/shelf/single-file-dashboard/dashboard.php b/projects/shelf/single-file-dashboard/dashboard.php index 0f77f32537d..0b608c757ac 100644 --- a/projects/shelf/single-file-dashboard/dashboard.php +++ b/projects/shelf/single-file-dashboard/dashboard.php @@ -12,12 +12,12 @@ use Hyde\Framework\Exceptions\FileNotFoundException; use Hyde\Framework\Exceptions\UnsupportedPageTypeException; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\BladePage; use Hyde\Framework\Models\DocumentationPage; use Hyde\Framework\Models\MarkdownPage; use Hyde\Framework\Models\MarkdownPost; use Hyde\Framework\Services\DiscoveryService; +use Hyde\Hyde; const VERSION = 'dev-master'; diff --git a/tests/Benchmarks/PageParserBenchmark.php b/tests/Benchmarks/PageParserBenchmark.php index b2e37f920f0..9670e243e87 100644 --- a/tests/Benchmarks/PageParserBenchmark.php +++ b/tests/Benchmarks/PageParserBenchmark.php @@ -4,11 +4,11 @@ namespace Tests\Benchmarks; -use Hyde\Framework\Hyde; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; use Hyde\Framework\Models\Pages\MarkdownPost; +use Hyde\Hyde; use Tests\Benchmarks\CBench\Benchmark; class PageParserBenchmark extends BenchCase diff --git a/tests/Benchmarks/SearchIndexBenchmark.php b/tests/Benchmarks/SearchIndexBenchmark.php index 47c34e8fdda..2f396d766d6 100644 --- a/tests/Benchmarks/SearchIndexBenchmark.php +++ b/tests/Benchmarks/SearchIndexBenchmark.php @@ -4,7 +4,7 @@ namespace Tests\Benchmarks; -use Hyde\Framework\Hyde; +use Hyde\Hyde; class SearchIndexBenchmark extends BenchCase { diff --git a/tests/Benchmarks/StaticSiteBuilderBenchmark.php b/tests/Benchmarks/StaticSiteBuilderBenchmark.php index 8f88fdc344f..7de145fce35 100644 --- a/tests/Benchmarks/StaticSiteBuilderBenchmark.php +++ b/tests/Benchmarks/StaticSiteBuilderBenchmark.php @@ -4,7 +4,7 @@ namespace Tests\Benchmarks; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Tests\Benchmarks\CBench\Benchmark; class StaticSiteBuilderBenchmark extends BenchCase diff --git a/tests/Browser/HighLevelViewTest.php b/tests/Browser/HighLevelViewTest.php index efec3f6e950..d1c1850ed64 100644 --- a/tests/Browser/HighLevelViewTest.php +++ b/tests/Browser/HighLevelViewTest.php @@ -5,7 +5,7 @@ namespace Hyde\Testing\Browser; use Hyde\Framework\Actions\ConvertsArrayToFrontMatter; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\DuskTestCase; use Illuminate\Support\Str; use Laravel\Dusk\Browser; diff --git a/tests/Hyde/Feature/DefaultContentTest.php b/tests/Hyde/Feature/DefaultContentTest.php index 89d8115c7ab..cceda6bd319 100644 --- a/tests/Hyde/Feature/DefaultContentTest.php +++ b/tests/Hyde/Feature/DefaultContentTest.php @@ -4,7 +4,7 @@ namespace Hyde\Testing\Hyde\Feature; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; class DefaultContentTest extends TestCase diff --git a/tests/Hyde/Feature/StaticSiteBuilderTest.php b/tests/Hyde/Feature/StaticSiteBuilderTest.php index c06a1f1faf8..07b8e70934d 100644 --- a/tests/Hyde/Feature/StaticSiteBuilderTest.php +++ b/tests/Hyde/Feature/StaticSiteBuilderTest.php @@ -4,7 +4,7 @@ namespace Hyde\Testing\Hyde\Feature; -use Hyde\Framework\Hyde; +use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\File; From 60d931811c4b8b5ac3f825529c9c3769ad05c6f9 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 19:07:58 +0200 Subject: [PATCH 006/768] Move Foundation namespace to root Hyde namespace --- app/bootstrap.php | 2 +- .../Foundation/Application.php | 2 +- .../Concerns/BaseFoundationCollection.php | 8 +++---- .../Concerns/ForwardsFilesystem.php | 2 +- .../Concerns/ForwardsHyperlinks.php | 2 +- .../Concerns/HandlesFoundationCollections.php | 8 +++---- .../Concerns/ImplementsStringHelpers.php | 2 +- .../Foundation/Concerns/ManagesHydeKernel.php | 8 +++---- .../Foundation/Concerns/ManagesViewData.php | 2 +- .../Foundation/FileCollection.php | 4 ++-- .../{Framework => }/Foundation/Filesystem.php | 2 +- .../{Framework => }/Foundation/Hyperlinks.php | 2 +- .../Foundation/PageCollection.php | 6 ++--- .../Foundation/RouteCollection.php | 6 ++--- .../src/Framework/Concerns/HydePage.php | 4 ++-- .../framework/src/Framework/HydeKernel.php | 24 +++++++++---------- .../Framework/Models/Pages/MarkdownPost.php | 4 ++-- .../src/Framework/Models/Support/Route.php | 4 ++-- .../src/Framework/Services/BuildService.php | 4 ++-- packages/framework/src/Hyde.php | 6 ++--- .../tests/Feature/FileCollectionTest.php | 6 ++--- .../Feature/Foundation/FilesystemTest.php | 8 +++---- .../Feature/Foundation/HyperlinksTest.php | 7 +++--- .../tests/Feature/PageCollectionTest.php | 6 ++--- .../tests/Feature/RouteCollectionTest.php | 6 ++--- .../HyperlinkFileHelperRelativeLinkTest.php | 2 +- .../HyperlinkFormatHtmlPathTest.php | 2 +- .../HyperlinksUrlPathHelpersTest.php | 6 ++--- 28 files changed, 72 insertions(+), 73 deletions(-) rename packages/framework/src/{Framework => }/Foundation/Application.php (94%) rename packages/framework/src/{Framework => }/Foundation/Concerns/BaseFoundationCollection.php (78%) rename packages/framework/src/{Framework => }/Foundation/Concerns/ForwardsFilesystem.php (97%) rename packages/framework/src/{Framework => }/Foundation/Concerns/ForwardsHyperlinks.php (94%) rename packages/framework/src/{Framework => }/Foundation/Concerns/HandlesFoundationCollections.php (78%) rename packages/framework/src/{Framework => }/Foundation/Concerns/ImplementsStringHelpers.php (91%) rename packages/framework/src/{Framework => }/Foundation/Concerns/ManagesHydeKernel.php (82%) rename packages/framework/src/{Framework => }/Foundation/Concerns/ManagesViewData.php (95%) rename packages/framework/src/{Framework => }/Foundation/FileCollection.php (96%) rename packages/framework/src/{Framework => }/Foundation/Filesystem.php (99%) rename packages/framework/src/{Framework => }/Foundation/Hyperlinks.php (98%) rename packages/framework/src/{Framework => }/Foundation/PageCollection.php (94%) rename packages/framework/src/{Framework => }/Foundation/RouteCollection.php (93%) diff --git a/app/bootstrap.php b/app/bootstrap.php index d09863a99f5..c9f44913394 100644 --- a/app/bootstrap.php +++ b/app/bootstrap.php @@ -11,7 +11,7 @@ | */ -$app = new \Hyde\Framework\Foundation\Application( +$app = new \Hyde\Foundation\Application( dirname(__DIR__) ); diff --git a/packages/framework/src/Framework/Foundation/Application.php b/packages/framework/src/Foundation/Application.php similarity index 94% rename from packages/framework/src/Framework/Foundation/Application.php rename to packages/framework/src/Foundation/Application.php index 00f0a6bf7f6..3ae96e00df9 100644 --- a/packages/framework/src/Framework/Foundation/Application.php +++ b/packages/framework/src/Foundation/Application.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Foundation; +namespace Hyde\Foundation; use Illuminate\Filesystem\Filesystem; use Illuminate\Foundation\PackageManifest; diff --git a/packages/framework/src/Framework/Foundation/Concerns/BaseFoundationCollection.php b/packages/framework/src/Foundation/Concerns/BaseFoundationCollection.php similarity index 78% rename from packages/framework/src/Framework/Foundation/Concerns/BaseFoundationCollection.php rename to packages/framework/src/Foundation/Concerns/BaseFoundationCollection.php index 6a006d23c35..fde7ff46a19 100644 --- a/packages/framework/src/Framework/Foundation/Concerns/BaseFoundationCollection.php +++ b/packages/framework/src/Foundation/Concerns/BaseFoundationCollection.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Foundation\Concerns; +namespace Hyde\Foundation\Concerns; use Hyde\Framework\HydeKernel; use Illuminate\Support\Collection; @@ -10,9 +10,9 @@ /** * @internal Base class for the kernel auto-discovery collections. * - * @see \Hyde\Framework\Foundation\FileCollection - * @see \Hyde\Framework\Foundation\PageCollection - * @see \Hyde\Framework\Foundation\RouteCollection + * @see \Hyde\Foundation\FileCollection + * @see \Hyde\Foundation\PageCollection + * @see \Hyde\Foundation\RouteCollection */ abstract class BaseFoundationCollection extends Collection { diff --git a/packages/framework/src/Framework/Foundation/Concerns/ForwardsFilesystem.php b/packages/framework/src/Foundation/Concerns/ForwardsFilesystem.php similarity index 97% rename from packages/framework/src/Framework/Foundation/Concerns/ForwardsFilesystem.php rename to packages/framework/src/Foundation/Concerns/ForwardsFilesystem.php index 9af2db15641..974697cc550 100644 --- a/packages/framework/src/Framework/Foundation/Concerns/ForwardsFilesystem.php +++ b/packages/framework/src/Foundation/Concerns/ForwardsFilesystem.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Foundation\Concerns; +namespace Hyde\Foundation\Concerns; /** * @internal Single-use trait for the HydeKernel class. diff --git a/packages/framework/src/Framework/Foundation/Concerns/ForwardsHyperlinks.php b/packages/framework/src/Foundation/Concerns/ForwardsHyperlinks.php similarity index 94% rename from packages/framework/src/Framework/Foundation/Concerns/ForwardsHyperlinks.php rename to packages/framework/src/Foundation/Concerns/ForwardsHyperlinks.php index b0b577d3d67..52b4be02a94 100644 --- a/packages/framework/src/Framework/Foundation/Concerns/ForwardsHyperlinks.php +++ b/packages/framework/src/Foundation/Concerns/ForwardsHyperlinks.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Foundation\Concerns; +namespace Hyde\Foundation\Concerns; /** * @internal Single-use trait for the HydeKernel class. diff --git a/packages/framework/src/Framework/Foundation/Concerns/HandlesFoundationCollections.php b/packages/framework/src/Foundation/Concerns/HandlesFoundationCollections.php similarity index 78% rename from packages/framework/src/Framework/Foundation/Concerns/HandlesFoundationCollections.php rename to packages/framework/src/Foundation/Concerns/HandlesFoundationCollections.php index 919bb62cf3c..b96b8935509 100644 --- a/packages/framework/src/Framework/Foundation/Concerns/HandlesFoundationCollections.php +++ b/packages/framework/src/Foundation/Concerns/HandlesFoundationCollections.php @@ -2,11 +2,11 @@ declare(strict_types=1); -namespace Hyde\Framework\Foundation\Concerns; +namespace Hyde\Foundation\Concerns; -use Hyde\Framework\Foundation\FileCollection; -use Hyde\Framework\Foundation\PageCollection; -use Hyde\Framework\Foundation\RouteCollection; +use Hyde\Foundation\FileCollection; +use Hyde\Foundation\PageCollection; +use Hyde\Foundation\RouteCollection; /** * @internal Single-use trait for the HydeKernel class. diff --git a/packages/framework/src/Framework/Foundation/Concerns/ImplementsStringHelpers.php b/packages/framework/src/Foundation/Concerns/ImplementsStringHelpers.php similarity index 91% rename from packages/framework/src/Framework/Foundation/Concerns/ImplementsStringHelpers.php rename to packages/framework/src/Foundation/Concerns/ImplementsStringHelpers.php index 96e43adb780..1010f4e7b47 100644 --- a/packages/framework/src/Framework/Foundation/Concerns/ImplementsStringHelpers.php +++ b/packages/framework/src/Foundation/Concerns/ImplementsStringHelpers.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Foundation\Concerns; +namespace Hyde\Foundation\Concerns; use Illuminate\Support\Str; diff --git a/packages/framework/src/Framework/Foundation/Concerns/ManagesHydeKernel.php b/packages/framework/src/Foundation/Concerns/ManagesHydeKernel.php similarity index 82% rename from packages/framework/src/Framework/Foundation/Concerns/ManagesHydeKernel.php rename to packages/framework/src/Foundation/Concerns/ManagesHydeKernel.php index fe53d3df2aa..26b3e3988b9 100644 --- a/packages/framework/src/Framework/Foundation/Concerns/ManagesHydeKernel.php +++ b/packages/framework/src/Foundation/Concerns/ManagesHydeKernel.php @@ -2,11 +2,11 @@ declare(strict_types=1); -namespace Hyde\Framework\Foundation\Concerns; +namespace Hyde\Foundation\Concerns; -use Hyde\Framework\Foundation\FileCollection; -use Hyde\Framework\Foundation\PageCollection; -use Hyde\Framework\Foundation\RouteCollection; +use Hyde\Foundation\FileCollection; +use Hyde\Foundation\PageCollection; +use Hyde\Foundation\RouteCollection; use Hyde\Framework\HydeKernel; /** diff --git a/packages/framework/src/Framework/Foundation/Concerns/ManagesViewData.php b/packages/framework/src/Foundation/Concerns/ManagesViewData.php similarity index 95% rename from packages/framework/src/Framework/Foundation/Concerns/ManagesViewData.php rename to packages/framework/src/Foundation/Concerns/ManagesViewData.php index 1228fade760..92c8dd2a840 100644 --- a/packages/framework/src/Framework/Foundation/Concerns/ManagesViewData.php +++ b/packages/framework/src/Foundation/Concerns/ManagesViewData.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Foundation\Concerns; +namespace Hyde\Foundation\Concerns; use Hyde\Framework\Concerns\HydePage; use Hyde\Framework\Models\Support\Route; diff --git a/packages/framework/src/Framework/Foundation/FileCollection.php b/packages/framework/src/Foundation/FileCollection.php similarity index 96% rename from packages/framework/src/Framework/Foundation/FileCollection.php rename to packages/framework/src/Foundation/FileCollection.php index a29df4bd691..c258327fe3a 100644 --- a/packages/framework/src/Framework/Foundation/FileCollection.php +++ b/packages/framework/src/Foundation/FileCollection.php @@ -2,10 +2,10 @@ declare(strict_types=1); -namespace Hyde\Framework\Foundation; +namespace Hyde\Foundation; +use Hyde\Foundation\Concerns\BaseFoundationCollection; use Hyde\Framework\Concerns\HydePage; -use Hyde\Framework\Foundation\Concerns\BaseFoundationCollection; use Hyde\Framework\Helpers\Features; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; diff --git a/packages/framework/src/Framework/Foundation/Filesystem.php b/packages/framework/src/Foundation/Filesystem.php similarity index 99% rename from packages/framework/src/Framework/Foundation/Filesystem.php rename to packages/framework/src/Foundation/Filesystem.php index 7fe9f9b98a5..57aa07a8e55 100644 --- a/packages/framework/src/Framework/Foundation/Filesystem.php +++ b/packages/framework/src/Foundation/Filesystem.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Foundation; +namespace Hyde\Foundation; use Hyde\Framework\HydeKernel; use Hyde\Framework\Models\Pages\BladePage; diff --git a/packages/framework/src/Framework/Foundation/Hyperlinks.php b/packages/framework/src/Foundation/Hyperlinks.php similarity index 98% rename from packages/framework/src/Framework/Foundation/Hyperlinks.php rename to packages/framework/src/Foundation/Hyperlinks.php index 1a0be56d96f..16386d4602f 100644 --- a/packages/framework/src/Framework/Foundation/Hyperlinks.php +++ b/packages/framework/src/Foundation/Hyperlinks.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Foundation; +namespace Hyde\Foundation; use Hyde\Framework\Exceptions\BaseUrlNotSetException; use Hyde\Framework\HydeKernel; diff --git a/packages/framework/src/Framework/Foundation/PageCollection.php b/packages/framework/src/Foundation/PageCollection.php similarity index 94% rename from packages/framework/src/Framework/Foundation/PageCollection.php rename to packages/framework/src/Foundation/PageCollection.php index 9c24d0bbc8e..e862e1eeccd 100644 --- a/packages/framework/src/Framework/Foundation/PageCollection.php +++ b/packages/framework/src/Foundation/PageCollection.php @@ -2,11 +2,11 @@ declare(strict_types=1); -namespace Hyde\Framework\Foundation; +namespace Hyde\Foundation; +use Hyde\Foundation\Concerns\BaseFoundationCollection; use Hyde\Framework\Concerns\HydePage; use Hyde\Framework\Exceptions\FileNotFoundException; -use Hyde\Framework\Foundation\Concerns\BaseFoundationCollection; use Hyde\Framework\Helpers\Features; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; @@ -16,7 +16,7 @@ use Illuminate\Support\Collection; /** - * @see \Hyde\Framework\Foundation\RouteCollection + * @see \Hyde\Foundation\RouteCollection * @see \Hyde\Framework\Testing\Feature\PageCollectionTest */ final class PageCollection extends BaseFoundationCollection diff --git a/packages/framework/src/Framework/Foundation/RouteCollection.php b/packages/framework/src/Foundation/RouteCollection.php similarity index 93% rename from packages/framework/src/Framework/Foundation/RouteCollection.php rename to packages/framework/src/Foundation/RouteCollection.php index 58c02474b0e..07bdf3a31a4 100644 --- a/packages/framework/src/Framework/Foundation/RouteCollection.php +++ b/packages/framework/src/Foundation/RouteCollection.php @@ -2,16 +2,16 @@ declare(strict_types=1); -namespace Hyde\Framework\Foundation; +namespace Hyde\Foundation; +use Hyde\Foundation\Concerns\BaseFoundationCollection; use Hyde\Framework\Concerns\HydePage; -use Hyde\Framework\Foundation\Concerns\BaseFoundationCollection; use Hyde\Framework\Models\Support\Route; /** * Pseudo-Router for Hyde. * - * @see \Hyde\Framework\Foundation\PageCollection + * @see \Hyde\Foundation\PageCollection * @see \Hyde\Framework\Testing\Feature\RouteTest * @see \Hyde\Framework\Testing\Feature\RouteCollectionTest * diff --git a/packages/framework/src/Framework/Concerns/HydePage.php b/packages/framework/src/Framework/Concerns/HydePage.php index 9c9f80793ab..1546591ac2a 100644 --- a/packages/framework/src/Framework/Concerns/HydePage.php +++ b/packages/framework/src/Framework/Concerns/HydePage.php @@ -4,11 +4,11 @@ namespace Hyde\Framework\Concerns; +use Hyde\Foundation\PageCollection; use Hyde\Framework\Actions\SourceFileParser; use Hyde\Framework\Concerns\Internal\ConstructsPageSchemas; use Hyde\Framework\Contracts\CompilableContract; use Hyde\Framework\Contracts\FrontMatter\PageSchema; -use Hyde\Framework\Foundation\PageCollection; use Hyde\Framework\Models\Markdown\FrontMatter; use Hyde\Framework\Models\Navigation\NavigationData; use Hyde\Framework\Models\Support\Route; @@ -91,7 +91,7 @@ public static function files(): array|false /** * Get a collection of all pages, parsed into page models. * - * @return \Hyde\Framework\Foundation\PageCollection<\Hyde\Framework\Concerns\HydePage + * @return \Hyde\Foundation\PageCollection<\Hyde\Framework\Concerns\HydePage */ public static function all(): PageCollection { diff --git a/packages/framework/src/Framework/HydeKernel.php b/packages/framework/src/Framework/HydeKernel.php index 3f53aa99d6c..e0e98a7f0cc 100644 --- a/packages/framework/src/Framework/HydeKernel.php +++ b/packages/framework/src/Framework/HydeKernel.php @@ -4,12 +4,12 @@ namespace Hyde\Framework; +use Hyde\Foundation\FileCollection; +use Hyde\Foundation\Filesystem; +use Hyde\Foundation\Hyperlinks; +use Hyde\Foundation\PageCollection; +use Hyde\Foundation\RouteCollection; use Hyde\Framework\Concerns\JsonSerializesArrayable; -use Hyde\Framework\Foundation\FileCollection; -use Hyde\Framework\Foundation\Filesystem; -use Hyde\Framework\Foundation\Hyperlinks; -use Hyde\Framework\Foundation\PageCollection; -use Hyde\Framework\Foundation\RouteCollection; use Hyde\Framework\Helpers\Features; use Illuminate\Contracts\Support\Arrayable; use Illuminate\Support\Traits\Macroable; @@ -38,12 +38,12 @@ */ class HydeKernel implements Arrayable, JsonSerializable { - use Foundation\Concerns\HandlesFoundationCollections; - use Foundation\Concerns\ImplementsStringHelpers; - use Foundation\Concerns\ForwardsHyperlinks; - use Foundation\Concerns\ForwardsFilesystem; - use Foundation\Concerns\ManagesHydeKernel; - use Foundation\Concerns\ManagesViewData; + use \Hyde\Foundation\Concerns\HandlesFoundationCollections; + use \Hyde\Foundation\Concerns\ImplementsStringHelpers; + use \Hyde\Foundation\Concerns\ForwardsHyperlinks; + use \Hyde\Foundation\Concerns\ForwardsFilesystem; + use \Hyde\Foundation\Concerns\ManagesHydeKernel; + use \Hyde\Foundation\Concerns\ManagesViewData; use JsonSerializesArrayable; use Macroable; @@ -87,7 +87,7 @@ public function hasFeature(string $feature): bool /** * @inheritDoc - * @psalm-return array{basePath: string, features: \Hyde\Framework\Helpers\Features, pages: \Hyde\Framework\Foundation\PageCollection, routes: \Hyde\Framework\Foundation\RouteCollection} + * @psalm-return array{basePath: string, features: \Hyde\Framework\Helpers\Features, pages: \Hyde\Foundation\PageCollection, routes: \Hyde\Foundation\RouteCollection} */ public function toArray(): array { diff --git a/packages/framework/src/Framework/Models/Pages/MarkdownPost.php b/packages/framework/src/Framework/Models/Pages/MarkdownPost.php index 7837cf1e516..50262032ec3 100644 --- a/packages/framework/src/Framework/Models/Pages/MarkdownPost.php +++ b/packages/framework/src/Framework/Models/Pages/MarkdownPost.php @@ -4,9 +4,9 @@ namespace Hyde\Framework\Models\Pages; +use Hyde\Foundation\PageCollection; use Hyde\Framework\Concerns\BaseMarkdownPage; use Hyde\Framework\Contracts\FrontMatter\BlogPostSchema; -use Hyde\Framework\Foundation\PageCollection; use Hyde\Framework\Models\Support\Author; use Hyde\Framework\Models\Support\DateString; use Hyde\Framework\Models\Support\Image; @@ -32,7 +32,7 @@ class MarkdownPost extends BaseMarkdownPage implements BlogPostSchema public ?Author $author = null; public ?Image $image = null; - /** @return \Hyde\Framework\Foundation\PageCollection<\Hyde\Framework\Models\Pages\MarkdownPost> */ + /** @return \Hyde\Foundation\PageCollection<\Hyde\Framework\Models\Pages\MarkdownPost> */ public static function getLatestPosts(): PageCollection { return static::all()->sortByDesc('matter.date'); diff --git a/packages/framework/src/Framework/Models/Support/Route.php b/packages/framework/src/Framework/Models/Support/Route.php index a9e8f91559d..7cc8407d6e6 100644 --- a/packages/framework/src/Framework/Models/Support/Route.php +++ b/packages/framework/src/Framework/Models/Support/Route.php @@ -4,10 +4,10 @@ namespace Hyde\Framework\Models\Support; +use Hyde\Foundation\RouteCollection; use Hyde\Framework\Concerns\HydePage; use Hyde\Framework\Concerns\JsonSerializesArrayable; use Hyde\Framework\Exceptions\RouteNotFoundException; -use Hyde\Framework\Foundation\RouteCollection; use Hyde\Hyde; use Illuminate\Contracts\Support\Arrayable; use JsonSerializable; @@ -226,7 +226,7 @@ public static function getFromModel(HydePage $page): Route /** * Get all routes from the route index. * - * @return \Hyde\Framework\Foundation\RouteCollection<\Hyde\Framework\Models\Support\Route> + * @return \Hyde\Foundation\RouteCollection<\Hyde\Framework\Models\Support\Route> */ public static function all(): RouteCollection { diff --git a/packages/framework/src/Framework/Services/BuildService.php b/packages/framework/src/Framework/Services/BuildService.php index 7346ade646c..776bfe5b8a2 100644 --- a/packages/framework/src/Framework/Services/BuildService.php +++ b/packages/framework/src/Framework/Services/BuildService.php @@ -5,9 +5,9 @@ namespace Hyde\Framework\Services; use Closure; +use Hyde\Foundation\RouteCollection; use Hyde\Framework\Actions\StaticPageBuilder; use Hyde\Framework\Concerns\InteractsWithDirectories; -use Hyde\Framework\Foundation\RouteCollection; use Hyde\Framework\Models\Support\Route; use Hyde\Framework\Models\Support\Site; use Hyde\Hyde; @@ -73,7 +73,7 @@ function ($filepath) { } /** - * @return \Hyde\Framework\Foundation\RouteCollection> + * @return \Hyde\Foundation\RouteCollection> */ protected function getDiscoveredModels(): RouteCollection { diff --git a/packages/framework/src/Hyde.php b/packages/framework/src/Hyde.php index e3dbacddcdc..a9c678e3001 100644 --- a/packages/framework/src/Hyde.php +++ b/packages/framework/src/Hyde.php @@ -4,10 +4,10 @@ namespace Hyde; +use Hyde\Foundation\FileCollection; +use Hyde\Foundation\PageCollection; +use Hyde\Foundation\RouteCollection; use Hyde\Framework\Concerns\HydePage; -use Hyde\Framework\Foundation\FileCollection; -use Hyde\Framework\Foundation\PageCollection; -use Hyde\Framework\Foundation\RouteCollection; use Hyde\Framework\Helpers\Features; use Hyde\Framework\HydeKernel; use Hyde\Framework\Models\Support\Route; diff --git a/packages/framework/tests/Feature/FileCollectionTest.php b/packages/framework/tests/Feature/FileCollectionTest.php index 185580a4602..4f3767ae831 100644 --- a/packages/framework/tests/Feature/FileCollectionTest.php +++ b/packages/framework/tests/Feature/FileCollectionTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Feature; -use Hyde\Framework\Foundation\FileCollection; +use Hyde\Foundation\FileCollection; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; @@ -15,8 +15,8 @@ use Illuminate\Support\Collection; /** - * @covers \Hyde\Framework\Foundation\FileCollection - * @covers \Hyde\Framework\Foundation\Concerns\BaseFoundationCollection + * @covers \Hyde\Foundation\FileCollection + * @covers \Hyde\Foundation\Concerns\BaseFoundationCollection */ class FileCollectionTest extends TestCase { diff --git a/packages/framework/tests/Feature/Foundation/FilesystemTest.php b/packages/framework/tests/Feature/Foundation/FilesystemTest.php index af592fca386..8232417e8a2 100644 --- a/packages/framework/tests/Feature/Foundation/FilesystemTest.php +++ b/packages/framework/tests/Feature/Foundation/FilesystemTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Feature\Foundation; -use Hyde\Framework\Foundation\Filesystem; +use Hyde\Foundation\Filesystem; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; @@ -14,7 +14,7 @@ /** * @covers \Hyde\Framework\HydeKernel - * @covers \Hyde\Framework\Foundation\Filesystem + * @covers \Hyde\Foundation\Filesystem */ class FilesystemTest extends TestCase { @@ -91,7 +91,7 @@ public function test_path_method_returns_expected_value_regardless_of_trailing_d public function test_vendor_path_method_exists() { - $this->assertTrue(method_exists(Filesystem::class, 'vendorPath')); + $this->assertTrue(method_exists(\Hyde\Foundation\Filesystem::class, 'vendorPath')); } public function test_vendor_path_method_returns_string() @@ -113,7 +113,7 @@ public function test_vendor_path_method_returns_expected_value_regardless_of_tra public function test_copy_method() { touch(Hyde::path('foo')); - $this->assertTrue(method_exists(Filesystem::class, 'copy')); + $this->assertTrue(method_exists(\Hyde\Foundation\Filesystem::class, 'copy')); $this->assertTrue(Hyde::copy('foo', 'bar')); $this->assertFileExists(Hyde::path('bar')); unlink(Hyde::path('foo')); diff --git a/packages/framework/tests/Feature/Foundation/HyperlinksTest.php b/packages/framework/tests/Feature/Foundation/HyperlinksTest.php index c4d69ad5b9c..d4983063e62 100644 --- a/packages/framework/tests/Feature/Foundation/HyperlinksTest.php +++ b/packages/framework/tests/Feature/Foundation/HyperlinksTest.php @@ -4,22 +4,21 @@ namespace Hyde\Framework\Testing\Feature\Foundation; -use Hyde\Framework\Foundation\Hyperlinks; use Hyde\Framework\HydeKernel; use Hyde\Testing\TestCase; /** - * @covers \Hyde\Framework\Foundation\Hyperlinks + * @covers \Hyde\Foundation\Hyperlinks */ class HyperlinksTest extends TestCase { - protected Hyperlinks $class; + protected \Hyde\Foundation\Hyperlinks $class; protected function setUp(): void { parent::setUp(); - $this->class = new Hyperlinks(HydeKernel::getInstance()); + $this->class = new \Hyde\Foundation\Hyperlinks(HydeKernel::getInstance()); } public function test_image_helper_gets_relative_web_link_to_image_stored_in_site_media_folder() diff --git a/packages/framework/tests/Feature/PageCollectionTest.php b/packages/framework/tests/Feature/PageCollectionTest.php index e32c3f0eaf8..cd470afba32 100644 --- a/packages/framework/tests/Feature/PageCollectionTest.php +++ b/packages/framework/tests/Feature/PageCollectionTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Feature; -use Hyde\Framework\Foundation\PageCollection; +use Hyde\Foundation\PageCollection; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; @@ -15,8 +15,8 @@ use Illuminate\Support\Facades\File; /** - * @covers \Hyde\Framework\Foundation\PageCollection - * @covers \Hyde\Framework\Foundation\Concerns\BaseFoundationCollection + * @covers \Hyde\Foundation\PageCollection + * @covers \Hyde\Foundation\Concerns\BaseFoundationCollection */ class PageCollectionTest extends TestCase { diff --git a/packages/framework/tests/Feature/RouteCollectionTest.php b/packages/framework/tests/Feature/RouteCollectionTest.php index 0d64d6f6b30..68c21798376 100644 --- a/packages/framework/tests/Feature/RouteCollectionTest.php +++ b/packages/framework/tests/Feature/RouteCollectionTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Feature; -use Hyde\Framework\Foundation\RouteCollection; +use Hyde\Foundation\RouteCollection; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; @@ -15,8 +15,8 @@ use Illuminate\Support\Collection; /** - * @covers \Hyde\Framework\Foundation\RouteCollection - * @covers \Hyde\Framework\Foundation\Concerns\BaseFoundationCollection + * @covers \Hyde\Foundation\RouteCollection + * @covers \Hyde\Foundation\Concerns\BaseFoundationCollection */ class RouteCollectionTest extends TestCase { diff --git a/packages/framework/tests/Unit/Foundation/HyperlinkFileHelperRelativeLinkTest.php b/packages/framework/tests/Unit/Foundation/HyperlinkFileHelperRelativeLinkTest.php index 31363e22232..05cf2ea7271 100644 --- a/packages/framework/tests/Unit/Foundation/HyperlinkFileHelperRelativeLinkTest.php +++ b/packages/framework/tests/Unit/Foundation/HyperlinkFileHelperRelativeLinkTest.php @@ -8,7 +8,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Framework\Foundation\Hyperlinks::relativeLink + * @covers \Hyde\Foundation\Hyperlinks::relativeLink */ class HyperlinkFileHelperRelativeLinkTest extends TestCase { diff --git a/packages/framework/tests/Unit/Foundation/HyperlinkFormatHtmlPathTest.php b/packages/framework/tests/Unit/Foundation/HyperlinkFormatHtmlPathTest.php index 06e7295a806..5d30e501990 100644 --- a/packages/framework/tests/Unit/Foundation/HyperlinkFormatHtmlPathTest.php +++ b/packages/framework/tests/Unit/Foundation/HyperlinkFormatHtmlPathTest.php @@ -8,7 +8,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Framework\Foundation\Hyperlinks::formatLink + * @covers \Hyde\Foundation\Hyperlinks::formatLink */ class HyperlinkformatLinkTest extends TestCase { diff --git a/packages/framework/tests/Unit/Foundation/HyperlinksUrlPathHelpersTest.php b/packages/framework/tests/Unit/Foundation/HyperlinksUrlPathHelpersTest.php index ac794fb9862..128e165aa3c 100644 --- a/packages/framework/tests/Unit/Foundation/HyperlinksUrlPathHelpersTest.php +++ b/packages/framework/tests/Unit/Foundation/HyperlinksUrlPathHelpersTest.php @@ -4,14 +4,14 @@ namespace Hyde\Framework\Testing\Unit\Foundation; +use Hyde\Foundation\Hyperlinks; use Hyde\Framework\Exceptions\BaseUrlNotSetException; -use Hyde\Framework\Foundation\Hyperlinks; use Hyde\Framework\HydeKernel; use Hyde\Testing\TestCase; /** - * @covers \Hyde\Framework\Foundation\Hyperlinks::hasSiteUrl - * @covers \Hyde\Framework\Foundation\Hyperlinks::url + * @covers \Hyde\Foundation\Hyperlinks::hasSiteUrl + * @covers \Hyde\Foundation\Hyperlinks::url * @covers \Hyde\Framework\Exceptions\BaseUrlNotSetException */ class HyperlinksUrlPathHelpersTest extends TestCase From 2ca7ba41b4b87bc769ceaaf608365497cebf1125 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 19:08:50 +0200 Subject: [PATCH 007/768] Move HydeKernel into Foundation namespace --- app/bootstrap.php | 8 ++++---- .../src/Foundation/Concerns/BaseFoundationCollection.php | 2 +- .../src/Foundation/Concerns/ForwardsFilesystem.php | 2 +- .../src/Foundation/Concerns/ForwardsHyperlinks.php | 2 +- .../Foundation/Concerns/HandlesFoundationCollections.php | 2 +- .../src/Foundation/Concerns/ImplementsStringHelpers.php | 2 +- .../src/Foundation/Concerns/ManagesHydeKernel.php | 4 ++-- .../framework/src/Foundation/Concerns/ManagesViewData.php | 2 +- packages/framework/src/Foundation/Filesystem.php | 1 - .../src/{Framework => Foundation}/HydeKernel.php | 7 +------ packages/framework/src/Foundation/Hyperlinks.php | 1 - packages/framework/src/Framework/HydeServiceProvider.php | 1 + packages/framework/src/Framework/helpers.php | 4 ++-- packages/framework/src/Hyde.php | 4 ++-- .../framework/tests/Feature/Foundation/FilesystemTest.php | 2 +- .../framework/tests/Feature/Foundation/HyperlinksTest.php | 2 +- packages/framework/tests/Feature/HelpersTest.php | 2 +- packages/framework/tests/Feature/HydeKernelTest.php | 4 ++-- packages/framework/tests/Feature/MetadataViewTest.php | 2 +- .../Unit/Foundation/HyperlinksUrlPathHelpersTest.php | 2 +- .../framework/tests/Unit/HydeBasePathCanBeChangedTest.php | 6 +++--- packages/framework/tests/Unit/HydeFileHelpersTest.php | 2 +- .../tests/Unit/HydeGetBasePathHasFallbackTest.php | 2 +- packages/framework/tests/Unit/HydeHelperFacadeTest.php | 2 +- packages/framework/tests/Unit/HydePathHelperTest.php | 4 ++-- .../framework/tests/Unit/HydeVendorPathHelperTest.php | 2 +- packages/testing/src/CreatesApplication.php | 2 +- 27 files changed, 35 insertions(+), 41 deletions(-) rename packages/framework/src/{Framework => Foundation}/HydeKernel.php (93%) diff --git a/app/bootstrap.php b/app/bootstrap.php index c9f44913394..0f68f229466 100644 --- a/app/bootstrap.php +++ b/app/bootstrap.php @@ -47,17 +47,17 @@ | */ -$hyde = new Hyde\Framework\HydeKernel( +$hyde = new \Hyde\Foundation\HydeKernel( dirname(__DIR__) ); $app->singleton( - Hyde\Framework\HydeKernel::class, function () { - return Hyde\Framework\HydeKernel::getInstance(); + \Hyde\Foundation\HydeKernel::class, function () { + return \Hyde\Foundation\HydeKernel::getInstance(); } ); -Hyde\Framework\HydeKernel::setInstance($hyde); +\Hyde\Foundation\HydeKernel::setInstance($hyde); /* |-------------------------------------------------------------------------- diff --git a/packages/framework/src/Foundation/Concerns/BaseFoundationCollection.php b/packages/framework/src/Foundation/Concerns/BaseFoundationCollection.php index fde7ff46a19..142eb55d4ea 100644 --- a/packages/framework/src/Foundation/Concerns/BaseFoundationCollection.php +++ b/packages/framework/src/Foundation/Concerns/BaseFoundationCollection.php @@ -4,7 +4,7 @@ namespace Hyde\Foundation\Concerns; -use Hyde\Framework\HydeKernel; +use Hyde\Foundation\HydeKernel; use Illuminate\Support\Collection; /** diff --git a/packages/framework/src/Foundation/Concerns/ForwardsFilesystem.php b/packages/framework/src/Foundation/Concerns/ForwardsFilesystem.php index 974697cc550..09fea7b7f9b 100644 --- a/packages/framework/src/Foundation/Concerns/ForwardsFilesystem.php +++ b/packages/framework/src/Foundation/Concerns/ForwardsFilesystem.php @@ -7,7 +7,7 @@ /** * @internal Single-use trait for the HydeKernel class. * - * @see \Hyde\Framework\HydeKernel + * @see \Hyde\Foundation\HydeKernel */ trait ForwardsFilesystem { diff --git a/packages/framework/src/Foundation/Concerns/ForwardsHyperlinks.php b/packages/framework/src/Foundation/Concerns/ForwardsHyperlinks.php index 52b4be02a94..3e7e6482779 100644 --- a/packages/framework/src/Foundation/Concerns/ForwardsHyperlinks.php +++ b/packages/framework/src/Foundation/Concerns/ForwardsHyperlinks.php @@ -7,7 +7,7 @@ /** * @internal Single-use trait for the HydeKernel class. * - * @see \Hyde\Framework\HydeKernel + * @see \Hyde\Foundation\HydeKernel */ trait ForwardsHyperlinks { diff --git a/packages/framework/src/Foundation/Concerns/HandlesFoundationCollections.php b/packages/framework/src/Foundation/Concerns/HandlesFoundationCollections.php index b96b8935509..ca045508c96 100644 --- a/packages/framework/src/Foundation/Concerns/HandlesFoundationCollections.php +++ b/packages/framework/src/Foundation/Concerns/HandlesFoundationCollections.php @@ -11,7 +11,7 @@ /** * @internal Single-use trait for the HydeKernel class. * - * @see \Hyde\Framework\HydeKernel + * @see \Hyde\Foundation\HydeKernel */ trait HandlesFoundationCollections { diff --git a/packages/framework/src/Foundation/Concerns/ImplementsStringHelpers.php b/packages/framework/src/Foundation/Concerns/ImplementsStringHelpers.php index 1010f4e7b47..7e810ad2d3a 100644 --- a/packages/framework/src/Foundation/Concerns/ImplementsStringHelpers.php +++ b/packages/framework/src/Foundation/Concerns/ImplementsStringHelpers.php @@ -9,7 +9,7 @@ /** * @internal Single-use trait for the HydeKernel class. * - * @see \Hyde\Framework\HydeKernel + * @see \Hyde\Foundation\HydeKernel */ trait ImplementsStringHelpers { diff --git a/packages/framework/src/Foundation/Concerns/ManagesHydeKernel.php b/packages/framework/src/Foundation/Concerns/ManagesHydeKernel.php index 26b3e3988b9..f57adcce309 100644 --- a/packages/framework/src/Foundation/Concerns/ManagesHydeKernel.php +++ b/packages/framework/src/Foundation/Concerns/ManagesHydeKernel.php @@ -5,14 +5,14 @@ namespace Hyde\Foundation\Concerns; use Hyde\Foundation\FileCollection; +use Hyde\Foundation\HydeKernel; use Hyde\Foundation\PageCollection; use Hyde\Foundation\RouteCollection; -use Hyde\Framework\HydeKernel; /** * @internal Single-use trait for the HydeKernel class. * - * @see \Hyde\Framework\HydeKernel + * @see \Hyde\Foundation\HydeKernel */ trait ManagesHydeKernel { diff --git a/packages/framework/src/Foundation/Concerns/ManagesViewData.php b/packages/framework/src/Foundation/Concerns/ManagesViewData.php index 92c8dd2a840..1996841210b 100644 --- a/packages/framework/src/Foundation/Concerns/ManagesViewData.php +++ b/packages/framework/src/Foundation/Concerns/ManagesViewData.php @@ -11,7 +11,7 @@ /** * @internal Single-use trait for the HydeKernel class. * - * @see \Hyde\Framework\HydeKernel + * @see \Hyde\Foundation\HydeKernel */ trait ManagesViewData { diff --git a/packages/framework/src/Foundation/Filesystem.php b/packages/framework/src/Foundation/Filesystem.php index 57aa07a8e55..59ff715a371 100644 --- a/packages/framework/src/Foundation/Filesystem.php +++ b/packages/framework/src/Foundation/Filesystem.php @@ -4,7 +4,6 @@ namespace Hyde\Foundation; -use Hyde\Framework\HydeKernel; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; diff --git a/packages/framework/src/Framework/HydeKernel.php b/packages/framework/src/Foundation/HydeKernel.php similarity index 93% rename from packages/framework/src/Framework/HydeKernel.php rename to packages/framework/src/Foundation/HydeKernel.php index e0e98a7f0cc..42c5c30d0e5 100644 --- a/packages/framework/src/Framework/HydeKernel.php +++ b/packages/framework/src/Foundation/HydeKernel.php @@ -2,13 +2,8 @@ declare(strict_types=1); -namespace Hyde\Framework; +namespace Hyde\Foundation; -use Hyde\Foundation\FileCollection; -use Hyde\Foundation\Filesystem; -use Hyde\Foundation\Hyperlinks; -use Hyde\Foundation\PageCollection; -use Hyde\Foundation\RouteCollection; use Hyde\Framework\Concerns\JsonSerializesArrayable; use Hyde\Framework\Helpers\Features; use Illuminate\Contracts\Support\Arrayable; diff --git a/packages/framework/src/Foundation/Hyperlinks.php b/packages/framework/src/Foundation/Hyperlinks.php index 16386d4602f..9d8b46c2bb9 100644 --- a/packages/framework/src/Foundation/Hyperlinks.php +++ b/packages/framework/src/Foundation/Hyperlinks.php @@ -5,7 +5,6 @@ namespace Hyde\Foundation; use Hyde\Framework\Exceptions\BaseUrlNotSetException; -use Hyde\Framework\HydeKernel; use Hyde\Framework\Models\Pages\DocumentationPage; /** diff --git a/packages/framework/src/Framework/HydeServiceProvider.php b/packages/framework/src/Framework/HydeServiceProvider.php index f5323259c35..86fb8a109c5 100644 --- a/packages/framework/src/Framework/HydeServiceProvider.php +++ b/packages/framework/src/Framework/HydeServiceProvider.php @@ -4,6 +4,7 @@ namespace Hyde\Framework; +use Hyde\Foundation\HydeKernel; use Hyde\Framework\Actions\MarkdownConverter; use Hyde\Framework\Concerns\RegistersFileLocations; use Hyde\Framework\Models\Pages\BladePage; diff --git a/packages/framework/src/Framework/helpers.php b/packages/framework/src/Framework/helpers.php index f4efd179eb4..f8b6becb848 100644 --- a/packages/framework/src/Framework/helpers.php +++ b/packages/framework/src/Framework/helpers.php @@ -2,13 +2,13 @@ declare(strict_types=1); -use Hyde\Framework\HydeKernel; +use Hyde\Foundation\HydeKernel; if (! function_exists('hyde')) { /** * Get the available HydeKernel instance. * - * @return \Hyde\Framework\HydeKernel + * @return \Hyde\Foundation\HydeKernel */ function hyde(): HydeKernel { diff --git a/packages/framework/src/Hyde.php b/packages/framework/src/Hyde.php index a9c678e3001..7fd44305fbb 100644 --- a/packages/framework/src/Hyde.php +++ b/packages/framework/src/Hyde.php @@ -5,18 +5,18 @@ namespace Hyde; use Hyde\Foundation\FileCollection; +use Hyde\Foundation\HydeKernel; use Hyde\Foundation\PageCollection; use Hyde\Foundation\RouteCollection; use Hyde\Framework\Concerns\HydePage; use Hyde\Framework\Helpers\Features; -use Hyde\Framework\HydeKernel; use Hyde\Framework\Models\Support\Route; use Illuminate\Support\Facades\Facade; /** * General facade for Hyde services. * - * @see \Hyde\Framework\HydeKernel + * @see \Hyde\Foundation\HydeKernel * * @author Caen De Silva * @copyright 2022 Caen De Silva diff --git a/packages/framework/tests/Feature/Foundation/FilesystemTest.php b/packages/framework/tests/Feature/Foundation/FilesystemTest.php index 8232417e8a2..1b42b65862a 100644 --- a/packages/framework/tests/Feature/Foundation/FilesystemTest.php +++ b/packages/framework/tests/Feature/Foundation/FilesystemTest.php @@ -13,7 +13,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Framework\HydeKernel + * @covers \Hyde\Foundation\HydeKernel * @covers \Hyde\Foundation\Filesystem */ class FilesystemTest extends TestCase diff --git a/packages/framework/tests/Feature/Foundation/HyperlinksTest.php b/packages/framework/tests/Feature/Foundation/HyperlinksTest.php index d4983063e62..304ef087e8a 100644 --- a/packages/framework/tests/Feature/Foundation/HyperlinksTest.php +++ b/packages/framework/tests/Feature/Foundation/HyperlinksTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Feature\Foundation; -use Hyde\Framework\HydeKernel; +use Hyde\Foundation\HydeKernel; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/HelpersTest.php b/packages/framework/tests/Feature/HelpersTest.php index ba9e4ee5260..84f832b93fb 100644 --- a/packages/framework/tests/Feature/HelpersTest.php +++ b/packages/framework/tests/Feature/HelpersTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Feature; -use Hyde\Framework\HydeKernel; +use Hyde\Foundation\HydeKernel; use Hyde\Hyde; use Hyde\Testing\TestCase; diff --git a/packages/framework/tests/Feature/HydeKernelTest.php b/packages/framework/tests/Feature/HydeKernelTest.php index 0a75e8c956c..d1e0d7c37ca 100644 --- a/packages/framework/tests/Feature/HydeKernelTest.php +++ b/packages/framework/tests/Feature/HydeKernelTest.php @@ -5,8 +5,8 @@ namespace Hyde\Framework\Testing\Feature; use Composer\InstalledVersions; +use Hyde\Foundation\HydeKernel; use Hyde\Framework\Helpers\Features; -use Hyde\Framework\HydeKernel; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; @@ -21,7 +21,7 @@ * This test class runs high-level tests on the HydeKernel class, * as most of the logic actually resides in linked service classes. * - * @covers \Hyde\Framework\HydeKernel + * @covers \Hyde\Foundation\HydeKernel * @covers \Hyde\Hyde * * @see \Hyde\Framework\Testing\Unit\HydeHelperFacadeMakeTitleTest diff --git a/packages/framework/tests/Feature/MetadataViewTest.php b/packages/framework/tests/Feature/MetadataViewTest.php index 517de89d529..08303304908 100644 --- a/packages/framework/tests/Feature/MetadataViewTest.php +++ b/packages/framework/tests/Feature/MetadataViewTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Feature; -use Hyde\Framework\HydeKernel; +use Hyde\Foundation\HydeKernel; use Hyde\Hyde; use Hyde\Testing\TestCase; diff --git a/packages/framework/tests/Unit/Foundation/HyperlinksUrlPathHelpersTest.php b/packages/framework/tests/Unit/Foundation/HyperlinksUrlPathHelpersTest.php index 128e165aa3c..45930b82837 100644 --- a/packages/framework/tests/Unit/Foundation/HyperlinksUrlPathHelpersTest.php +++ b/packages/framework/tests/Unit/Foundation/HyperlinksUrlPathHelpersTest.php @@ -4,9 +4,9 @@ namespace Hyde\Framework\Testing\Unit\Foundation; +use Hyde\Foundation\HydeKernel; use Hyde\Foundation\Hyperlinks; use Hyde\Framework\Exceptions\BaseUrlNotSetException; -use Hyde\Framework\HydeKernel; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Unit/HydeBasePathCanBeChangedTest.php b/packages/framework/tests/Unit/HydeBasePathCanBeChangedTest.php index 93b5e110f1e..3eff9f91dd1 100644 --- a/packages/framework/tests/Unit/HydeBasePathCanBeChangedTest.php +++ b/packages/framework/tests/Unit/HydeBasePathCanBeChangedTest.php @@ -10,9 +10,9 @@ /** * Class HydeBasePathCanBeChangedTest. * - * @covers \Hyde\Framework\HydeKernel::getBasePath - * @covers \Hyde\Framework\HydeKernel::setBasePath - * @covers \Hyde\Framework\HydeKernel::path + * @covers \Hyde\Foundation\HydeKernel::getBasePath + * @covers \Hyde\Foundation\HydeKernel::setBasePath + * @covers \Hyde\Foundation\HydeKernel::path */ class HydeBasePathCanBeChangedTest extends TestCase { diff --git a/packages/framework/tests/Unit/HydeFileHelpersTest.php b/packages/framework/tests/Unit/HydeFileHelpersTest.php index adbd3c56221..86244813fcb 100644 --- a/packages/framework/tests/Unit/HydeFileHelpersTest.php +++ b/packages/framework/tests/Unit/HydeFileHelpersTest.php @@ -9,7 +9,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Framework\HydeKernel + * @covers \Hyde\Foundation\HydeKernel */ class HydeFileHelpersTest extends TestCase { diff --git a/packages/framework/tests/Unit/HydeGetBasePathHasFallbackTest.php b/packages/framework/tests/Unit/HydeGetBasePathHasFallbackTest.php index a811a2868e0..cdb7eb66daf 100644 --- a/packages/framework/tests/Unit/HydeGetBasePathHasFallbackTest.php +++ b/packages/framework/tests/Unit/HydeGetBasePathHasFallbackTest.php @@ -10,7 +10,7 @@ /** * Class HydeGetBasePathHasFallbackTest. * - * @covers \Hyde\Framework\HydeKernel::getBasePath + * @covers \Hyde\Foundation\HydeKernel::getBasePath */ class HydeGetBasePathHasFallbackTest extends TestCase { diff --git a/packages/framework/tests/Unit/HydeHelperFacadeTest.php b/packages/framework/tests/Unit/HydeHelperFacadeTest.php index f6ecb0a835f..2ad4c283784 100644 --- a/packages/framework/tests/Unit/HydeHelperFacadeTest.php +++ b/packages/framework/tests/Unit/HydeHelperFacadeTest.php @@ -9,7 +9,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Framework\HydeKernel + * @covers \Hyde\Foundation\HydeKernel */ class HydeHelperFacadeTest extends TestCase { diff --git a/packages/framework/tests/Unit/HydePathHelperTest.php b/packages/framework/tests/Unit/HydePathHelperTest.php index 65cef938b33..29bb6e797e3 100644 --- a/packages/framework/tests/Unit/HydePathHelperTest.php +++ b/packages/framework/tests/Unit/HydePathHelperTest.php @@ -4,14 +4,14 @@ namespace Hyde\Framework\Testing\Unit; -use Hyde\Framework\HydeKernel; +use Hyde\Foundation\HydeKernel; use Hyde\Hyde; use Hyde\Testing\TestCase; /** * Class HydePathHelperTest. * - * @covers \Hyde\Framework\HydeKernel::path + * @covers \Hyde\Foundation\HydeKernel::path */ class HydePathHelperTest extends TestCase { diff --git a/packages/framework/tests/Unit/HydeVendorPathHelperTest.php b/packages/framework/tests/Unit/HydeVendorPathHelperTest.php index a23506b7ede..df27dbd38c1 100644 --- a/packages/framework/tests/Unit/HydeVendorPathHelperTest.php +++ b/packages/framework/tests/Unit/HydeVendorPathHelperTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Unit; -use Hyde\Framework\HydeKernel; +use Hyde\Foundation\HydeKernel; use Hyde\Hyde; use Hyde\Testing\TestCase; diff --git a/packages/testing/src/CreatesApplication.php b/packages/testing/src/CreatesApplication.php index e480a8d7a24..6339cc0287d 100644 --- a/packages/testing/src/CreatesApplication.php +++ b/packages/testing/src/CreatesApplication.php @@ -2,7 +2,7 @@ namespace Hyde\Testing; -use Hyde\Framework\HydeKernel; +use Hyde\Foundation\HydeKernel; use Hyde\Hyde; use Illuminate\Contracts\Console\Kernel; use Illuminate\Foundation\Application; From 5d1eac6d101f352750301b7c0a3a36dc6e8d0f39 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 19:08:53 +0200 Subject: [PATCH 008/768] Cleanup code --- .../framework/src/Foundation/HydeKernel.php | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/packages/framework/src/Foundation/HydeKernel.php b/packages/framework/src/Foundation/HydeKernel.php index 42c5c30d0e5..8174282794c 100644 --- a/packages/framework/src/Foundation/HydeKernel.php +++ b/packages/framework/src/Foundation/HydeKernel.php @@ -4,6 +4,12 @@ namespace Hyde\Foundation; +use Hyde\Foundation\Concerns\ForwardsFilesystem; +use Hyde\Foundation\Concerns\ForwardsHyperlinks; +use Hyde\Foundation\Concerns\HandlesFoundationCollections; +use Hyde\Foundation\Concerns\ImplementsStringHelpers; +use Hyde\Foundation\Concerns\ManagesHydeKernel; +use Hyde\Foundation\Concerns\ManagesViewData; use Hyde\Framework\Concerns\JsonSerializesArrayable; use Hyde\Framework\Helpers\Features; use Illuminate\Contracts\Support\Arrayable; @@ -33,12 +39,12 @@ */ class HydeKernel implements Arrayable, JsonSerializable { - use \Hyde\Foundation\Concerns\HandlesFoundationCollections; - use \Hyde\Foundation\Concerns\ImplementsStringHelpers; - use \Hyde\Foundation\Concerns\ForwardsHyperlinks; - use \Hyde\Foundation\Concerns\ForwardsFilesystem; - use \Hyde\Foundation\Concerns\ManagesHydeKernel; - use \Hyde\Foundation\Concerns\ManagesViewData; + use HandlesFoundationCollections; + use ImplementsStringHelpers; + use ForwardsHyperlinks; + use ForwardsFilesystem; + use ManagesHydeKernel; + use ManagesViewData; use JsonSerializesArrayable; use Macroable; From 4f2bdde9641b3295d714723f05137a6b06e1e24a Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 19:09:46 +0200 Subject: [PATCH 009/768] Import namespace group --- .../framework/src/Foundation/HydeKernel.php | 19 +++++++------------ 1 file changed, 7 insertions(+), 12 deletions(-) diff --git a/packages/framework/src/Foundation/HydeKernel.php b/packages/framework/src/Foundation/HydeKernel.php index 8174282794c..a17d92cf0d6 100644 --- a/packages/framework/src/Foundation/HydeKernel.php +++ b/packages/framework/src/Foundation/HydeKernel.php @@ -4,14 +4,9 @@ namespace Hyde\Foundation; -use Hyde\Foundation\Concerns\ForwardsFilesystem; -use Hyde\Foundation\Concerns\ForwardsHyperlinks; -use Hyde\Foundation\Concerns\HandlesFoundationCollections; -use Hyde\Foundation\Concerns\ImplementsStringHelpers; -use Hyde\Foundation\Concerns\ManagesHydeKernel; -use Hyde\Foundation\Concerns\ManagesViewData; use Hyde\Framework\Concerns\JsonSerializesArrayable; use Hyde\Framework\Helpers\Features; +use Hyde\Foundation\Concerns; use Illuminate\Contracts\Support\Arrayable; use Illuminate\Support\Traits\Macroable; use JsonSerializable; @@ -39,12 +34,12 @@ */ class HydeKernel implements Arrayable, JsonSerializable { - use HandlesFoundationCollections; - use ImplementsStringHelpers; - use ForwardsHyperlinks; - use ForwardsFilesystem; - use ManagesHydeKernel; - use ManagesViewData; + use Concerns\HandlesFoundationCollections; + use Concerns\ImplementsStringHelpers; + use Concerns\ForwardsHyperlinks; + use Concerns\ForwardsFilesystem; + use Concerns\ManagesHydeKernel; + use Concerns\ManagesViewData; use JsonSerializesArrayable; use Macroable; From 221e805d77c32e8688bf3f7fd346f535a6dfd205 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 19:11:54 +0200 Subject: [PATCH 010/768] Move helpers.php to root src directory --- packages/framework/composer.json | 2 +- packages/framework/src/{Framework => }/helpers.php | 0 2 files changed, 1 insertion(+), 1 deletion(-) rename packages/framework/src/{Framework => }/helpers.php (100%) diff --git a/packages/framework/composer.json b/packages/framework/composer.json index 01cd127ead2..3af3bbb2d20 100644 --- a/packages/framework/composer.json +++ b/packages/framework/composer.json @@ -7,7 +7,7 @@ "Hyde\\": "src/" }, "files": [ - "src/Framework/helpers.php" + "src/helpers.php" ] }, "autoload-dev": { diff --git a/packages/framework/src/Framework/helpers.php b/packages/framework/src/helpers.php similarity index 100% rename from packages/framework/src/Framework/helpers.php rename to packages/framework/src/helpers.php From 2a89a35ec21022ecdd1e0d40f7a5adf63bd75135 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 19:12:30 +0200 Subject: [PATCH 011/768] Update composer.lock --- composer.lock | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/composer.lock b/composer.lock index 62617ccfa8a..da4f7b9b416 100644 --- a/composer.lock +++ b/composer.lock @@ -830,7 +830,7 @@ "dist": { "type": "path", "url": "./packages/framework", - "reference": "322dce9cf80a72175eb027dbc9d151accabcb42c" + "reference": "6d64cb61b879f53097eda4cf1ae4ad9845ba7390" }, "require": { "illuminate/support": "^9.5", @@ -852,7 +852,7 @@ "Hyde\\": "src/" }, "files": [ - "src/Framework/helpers.php" + "src/helpers.php" ] }, "autoload-dev": { From 4e48741ade9c1de20c9192d2162da7d4f715fd37 Mon Sep 17 00:00:00 2001 From: StyleCI Bot Date: Wed, 26 Oct 2022 17:13:32 +0000 Subject: [PATCH 012/768] Apply fixes from StyleCI --- config/hyde.php | 2 +- packages/framework/config/hyde.php | 2 +- packages/framework/src/Foundation/HydeKernel.php | 1 - 3 files changed, 2 insertions(+), 3 deletions(-) diff --git a/config/hyde.php b/config/hyde.php index 986c339ac89..2bcf6cd9fff 100644 --- a/config/hyde.php +++ b/config/hyde.php @@ -36,7 +36,7 @@ // Meta::name('twitter:creator', '@HydeFramework'), // Meta::name('description', 'My Hyde Blog'), // Meta::name('keywords', 'Static Sites, Blogs, Documentation'), - Meta::name('generator', 'HydePHP '. Hyde\Hyde::version()), + Meta::name('generator', 'HydePHP '.Hyde\Hyde::version()), Meta::property('site_name', config('site.name', 'HydePHP')), ], diff --git a/packages/framework/config/hyde.php b/packages/framework/config/hyde.php index 986c339ac89..2bcf6cd9fff 100644 --- a/packages/framework/config/hyde.php +++ b/packages/framework/config/hyde.php @@ -36,7 +36,7 @@ // Meta::name('twitter:creator', '@HydeFramework'), // Meta::name('description', 'My Hyde Blog'), // Meta::name('keywords', 'Static Sites, Blogs, Documentation'), - Meta::name('generator', 'HydePHP '. Hyde\Hyde::version()), + Meta::name('generator', 'HydePHP '.Hyde\Hyde::version()), Meta::property('site_name', config('site.name', 'HydePHP')), ], diff --git a/packages/framework/src/Foundation/HydeKernel.php b/packages/framework/src/Foundation/HydeKernel.php index a17d92cf0d6..d29622ef8d6 100644 --- a/packages/framework/src/Foundation/HydeKernel.php +++ b/packages/framework/src/Foundation/HydeKernel.php @@ -6,7 +6,6 @@ use Hyde\Framework\Concerns\JsonSerializesArrayable; use Hyde\Framework\Helpers\Features; -use Hyde\Foundation\Concerns; use Illuminate\Contracts\Support\Arrayable; use Illuminate\Support\Traits\Macroable; use JsonSerializable; From 2a8c4e195477495f69cf905e0593b580efd95369 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 19:16:51 +0200 Subject: [PATCH 013/768] Update resource paths --- packages/framework/src/Framework/HydeServiceProvider.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/framework/src/Framework/HydeServiceProvider.php b/packages/framework/src/Framework/HydeServiceProvider.php index 86fb8a109c5..f7b02b0fe23 100644 --- a/packages/framework/src/Framework/HydeServiceProvider.php +++ b/packages/framework/src/Framework/HydeServiceProvider.php @@ -69,18 +69,18 @@ public function register(): void */ public function boot(): void { - $this->loadViewsFrom(__DIR__.'/../resources/views', 'hyde'); + $this->loadViewsFrom(__DIR__.'/../../resources/views', 'hyde'); $this->publishes([ - __DIR__.'/../config' => config_path(), + __DIR__.'/../../config' => config_path(), ], 'configs'); $this->publishes([ - __DIR__.'/../resources/views/layouts' => resource_path('views/vendor/hyde/layouts'), + __DIR__.'/../../resources/views/layouts' => resource_path('views/vendor/hyde/layouts'), ], 'hyde-layouts'); $this->publishes([ - __DIR__.'/../resources/views/components' => resource_path('views/vendor/hyde/components'), + __DIR__.'/../../resources/views/components' => resource_path('views/vendor/hyde/components'), ], 'hyde-components'); $this->publishes([ From 60df64710f55842ff1ee4f8a0e2d56f5fa53fd75 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 19:19:57 +0200 Subject: [PATCH 014/768] Move Metadata module to root Hyde namespace --- .../src/Framework/Concerns/HydePage.php | 2 +- .../framework/src/Framework/Helpers/Meta.php | 14 ++++++------- .../src/Framework/Models/Support/Site.php | 2 +- .../Metadata/GlobalMetadataBag.php | 2 +- .../Modules => }/Metadata/MetadataBag.php | 12 +++++------ .../Metadata/MetadataElementContract.php | 2 +- .../Metadata/Models/LinkElement.php | 4 ++-- .../Metadata/Models/MetadataElement.php | 4 ++-- .../Metadata/Models/OpenGraphElement.php | 4 ++-- .../Modules => }/Metadata/PageMetadataBag.php | 2 +- .../tests/Feature/GlobalMetadataBagTest.php | 4 ++-- .../tests/Feature/MetadataHelperTest.php | 2 +- .../framework/tests/Feature/MetadataTest.php | 20 +++++++++---------- .../tests/Feature/MetadataViewTest.php | 6 +++--- packages/framework/tests/Feature/SiteTest.php | 2 +- 15 files changed, 41 insertions(+), 41 deletions(-) rename packages/framework/src/{Framework/Modules => }/Metadata/GlobalMetadataBag.php (97%) rename packages/framework/src/{Framework/Modules => }/Metadata/MetadataBag.php (84%) rename packages/framework/src/{Framework/Modules => }/Metadata/MetadataElementContract.php (93%) rename packages/framework/src/{Framework/Modules => }/Metadata/Models/LinkElement.php (89%) rename packages/framework/src/{Framework/Modules => }/Metadata/Models/MetadataElement.php (82%) rename packages/framework/src/{Framework/Modules => }/Metadata/Models/OpenGraphElement.php (87%) rename packages/framework/src/{Framework/Modules => }/Metadata/PageMetadataBag.php (98%) diff --git a/packages/framework/src/Framework/Concerns/HydePage.php b/packages/framework/src/Framework/Concerns/HydePage.php index 1546591ac2a..8d4ebae0894 100644 --- a/packages/framework/src/Framework/Concerns/HydePage.php +++ b/packages/framework/src/Framework/Concerns/HydePage.php @@ -12,9 +12,9 @@ use Hyde\Framework\Models\Markdown\FrontMatter; use Hyde\Framework\Models\Navigation\NavigationData; use Hyde\Framework\Models\Support\Route; -use Hyde\Framework\Modules\Metadata\PageMetadataBag; use Hyde\Framework\Services\DiscoveryService; use Hyde\Hyde; +use Hyde\Metadata\PageMetadataBag; use Illuminate\Support\Arr; /** diff --git a/packages/framework/src/Framework/Helpers/Meta.php b/packages/framework/src/Framework/Helpers/Meta.php index 8be29476785..3f2f4f0154f 100644 --- a/packages/framework/src/Framework/Helpers/Meta.php +++ b/packages/framework/src/Framework/Helpers/Meta.php @@ -4,10 +4,10 @@ namespace Hyde\Framework\Helpers; -use Hyde\Framework\Modules\Metadata\GlobalMetadataBag; -use Hyde\Framework\Modules\Metadata\Models\LinkElement; -use Hyde\Framework\Modules\Metadata\Models\MetadataElement; -use Hyde\Framework\Modules\Metadata\Models\OpenGraphElement; +use Hyde\Metadata\GlobalMetadataBag; +use Hyde\Metadata\Models\LinkElement; +use Hyde\Metadata\Models\MetadataElement; +use Hyde\Metadata\Models\OpenGraphElement; /** * Helpers to fluently declare HTML meta elements using their object representations. @@ -21,7 +21,7 @@ class Meta * * @param string $name The meta tag's name attribute. * @param string $content The content of the meta tag. - * @return \Hyde\Framework\Modules\Metadata\Models\MetadataElement + * @return \Hyde\Metadata\Models\MetadataElement * * @link https://www.w3schools.com/tags/tag_meta.asp */ @@ -35,7 +35,7 @@ public static function name(string $name, string $content): MetadataElement * * @param string $property The meta tag's property attribute. The "og:" prefix is optional. * @param string $content The content of the meta tag. - * @return \Hyde\Framework\Modules\Metadata\Models\OpenGraphElement + * @return \Hyde\Metadata\Models\OpenGraphElement * * @link https://ogp.me/ */ @@ -50,7 +50,7 @@ public static function property(string $property, string $content): OpenGraphEle * @param string $rel The link tag's rel attribute. * @param string $href The link tag's href attribute. * @param array $attr An optional key-value array of additional attributes. - * @return \Hyde\Framework\Modules\Metadata\Models\LinkElement + * @return \Hyde\Metadata\Models\LinkElement * * @link https://www.w3schools.com/tags/tag_link.asp */ diff --git a/packages/framework/src/Framework/Models/Support/Site.php b/packages/framework/src/Framework/Models/Support/Site.php index f0883aa9d08..2e3f6aadb53 100644 --- a/packages/framework/src/Framework/Models/Support/Site.php +++ b/packages/framework/src/Framework/Models/Support/Site.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Models\Support; -use Hyde\Framework\Modules\Metadata\GlobalMetadataBag; +use Hyde\Metadata\GlobalMetadataBag; /** * Object representation for the HydePHP site. diff --git a/packages/framework/src/Framework/Modules/Metadata/GlobalMetadataBag.php b/packages/framework/src/Metadata/GlobalMetadataBag.php similarity index 97% rename from packages/framework/src/Framework/Modules/Metadata/GlobalMetadataBag.php rename to packages/framework/src/Metadata/GlobalMetadataBag.php index 5cf22843f57..4687c323590 100644 --- a/packages/framework/src/Framework/Modules/Metadata/GlobalMetadataBag.php +++ b/packages/framework/src/Metadata/GlobalMetadataBag.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Modules\Metadata; +namespace Hyde\Metadata; use Hyde\Framework\Concerns\HydePage; use Hyde\Framework\Helpers\Features; diff --git a/packages/framework/src/Framework/Modules/Metadata/MetadataBag.php b/packages/framework/src/Metadata/MetadataBag.php similarity index 84% rename from packages/framework/src/Framework/Modules/Metadata/MetadataBag.php rename to packages/framework/src/Metadata/MetadataBag.php index d15c82fa4ac..a555e341f6a 100644 --- a/packages/framework/src/Framework/Modules/Metadata/MetadataBag.php +++ b/packages/framework/src/Metadata/MetadataBag.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Modules\Metadata; +namespace Hyde\Metadata; use Illuminate\Contracts\Support\Htmlable; @@ -10,8 +10,8 @@ * Holds the metadata tags for a page or the site model. * * @see \Hyde\Framework\Testing\Feature\MetadataTest - * @see \Hyde\Framework\Modules\Metadata\PageMetadataBag - * @see \Hyde\Framework\Modules\Metadata\GlobalMetadataBag + * @see \Hyde\Metadata\PageMetadataBag + * @see \Hyde\Metadata\GlobalMetadataBag */ class MetadataBag implements Htmlable { @@ -42,15 +42,15 @@ public function get(): array public function add(MetadataElementContract|string $element): static { - if ($element instanceof Models\LinkElement) { + if ($element instanceof \Hyde\Metadata\Models\LinkElement) { return $this->addElement('links', $element); } - if ($element instanceof Models\MetadataElement) { + if ($element instanceof \Hyde\Metadata\Models\MetadataElement) { return $this->addElement('metadata', $element); } - if ($element instanceof Models\OpenGraphElement) { + if ($element instanceof \Hyde\Metadata\Models\OpenGraphElement) { return $this->addElement('properties', $element); } diff --git a/packages/framework/src/Framework/Modules/Metadata/MetadataElementContract.php b/packages/framework/src/Metadata/MetadataElementContract.php similarity index 93% rename from packages/framework/src/Framework/Modules/Metadata/MetadataElementContract.php rename to packages/framework/src/Metadata/MetadataElementContract.php index ac062452482..64b724aaf26 100644 --- a/packages/framework/src/Framework/Modules/Metadata/MetadataElementContract.php +++ b/packages/framework/src/Metadata/MetadataElementContract.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Modules\Metadata; +namespace Hyde\Metadata; use Stringable; diff --git a/packages/framework/src/Framework/Modules/Metadata/Models/LinkElement.php b/packages/framework/src/Metadata/Models/LinkElement.php similarity index 89% rename from packages/framework/src/Framework/Modules/Metadata/Models/LinkElement.php rename to packages/framework/src/Metadata/Models/LinkElement.php index 57c8f700da9..6b7807599a1 100644 --- a/packages/framework/src/Framework/Modules/Metadata/Models/LinkElement.php +++ b/packages/framework/src/Metadata/Models/LinkElement.php @@ -2,9 +2,9 @@ declare(strict_types=1); -namespace Hyde\Framework\Modules\Metadata\Models; +namespace Hyde\Metadata\Models; -use Hyde\Framework\Modules\Metadata\MetadataElementContract; +use Hyde\Metadata\MetadataElementContract; class LinkElement implements MetadataElementContract { diff --git a/packages/framework/src/Framework/Modules/Metadata/Models/MetadataElement.php b/packages/framework/src/Metadata/Models/MetadataElement.php similarity index 82% rename from packages/framework/src/Framework/Modules/Metadata/Models/MetadataElement.php rename to packages/framework/src/Metadata/Models/MetadataElement.php index ed78718c4e0..035d3688b4b 100644 --- a/packages/framework/src/Framework/Modules/Metadata/Models/MetadataElement.php +++ b/packages/framework/src/Metadata/Models/MetadataElement.php @@ -2,9 +2,9 @@ declare(strict_types=1); -namespace Hyde\Framework\Modules\Metadata\Models; +namespace Hyde\Metadata\Models; -use Hyde\Framework\Modules\Metadata\MetadataElementContract; +use Hyde\Metadata\MetadataElementContract; class MetadataElement implements MetadataElementContract { diff --git a/packages/framework/src/Framework/Modules/Metadata/Models/OpenGraphElement.php b/packages/framework/src/Metadata/Models/OpenGraphElement.php similarity index 87% rename from packages/framework/src/Framework/Modules/Metadata/Models/OpenGraphElement.php rename to packages/framework/src/Metadata/Models/OpenGraphElement.php index 8abc9d4479f..85eeed4dde0 100644 --- a/packages/framework/src/Framework/Modules/Metadata/Models/OpenGraphElement.php +++ b/packages/framework/src/Metadata/Models/OpenGraphElement.php @@ -2,9 +2,9 @@ declare(strict_types=1); -namespace Hyde\Framework\Modules\Metadata\Models; +namespace Hyde\Metadata\Models; -use Hyde\Framework\Modules\Metadata\MetadataElementContract; +use Hyde\Metadata\MetadataElementContract; class OpenGraphElement implements MetadataElementContract { diff --git a/packages/framework/src/Framework/Modules/Metadata/PageMetadataBag.php b/packages/framework/src/Metadata/PageMetadataBag.php similarity index 98% rename from packages/framework/src/Framework/Modules/Metadata/PageMetadataBag.php rename to packages/framework/src/Metadata/PageMetadataBag.php index 80e08373576..680d0c4d997 100644 --- a/packages/framework/src/Framework/Modules/Metadata/PageMetadataBag.php +++ b/packages/framework/src/Metadata/PageMetadataBag.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Modules\Metadata; +namespace Hyde\Metadata; use Hyde\Framework\Concerns\HydePage; use Hyde\Framework\Helpers\Meta; diff --git a/packages/framework/tests/Feature/GlobalMetadataBagTest.php b/packages/framework/tests/Feature/GlobalMetadataBagTest.php index 51470a3bcaf..9abe0447490 100644 --- a/packages/framework/tests/Feature/GlobalMetadataBagTest.php +++ b/packages/framework/tests/Feature/GlobalMetadataBagTest.php @@ -6,12 +6,12 @@ use Hyde\Framework\Helpers\Meta; use Hyde\Framework\Models\Pages\MarkdownPage; -use Hyde\Framework\Modules\Metadata\GlobalMetadataBag; +use Hyde\Metadata\GlobalMetadataBag; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\View; /** - * @covers \Hyde\Framework\Modules\Metadata\GlobalMetadataBag + * @covers \Hyde\Metadata\GlobalMetadataBag */ class GlobalMetadataBagTest extends TestCase { diff --git a/packages/framework/tests/Feature/MetadataHelperTest.php b/packages/framework/tests/Feature/MetadataHelperTest.php index 8e528ce5cb9..932f98c6c79 100644 --- a/packages/framework/tests/Feature/MetadataHelperTest.php +++ b/packages/framework/tests/Feature/MetadataHelperTest.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Testing\Feature; use Hyde\Framework\Helpers\Meta; -use Hyde\Framework\Modules\Metadata\GlobalMetadataBag; +use Hyde\Metadata\GlobalMetadataBag; use Hyde\Testing\TestCase; /** diff --git a/packages/framework/tests/Feature/MetadataTest.php b/packages/framework/tests/Feature/MetadataTest.php index 56edf663631..a83b60e3f0c 100644 --- a/packages/framework/tests/Feature/MetadataTest.php +++ b/packages/framework/tests/Feature/MetadataTest.php @@ -8,19 +8,19 @@ use Hyde\Framework\Helpers\Meta; use Hyde\Framework\Models\Pages\MarkdownPage; use Hyde\Framework\Models\Pages\MarkdownPost; -use Hyde\Framework\Modules\Metadata\MetadataBag; -use Hyde\Framework\Modules\Metadata\Models\LinkElement; -use Hyde\Framework\Modules\Metadata\Models\MetadataElement; -use Hyde\Framework\Modules\Metadata\Models\OpenGraphElement; +use Hyde\Metadata\MetadataBag; +use Hyde\Metadata\Models\LinkElement; +use Hyde\Metadata\Models\MetadataElement; +use Hyde\Metadata\Models\OpenGraphElement; use Hyde\Testing\TestCase; /** - * @covers \Hyde\Framework\Modules\Metadata\MetadataBag - * @covers \Hyde\Framework\Modules\Metadata\PageMetadataBag - * @covers \Hyde\Framework\Modules\Metadata\GlobalMetadataBag - * @covers \Hyde\Framework\Modules\Metadata\Models\LinkElement - * @covers \Hyde\Framework\Modules\Metadata\Models\MetadataElement - * @covers \Hyde\Framework\Modules\Metadata\Models\OpenGraphElement + * @covers \Hyde\Metadata\MetadataBag + * @covers \Hyde\Metadata\PageMetadataBag + * @covers \Hyde\Metadata\GlobalMetadataBag + * @covers \Hyde\Metadata\Models\LinkElement + * @covers \Hyde\Metadata\Models\MetadataElement + * @covers \Hyde\Metadata\Models\OpenGraphElement */ class MetadataTest extends TestCase { diff --git a/packages/framework/tests/Feature/MetadataViewTest.php b/packages/framework/tests/Feature/MetadataViewTest.php index 08303304908..2ca023589df 100644 --- a/packages/framework/tests/Feature/MetadataViewTest.php +++ b/packages/framework/tests/Feature/MetadataViewTest.php @@ -15,9 +15,9 @@ * * This test is useful both as a regression test, and also to ensure all tags are covered. * - * @covers \Hyde\Framework\Modules\Metadata\MetadataBag - * @covers \Hyde\Framework\Modules\Metadata\PageMetadataBag - * @covers \Hyde\Framework\Modules\Metadata\GlobalMetadataBag + * @covers \Hyde\Metadata\MetadataBag + * @covers \Hyde\Metadata\PageMetadataBag + * @covers \Hyde\Metadata\GlobalMetadataBag */ class MetadataViewTest extends TestCase { diff --git a/packages/framework/tests/Feature/SiteTest.php b/packages/framework/tests/Feature/SiteTest.php index cfcf72be63a..af5c6204d78 100644 --- a/packages/framework/tests/Feature/SiteTest.php +++ b/packages/framework/tests/Feature/SiteTest.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Testing\Feature; use Hyde\Framework\Models\Support\Site; -use Hyde\Framework\Modules\Metadata\GlobalMetadataBag; +use Hyde\Metadata\GlobalMetadataBag; use Hyde\Testing\TestCase; /** From aff08a986991f040984a984c8bf45074b5c8685d Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 19:23:14 +0200 Subject: [PATCH 015/768] Move Markdown module to root Hyde namespace --- .../Internal/SetsUpMarkdownConverter.php | 6 +++--- .../Contracts/MarkdownShortcodeContract.php | 2 +- .../Modules => }/Markdown/BladeDownProcessor.php | 2 +- .../Markdown/CodeblockFilepathProcessor.php | 2 +- .../Modules => }/Markdown/ShortcodeProcessor.php | 4 ++-- .../Markdown/Shortcodes/ColoredBlockquotes.php | 2 +- .../Feature/ColoredBlockquoteShortcodesTest.php | 4 ++-- .../Feature/Services/BladeDownProcessorTest.php | 4 ++-- .../Markdown/CodeblockFilepathProcessorTest.php | 16 ++++++++-------- .../Services/Markdown/ShortcodeProcessorTest.php | 12 ++++++------ 10 files changed, 27 insertions(+), 27 deletions(-) rename packages/framework/src/{Framework/Modules => }/Markdown/BladeDownProcessor.php (98%) rename packages/framework/src/{Framework/Modules => }/Markdown/CodeblockFilepathProcessor.php (98%) rename packages/framework/src/{Framework/Modules => }/Markdown/ShortcodeProcessor.php (96%) rename packages/framework/src/{Framework/Modules => }/Markdown/Shortcodes/ColoredBlockquotes.php (96%) diff --git a/packages/framework/src/Framework/Concerns/Internal/SetsUpMarkdownConverter.php b/packages/framework/src/Framework/Concerns/Internal/SetsUpMarkdownConverter.php index 5e96add099f..a016487bce9 100644 --- a/packages/framework/src/Framework/Concerns/Internal/SetsUpMarkdownConverter.php +++ b/packages/framework/src/Framework/Concerns/Internal/SetsUpMarkdownConverter.php @@ -4,9 +4,9 @@ namespace Hyde\Framework\Concerns\Internal; -use Hyde\Framework\Modules\Markdown\BladeDownProcessor; -use Hyde\Framework\Modules\Markdown\CodeblockFilepathProcessor; -use Hyde\Framework\Modules\Markdown\ShortcodeProcessor; +use Hyde\Markdown\BladeDownProcessor; +use Hyde\Markdown\CodeblockFilepathProcessor; +use Hyde\Markdown\ShortcodeProcessor; use Torchlight\Commonmark\V2\TorchlightExtension; /** diff --git a/packages/framework/src/Framework/Contracts/MarkdownShortcodeContract.php b/packages/framework/src/Framework/Contracts/MarkdownShortcodeContract.php index 8a66d12f6df..b7e5e0eecf1 100644 --- a/packages/framework/src/Framework/Contracts/MarkdownShortcodeContract.php +++ b/packages/framework/src/Framework/Contracts/MarkdownShortcodeContract.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Contracts; /** - * @see \Hyde\Framework\Modules\Markdown\ShortcodeProcessor to see how this is used. + * @see \Hyde\Markdown\ShortcodeProcessor to see how this is used. */ interface MarkdownShortcodeContract { diff --git a/packages/framework/src/Framework/Modules/Markdown/BladeDownProcessor.php b/packages/framework/src/Markdown/BladeDownProcessor.php similarity index 98% rename from packages/framework/src/Framework/Modules/Markdown/BladeDownProcessor.php rename to packages/framework/src/Markdown/BladeDownProcessor.php index 584d6ccfd1b..b3df0e6a8fc 100644 --- a/packages/framework/src/Framework/Modules/Markdown/BladeDownProcessor.php +++ b/packages/framework/src/Markdown/BladeDownProcessor.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Modules\Markdown; +namespace Hyde\Markdown; use Hyde\Framework\Contracts\MarkdownPostProcessorContract; use Hyde\Framework\Contracts\MarkdownPreProcessorContract; diff --git a/packages/framework/src/Framework/Modules/Markdown/CodeblockFilepathProcessor.php b/packages/framework/src/Markdown/CodeblockFilepathProcessor.php similarity index 98% rename from packages/framework/src/Framework/Modules/Markdown/CodeblockFilepathProcessor.php rename to packages/framework/src/Markdown/CodeblockFilepathProcessor.php index 50cb38d4876..7e22fb25ac1 100644 --- a/packages/framework/src/Framework/Modules/Markdown/CodeblockFilepathProcessor.php +++ b/packages/framework/src/Markdown/CodeblockFilepathProcessor.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Modules\Markdown; +namespace Hyde\Markdown; use Hyde\Framework\Contracts\MarkdownPostProcessorContract; use Hyde\Framework\Contracts\MarkdownPreProcessorContract; diff --git a/packages/framework/src/Framework/Modules/Markdown/ShortcodeProcessor.php b/packages/framework/src/Markdown/ShortcodeProcessor.php similarity index 96% rename from packages/framework/src/Framework/Modules/Markdown/ShortcodeProcessor.php rename to packages/framework/src/Markdown/ShortcodeProcessor.php index c492ab9e00e..6f122d2df5b 100644 --- a/packages/framework/src/Framework/Modules/Markdown/ShortcodeProcessor.php +++ b/packages/framework/src/Markdown/ShortcodeProcessor.php @@ -2,11 +2,11 @@ declare(strict_types=1); -namespace Hyde\Framework\Modules\Markdown; +namespace Hyde\Markdown; use Hyde\Framework\Contracts\MarkdownPreProcessorContract; use Hyde\Framework\Contracts\MarkdownShortcodeContract; -use Hyde\Framework\Modules\Markdown\Shortcodes\ColoredBlockquotes; +use Hyde\Markdown\Shortcodes\ColoredBlockquotes; /** * Handle all shortcode processing for a Markdown conversion. diff --git a/packages/framework/src/Framework/Modules/Markdown/Shortcodes/ColoredBlockquotes.php b/packages/framework/src/Markdown/Shortcodes/ColoredBlockquotes.php similarity index 96% rename from packages/framework/src/Framework/Modules/Markdown/Shortcodes/ColoredBlockquotes.php rename to packages/framework/src/Markdown/Shortcodes/ColoredBlockquotes.php index c15560115f6..fb846e96ab9 100644 --- a/packages/framework/src/Framework/Modules/Markdown/Shortcodes/ColoredBlockquotes.php +++ b/packages/framework/src/Markdown/Shortcodes/ColoredBlockquotes.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Modules\Markdown\Shortcodes; +namespace Hyde\Markdown\Shortcodes; use Hyde\Framework\Contracts\MarkdownShortcodeContract; diff --git a/packages/framework/tests/Feature/ColoredBlockquoteShortcodesTest.php b/packages/framework/tests/Feature/ColoredBlockquoteShortcodesTest.php index 12217dfe1f3..b142a2c58f0 100644 --- a/packages/framework/tests/Feature/ColoredBlockquoteShortcodesTest.php +++ b/packages/framework/tests/Feature/ColoredBlockquoteShortcodesTest.php @@ -4,13 +4,13 @@ namespace Hyde\Framework\Testing\Feature; -use Hyde\Framework\Modules\Markdown\Shortcodes\ColoredBlockquotes; +use Hyde\Markdown\Shortcodes\ColoredBlockquotes; use Hyde\Testing\TestCase; /** * Class ColoredBlockquoteShortcodesTest. * - * @covers \Hyde\Framework\Modules\Markdown\Shortcodes\ColoredBlockquotes + * @covers \Hyde\Markdown\Shortcodes\ColoredBlockquotes */ class ColoredBlockquoteShortcodesTest extends TestCase { diff --git a/packages/framework/tests/Feature/Services/BladeDownProcessorTest.php b/packages/framework/tests/Feature/Services/BladeDownProcessorTest.php index 603eb454104..21a38012551 100644 --- a/packages/framework/tests/Feature/Services/BladeDownProcessorTest.php +++ b/packages/framework/tests/Feature/Services/BladeDownProcessorTest.php @@ -4,13 +4,13 @@ namespace Hyde\Framework\Testing\Feature\Services; -use Hyde\Framework\Modules\Markdown\BladeDownProcessor; +use Hyde\Markdown\BladeDownProcessor; use Hyde\Testing\TestCase; /** * Class BladeDownProcessorTest. * - * @covers \Hyde\Framework\Modules\Markdown\BladeDownProcessor + * @covers \Hyde\Markdown\BladeDownProcessor */ class BladeDownProcessorTest extends TestCase { diff --git a/packages/framework/tests/Feature/Services/Markdown/CodeblockFilepathProcessorTest.php b/packages/framework/tests/Feature/Services/Markdown/CodeblockFilepathProcessorTest.php index f3dd2d33622..90facf347f2 100644 --- a/packages/framework/tests/Feature/Services/Markdown/CodeblockFilepathProcessorTest.php +++ b/packages/framework/tests/Feature/Services/Markdown/CodeblockFilepathProcessorTest.php @@ -4,11 +4,11 @@ namespace Hyde\Framework\Testing\Feature\Services\Markdown; -use Hyde\Framework\Modules\Markdown\CodeblockFilepathProcessor; +use Hyde\Markdown\CodeblockFilepathProcessor; use Hyde\Testing\TestCase; /** - * @covers \Hyde\Framework\Modules\Markdown\CodeblockFilepathProcessor + * @covers \Hyde\Markdown\CodeblockFilepathProcessor */ class CodeblockFilepathProcessorTest extends TestCase { @@ -37,7 +37,7 @@ public function test_preprocess_accepts_multiple_filepath_formats() $markdown = "\n```php\n{$pattern}foo.php\necho 'Hello World';\n```"; $expected = "\n\n```php\necho 'Hello World';\n```"; - $this->assertEquals($expected, CodeblockFilepathProcessor::preprocess($markdown)); + $this->assertEquals($expected, \Hyde\Markdown\CodeblockFilepathProcessor::preprocess($markdown)); } } @@ -55,10 +55,10 @@ public function test_preprocess_accepts_multiple_languages() $markdown = "\n```{$language}\n// filepath: foo.{$language}\nfoo\n```"; $expected = "\n\n```{$language}\nfoo\n```"; - $this->assertEquals($expected, \Hyde\Framework\Modules\Markdown\CodeblockFilepathProcessor::preprocess($markdown)); + $this->assertEquals($expected, \Hyde\Markdown\CodeblockFilepathProcessor::preprocess($markdown)); } - $this->assertEquals($expected, \Hyde\Framework\Modules\Markdown\CodeblockFilepathProcessor::preprocess($markdown)); + $this->assertEquals($expected, \Hyde\Markdown\CodeblockFilepathProcessor::preprocess($markdown)); } public function test_preprocess_accepts_multiple_input_blocks() @@ -114,7 +114,7 @@ public function test_preprocess_accepts_multi_line_codeblocks() ``` MD; - $this->assertEqualsIgnoringLineReturnType($expected, \Hyde\Framework\Modules\Markdown\CodeblockFilepathProcessor::preprocess($markdown)); + $this->assertEqualsIgnoringLineReturnType($expected, \Hyde\Markdown\CodeblockFilepathProcessor::preprocess($markdown)); } public function test_space_after_filepath_is_optional() @@ -136,8 +136,8 @@ public function test_space_after_filepath_is_optional() ``` MD; - $this->assertEqualsIgnoringLineReturnType(\Hyde\Framework\Modules\Markdown\CodeblockFilepathProcessor::preprocess($expected), - \Hyde\Framework\Modules\Markdown\CodeblockFilepathProcessor::preprocess($markdown)); + $this->assertEqualsIgnoringLineReturnType(\Hyde\Markdown\CodeblockFilepathProcessor::preprocess($expected), + \Hyde\Markdown\CodeblockFilepathProcessor::preprocess($markdown)); } public function test_processor_expands_filepath_directive_in_standard_codeblock() diff --git a/packages/framework/tests/Feature/Services/Markdown/ShortcodeProcessorTest.php b/packages/framework/tests/Feature/Services/Markdown/ShortcodeProcessorTest.php index a88d23f2cf5..4a72e001206 100644 --- a/packages/framework/tests/Feature/Services/Markdown/ShortcodeProcessorTest.php +++ b/packages/framework/tests/Feature/Services/Markdown/ShortcodeProcessorTest.php @@ -5,11 +5,11 @@ namespace Hyde\Framework\Testing\Feature\Services\Markdown; use Hyde\Framework\Contracts\MarkdownShortcodeContract; -use Hyde\Framework\Modules\Markdown\ShortcodeProcessor; +use Hyde\Markdown\ShortcodeProcessor; use Hyde\Testing\TestCase; /** - * @covers \Hyde\Framework\Modules\Markdown\ShortcodeProcessor + * @covers \Hyde\Markdown\ShortcodeProcessor */ class ShortcodeProcessorTest extends TestCase { @@ -23,7 +23,7 @@ public function test_constructor_discovers_default_shortcodes() public function test_discovered_shortcodes_are_used_to_process_input() { - $processor = new \Hyde\Framework\Modules\Markdown\ShortcodeProcessor('>info foo'); + $processor = new \Hyde\Markdown\ShortcodeProcessor('>info foo'); $this->assertEquals('
foo
', $processor->run()); @@ -31,7 +31,7 @@ public function test_discovered_shortcodes_are_used_to_process_input() public function test_string_without_shortcode_is_not_modified() { - $processor = new \Hyde\Framework\Modules\Markdown\ShortcodeProcessor('foo'); + $processor = new \Hyde\Markdown\ShortcodeProcessor('foo'); $this->assertEquals('foo', $processor->run()); } @@ -39,12 +39,12 @@ public function test_string_without_shortcode_is_not_modified() public function test_process_static_shorthand() { $this->assertEquals('
foo
', - ShortcodeProcessor::preprocess('>info foo')); + \Hyde\Markdown\ShortcodeProcessor::preprocess('>info foo')); } public function test_shortcodes_can_be_added_to_processor() { - $processor = new \Hyde\Framework\Modules\Markdown\ShortcodeProcessor('foo'); + $processor = new \Hyde\Markdown\ShortcodeProcessor('foo'); $processor->addShortcode(new class implements MarkdownShortcodeContract { From 79a69645a1b35883b553d2631dd5ac3752ab80f4 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 19:31:07 +0200 Subject: [PATCH 016/768] Move DataCollections module to root Hyde namespace --- docs/digging-deeper/collections.md | 2 +- .../Modules => }/DataCollections/DataCollection.php | 2 +- .../DataCollectionServiceProvider.php | 4 ++-- .../DataCollections/Facades/MarkdownCollection.php | 4 ++-- .../framework/src/Framework/HydeServiceProvider.php | 2 +- .../framework/tests/Feature/DataCollectionTest.php | 12 ++++++------ .../framework/tests/Unit/HydeServiceProviderTest.php | 2 +- 7 files changed, 14 insertions(+), 14 deletions(-) rename packages/framework/src/{Framework/Modules => }/DataCollections/DataCollection.php (97%) rename packages/framework/src/{Framework/Modules => }/DataCollections/DataCollectionServiceProvider.php (88%) rename packages/framework/src/{Framework/Modules => }/DataCollections/Facades/MarkdownCollection.php (69%) diff --git a/docs/digging-deeper/collections.md b/docs/digging-deeper/collections.md index 82cfad48b5d..be41b07cd6b 100644 --- a/docs/digging-deeper/collections.md +++ b/docs/digging-deeper/collections.md @@ -88,7 +88,7 @@ MarkdownCollection::get('subdirectory_name') This will return a Hyde DataCollection object, containing our Markdown files as MarkdownDocument objects. Here is a quick look at the object the facade returns: -
^ Hyde\Framework\Modules\DataCollections\DataCollection {#270 ▼ 
  +key: "testimonials"
  #items: array:5 [
    0 => Hyde\Framework\Models\MarkdownDocument {#273 ▼
      +matter: array:1 []
      +body: "Lorem ipsum dolor sit amet, consectetur adipiscing elit...\n"
      +title: ""
      +slug: ""
    
}
    1 => Hyde\Framework\Models\MarkdownDocument {#274 ▶}
    2 => Hyde\Framework\Models\MarkdownDocument {#275 ▶}
    [The rest is truncated to conserve space...]
+
^ Hyde\DataCollections\DataCollection {#270 ▼ 
  +key: "testimonials"
  #items: array:5 [
    0 => Hyde\Framework\Models\MarkdownDocument {#273 ▼
      +matter: array:1 []
      +body: "Lorem ipsum dolor sit amet, consectetur adipiscing elit...\n"
      +title: ""
      +slug: ""
    
}
    1 => Hyde\Framework\Models\MarkdownDocument {#274 ▶}
    2 => Hyde\Framework\Models\MarkdownDocument {#275 ▶}
    [The rest is truncated to conserve space...]
#### Implementing it in a Blade view diff --git a/packages/framework/src/Framework/Modules/DataCollections/DataCollection.php b/packages/framework/src/DataCollections/DataCollection.php similarity index 97% rename from packages/framework/src/Framework/Modules/DataCollections/DataCollection.php rename to packages/framework/src/DataCollections/DataCollection.php index d5aca948094..9cea37df393 100644 --- a/packages/framework/src/Framework/Modules/DataCollections/DataCollection.php +++ b/packages/framework/src/DataCollections/DataCollection.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Modules\DataCollections; +namespace Hyde\DataCollections; use Hyde\Framework\Actions\MarkdownFileParser; use Hyde\Hyde; diff --git a/packages/framework/src/Framework/Modules/DataCollections/DataCollectionServiceProvider.php b/packages/framework/src/DataCollections/DataCollectionServiceProvider.php similarity index 88% rename from packages/framework/src/Framework/Modules/DataCollections/DataCollectionServiceProvider.php rename to packages/framework/src/DataCollections/DataCollectionServiceProvider.php index 5469c0002cd..1c60c6da21d 100644 --- a/packages/framework/src/Framework/Modules/DataCollections/DataCollectionServiceProvider.php +++ b/packages/framework/src/DataCollections/DataCollectionServiceProvider.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Modules\DataCollections; +namespace Hyde\DataCollections; use Hyde\Framework\Helpers\Features; use Hyde\Hyde; @@ -19,7 +19,7 @@ public function register() // Register the class alias AliasLoader::getInstance()->alias( 'MarkdownCollection', - Facades\MarkdownCollection::class + \Hyde\DataCollections\Facades\MarkdownCollection::class ); } diff --git a/packages/framework/src/Framework/Modules/DataCollections/Facades/MarkdownCollection.php b/packages/framework/src/DataCollections/Facades/MarkdownCollection.php similarity index 69% rename from packages/framework/src/Framework/Modules/DataCollections/Facades/MarkdownCollection.php rename to packages/framework/src/DataCollections/Facades/MarkdownCollection.php index 54100494691..795816ca26a 100644 --- a/packages/framework/src/Framework/Modules/DataCollections/Facades/MarkdownCollection.php +++ b/packages/framework/src/DataCollections/Facades/MarkdownCollection.php @@ -2,9 +2,9 @@ declare(strict_types=1); -namespace Hyde\Framework\Modules\DataCollections\Facades; +namespace Hyde\DataCollections\Facades; -use Hyde\Framework\Modules\DataCollections\DataCollection; +use Hyde\DataCollections\DataCollection; /** * @see \Hyde\Framework\Testing\Feature\DataCollectionTest diff --git a/packages/framework/src/Framework/HydeServiceProvider.php b/packages/framework/src/Framework/HydeServiceProvider.php index f7b02b0fe23..9a9e1204ceb 100644 --- a/packages/framework/src/Framework/HydeServiceProvider.php +++ b/packages/framework/src/Framework/HydeServiceProvider.php @@ -134,6 +134,6 @@ protected function registerHydeConsoleCommands(): void */ protected function registerModuleServiceProviders(): void { - $this->app->register(Modules\DataCollections\DataCollectionServiceProvider::class); + $this->app->register(\Hyde\DataCollections\DataCollectionServiceProvider::class); } } diff --git a/packages/framework/tests/Feature/DataCollectionTest.php b/packages/framework/tests/Feature/DataCollectionTest.php index 88b038b849b..30aab0ad3c2 100644 --- a/packages/framework/tests/Feature/DataCollectionTest.php +++ b/packages/framework/tests/Feature/DataCollectionTest.php @@ -4,11 +4,11 @@ namespace Hyde\Framework\Testing\Feature; +use Hyde\DataCollections\DataCollection; +use Hyde\DataCollections\DataCollectionServiceProvider; +use Hyde\DataCollections\Facades\MarkdownCollection; use Hyde\Framework\Helpers\Features; use Hyde\Framework\Models\Markdown\MarkdownDocument; -use Hyde\Framework\Modules\DataCollections\DataCollection; -use Hyde\Framework\Modules\DataCollections\DataCollectionServiceProvider; -use Hyde\Framework\Modules\DataCollections\Facades\MarkdownCollection; use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Foundation\AliasLoader; @@ -16,9 +16,9 @@ use Illuminate\Support\Facades\File; /** - * @covers \Hyde\Framework\Modules\DataCollections\DataCollection - * @covers \Hyde\Framework\Modules\DataCollections\DataCollectionServiceProvider - * @covers \Hyde\Framework\Modules\DataCollections\Facades\MarkdownCollection + * @covers \Hyde\DataCollections\DataCollection + * @covers \Hyde\DataCollections\DataCollectionServiceProvider + * @covers \Hyde\DataCollections\Facades\MarkdownCollection */ class DataCollectionTest extends TestCase { diff --git a/packages/framework/tests/Unit/HydeServiceProviderTest.php b/packages/framework/tests/Unit/HydeServiceProviderTest.php index 8adb469ef30..9702e85928d 100644 --- a/packages/framework/tests/Unit/HydeServiceProviderTest.php +++ b/packages/framework/tests/Unit/HydeServiceProviderTest.php @@ -4,13 +4,13 @@ namespace Hyde\Framework\Testing\Unit; +use Hyde\DataCollections\DataCollectionServiceProvider; use Hyde\Framework\HydeServiceProvider; use Hyde\Framework\Models\Pages\BladePage; use Hyde\Framework\Models\Pages\DocumentationPage; use Hyde\Framework\Models\Pages\MarkdownPage; use Hyde\Framework\Models\Pages\MarkdownPost; use Hyde\Framework\Models\Support\Site; -use Hyde\Framework\Modules\DataCollections\DataCollectionServiceProvider; use Hyde\Framework\Services\AssetService; use Hyde\Hyde; use Hyde\Testing\TestCase; From d9e0276807ba4061ea644a763d38169cfcbe6f4b Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 19:40:42 +0200 Subject: [PATCH 017/768] Delete Modules\README.md --- packages/framework/src/Framework/Modules/README.md | 10 ---------- 1 file changed, 10 deletions(-) delete mode 100644 packages/framework/src/Framework/Modules/README.md diff --git a/packages/framework/src/Framework/Modules/README.md b/packages/framework/src/Framework/Modules/README.md deleted file mode 100644 index 57fff10f6f5..00000000000 --- a/packages/framework/src/Framework/Modules/README.md +++ /dev/null @@ -1,10 +0,0 @@ -# Hyde Modules - -This directory contains self-contained code modules, -that may eventually be extracted into packages. - -They may also be merged into the Hyde core. - -As these modules may be experimental, -the namespaces used may be changed without notice -as per the current 0.x semantic versioning range. From db4d79b74d419debeb474c35704e8db83e2e8567 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 19:50:30 +0200 Subject: [PATCH 018/768] Delete projects/shelf directory --- projects/shelf/README.md | 3 - projects/shelf/admin/CONTRIBUTING.md | 55 --- projects/shelf/admin/LICENSE.md | 21 - projects/shelf/admin/README.md | 52 -- projects/shelf/admin/composer.json | 55 --- projects/shelf/admin/config/config.php | 8 - .../resources/views/components/card.blade.php | 3 - .../views/components/header.blade.php | 8 - .../views/components/sidebar-link.blade.php | 16 - .../admin/resources/views/dashboard.blade.php | 48 -- .../resources/views/layouts/footer.blade.php | 39 -- .../views/layouts/navigation.blade.php | 17 - .../resources/views/layouts/sidebar.blade.php | 58 --- .../admin/resources/views/pages/404.blade.php | 11 - .../resources/views/pages/dashboard.blade.php | 219 --------- .../resources/views/pages/docs.blade.php | 59 --- .../resources/views/pages/media.blade.php | 113 ----- .../resources/views/pages/pages.blade.php | 103 ---- .../resources/views/pages/posts.blade.php | 70 --- projects/shelf/admin/src/Admin.php | 8 - projects/shelf/admin/src/AdminPage.php | 49 -- .../shelf/admin/src/AdminServiceProvider.php | 18 - .../dashboard-manual.txt | 68 --- .../shelf/single-file-dashboard/dashboard.php | 465 ------------------ 24 files changed, 1566 deletions(-) delete mode 100644 projects/shelf/README.md delete mode 100644 projects/shelf/admin/CONTRIBUTING.md delete mode 100644 projects/shelf/admin/LICENSE.md delete mode 100644 projects/shelf/admin/README.md delete mode 100644 projects/shelf/admin/composer.json delete mode 100644 projects/shelf/admin/config/config.php delete mode 100644 projects/shelf/admin/resources/views/components/card.blade.php delete mode 100644 projects/shelf/admin/resources/views/components/header.blade.php delete mode 100644 projects/shelf/admin/resources/views/components/sidebar-link.blade.php delete mode 100644 projects/shelf/admin/resources/views/dashboard.blade.php delete mode 100644 projects/shelf/admin/resources/views/layouts/footer.blade.php delete mode 100644 projects/shelf/admin/resources/views/layouts/navigation.blade.php delete mode 100644 projects/shelf/admin/resources/views/layouts/sidebar.blade.php delete mode 100644 projects/shelf/admin/resources/views/pages/404.blade.php delete mode 100644 projects/shelf/admin/resources/views/pages/dashboard.blade.php delete mode 100644 projects/shelf/admin/resources/views/pages/docs.blade.php delete mode 100644 projects/shelf/admin/resources/views/pages/media.blade.php delete mode 100644 projects/shelf/admin/resources/views/pages/pages.blade.php delete mode 100644 projects/shelf/admin/resources/views/pages/posts.blade.php delete mode 100644 projects/shelf/admin/src/Admin.php delete mode 100644 projects/shelf/admin/src/AdminPage.php delete mode 100644 projects/shelf/admin/src/AdminServiceProvider.php delete mode 100644 projects/shelf/single-file-dashboard/dashboard-manual.txt delete mode 100644 projects/shelf/single-file-dashboard/dashboard.php diff --git a/projects/shelf/README.md b/projects/shelf/README.md deleted file mode 100644 index ff9fa6ffdbc..00000000000 --- a/projects/shelf/README.md +++ /dev/null @@ -1,3 +0,0 @@ -# The Shelf - -A collection of work-in-progress projects that may or may not work. diff --git a/projects/shelf/admin/CONTRIBUTING.md b/projects/shelf/admin/CONTRIBUTING.md deleted file mode 100644 index b4ae1c4a7cf..00000000000 --- a/projects/shelf/admin/CONTRIBUTING.md +++ /dev/null @@ -1,55 +0,0 @@ -# Contributing - -Contributions are **welcome** and will be fully **credited**. - -Please read and understand the contribution guide before creating an issue or pull request. - -## Etiquette - -This project is open source, and as such, the maintainers give their free time to build and maintain the source code -held within. They make the code freely available in the hope that it will be of use to other developers. It would be -extremely unfair for them to suffer abuse or anger for their hard work. - -Please be considerate towards maintainers when raising issues or presenting pull requests. Let's show the -world that developers are civilized and selfless people. - -It's the duty of the maintainer to ensure that all submissions to the project are of sufficient -quality to benefit the project. Many developers have different skillsets, strengths, and weaknesses. Respect the maintainer's decision, and do not be upset or abusive if your submission is not used. - -## Viability - -When requesting or submitting new features, first consider whether it might be useful to others. Open -source projects are used by many developers, who may have entirely different needs to your own. Think about -whether or not your feature is likely to be used by other users of the project. - -## Procedure - -Before filing an issue: - -- Attempt to replicate the problem, to ensure that it wasn't a coincidental incident. -- Check to make sure your feature suggestion isn't already present within the project. -- Check the pull requests tab to ensure that the bug doesn't have a fix in progress. -- Check the pull requests tab to ensure that the feature isn't already in progress. - -Before submitting a pull request: - -- Check the codebase to ensure that your feature doesn't already exist. -- Check the pull requests to ensure that another person hasn't already submitted the feature or fix. - -## Requirements - -If the project maintainer has any additional requirements, you will find them listed here. - -- **[PSR-2 Coding Standard](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-2-coding-style-guide.md)** - The easiest way to apply the conventions is to install [PHP Code Sniffer](https://pear.php.net/package/PHP_CodeSniffer). - -- **Add tests!** - Your patch won't be accepted if it doesn't have tests. - -- **Document any change in behaviour** - Make sure the `README.md` and any other relevant documentation are kept up-to-date. - -- **Consider our release cycle** - We try to follow [SemVer v2.0.0](https://semver.org/). Randomly breaking public APIs is not an option. - -- **One pull request per feature** - If you want to do more than one thing, send multiple pull requests. - -- **Send coherent history** - Make sure each individual commit in your pull request is meaningful. If you had to make multiple intermediate commits while developing, please [squash them](https://www.git-scm.com/book/en/v2/Git-Tools-Rewriting-History#Changing-Multiple-Commit-Messages) before submitting. - -**Happy coding**! diff --git a/projects/shelf/admin/LICENSE.md b/projects/shelf/admin/LICENSE.md deleted file mode 100644 index f9d246d3801..00000000000 --- a/projects/shelf/admin/LICENSE.md +++ /dev/null @@ -1,21 +0,0 @@ -MIT License - -Copyright (c) Caen De Silva - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. \ No newline at end of file diff --git a/projects/shelf/admin/README.md b/projects/shelf/admin/README.md deleted file mode 100644 index b750da0a788..00000000000 --- a/projects/shelf/admin/README.md +++ /dev/null @@ -1,52 +0,0 @@ -# Very short description of the package - -[![Latest Version on Packagist](https://img.shields.io/packagist/v/hyde/admin.svg?style=flat-square)](https://packagist.org/packages/hyde/admin) -[![Total Downloads](https://img.shields.io/packagist/dt/hyde/admin.svg?style=flat-square)](https://packagist.org/packages/hyde/admin) -![GitHub Actions](https://github.com/hyde/admin/actions/workflows/main.yml/badge.svg) - -This is where your description should go. Try and limit it to a paragraph or two, and maybe throw in a mention of what PSRs you support to avoid any confusion with users and contributors. - -## Installation - -You can install the package via composer: - -```bash -composer require hyde/admin -``` - -## Usage - -```php -// Usage description here -``` - -### Testing - -```bash -composer test -``` - -### Changelog - -Please see [CHANGELOG](CHANGELOG.md) for more information what has changed recently. - -## Contributing - -Please see [CONTRIBUTING](CONTRIBUTING.md) for details. - -### Security - -If you discover any security related issues, please email caen@desilva.se instead of using the issue tracker. - -## Credits - -- [Caen De Silva](https://github.com/hyde) -- [All Contributors](../../contributors) - -## License - -The MIT License (MIT). Please see [License File](LICENSE.md) for more information. - -## Laravel Package Boilerplate - -This package was generated using the [Laravel Package Boilerplate](https://laravelpackageboilerplate.com). diff --git a/projects/shelf/admin/composer.json b/projects/shelf/admin/composer.json deleted file mode 100644 index a82bdf4a7bc..00000000000 --- a/projects/shelf/admin/composer.json +++ /dev/null @@ -1,55 +0,0 @@ -{ - "name": "hyde/admin", - "description": "Experimental admin panel for local HydePHP development", - "keywords": [ - "hyde", - "admin" - ], - "homepage": "https://github.com/hyde/admin", - "license": "MIT", - "type": "library", - "authors": [ - { - "name": "Caen De Silva", - "email": "caen@desilva.se", - "role": "Developer" - } - ], - "require": { - "php": "^7.4|^8.0", - "illuminate/support": "^9.5", - "hyde/framework": "dev-master" - }, - "require-dev": { - "orchestra/testbench": "^6.0", - "phpunit/phpunit": "^9.0" - }, - "autoload": { - "psr-4": { - "Hyde\\Admin\\": "src" - } - }, - "autoload-dev": { - "psr-4": { - "Hyde\\Admin\\Tests\\": "tests" - } - }, - "scripts": { - "test": "vendor/bin/phpunit", - "test-coverage": "vendor/bin/phpunit --coverage-html coverage" - - }, - "config": { - "sort-packages": true - }, - "extra": { - "laravel": { - "providers": [ - "Hyde\\Admin\\AdminServiceProvider" - ], - "aliases": { - "Admin": "Hyde\\Admin\\AdminFacade" - } - } - } -} diff --git a/projects/shelf/admin/config/config.php b/projects/shelf/admin/config/config.php deleted file mode 100644 index aaec0920123..00000000000 --- a/projects/shelf/admin/config/config.php +++ /dev/null @@ -1,8 +0,0 @@ -merge(['class' => 'relative flex flex-col min-w-0 break-words bg-white w-full mb-6 px-6 py-4 shadow-lg rounded']) }}> - {{ $slot }} - \ No newline at end of file diff --git a/projects/shelf/admin/resources/views/components/header.blade.php b/projects/shelf/admin/resources/views/components/header.blade.php deleted file mode 100644 index 35fc4964955..00000000000 --- a/projects/shelf/admin/resources/views/components/header.blade.php +++ /dev/null @@ -1,8 +0,0 @@ - -
-
-
- {{ $slot }} -
-
-
\ No newline at end of file diff --git a/projects/shelf/admin/resources/views/components/sidebar-link.blade.php b/projects/shelf/admin/resources/views/components/sidebar-link.blade.php deleted file mode 100644 index cbd9bec9e98..00000000000 --- a/projects/shelf/admin/resources/views/components/sidebar-link.blade.php +++ /dev/null @@ -1,16 +0,0 @@ -@props([ - 'route', - 'label', - 'icon' => 'file', - 'active' => $page->route == $route -]) - - $active ])> - $active, - 'text-slate-300' => ! $active - ])> -{{ $label }} diff --git a/projects/shelf/admin/resources/views/dashboard.blade.php b/projects/shelf/admin/resources/views/dashboard.blade.php deleted file mode 100644 index 76fa4aff324..00000000000 --- a/projects/shelf/admin/resources/views/dashboard.blade.php +++ /dev/null @@ -1,48 +0,0 @@ - - - - - - - - - - - Dashboard | {{ config('hyde.name') }} Admin - - - -
- @include('hyde-admin::layouts.sidebar') - -
- @include('hyde-admin::layouts.navigation') - -
- @include($page->view()) -
- - @include('hyde-admin::layouts.footer') -
-
- - \ No newline at end of file diff --git a/projects/shelf/admin/resources/views/layouts/footer.blade.php b/projects/shelf/admin/resources/views/layouts/footer.blade.php deleted file mode 100644 index 9bfde1b88d9..00000000000 --- a/projects/shelf/admin/resources/views/layouts/footer.blade.php +++ /dev/null @@ -1,39 +0,0 @@ - \ No newline at end of file diff --git a/projects/shelf/admin/resources/views/layouts/navigation.blade.php b/projects/shelf/admin/resources/views/layouts/navigation.blade.php deleted file mode 100644 index 9caed5e8351..00000000000 --- a/projects/shelf/admin/resources/views/layouts/navigation.blade.php +++ /dev/null @@ -1,17 +0,0 @@ - \ No newline at end of file diff --git a/projects/shelf/admin/resources/views/layouts/sidebar.blade.php b/projects/shelf/admin/resources/views/layouts/sidebar.blade.php deleted file mode 100644 index ce79d113e84..00000000000 --- a/projects/shelf/admin/resources/views/layouts/sidebar.blade.php +++ /dev/null @@ -1,58 +0,0 @@ - \ No newline at end of file diff --git a/projects/shelf/admin/resources/views/pages/404.blade.php b/projects/shelf/admin/resources/views/pages/404.blade.php deleted file mode 100644 index 28e9dbea345..00000000000 --- a/projects/shelf/admin/resources/views/pages/404.blade.php +++ /dev/null @@ -1,11 +0,0 @@ - - - - - \ No newline at end of file diff --git a/projects/shelf/admin/resources/views/pages/dashboard.blade.php b/projects/shelf/admin/resources/views/pages/dashboard.blade.php deleted file mode 100644 index 10dc9bedd28..00000000000 --- a/projects/shelf/admin/resources/views/pages/dashboard.blade.php +++ /dev/null @@ -1,219 +0,0 @@ -@php -use Hyde\Framework\Services\DiscoveryService; -@endphp - - - -
-
-
-
-
-
-
Blade Pages
- {{ count(DiscoveryService::getBladePageFiles()) }} pages -
-
-
- -
-
-
- {{--

- - 3.48% - Since last month -

--}} -
-
-
-
-
-
-
-
-
Markdown Pages
- {{ count(DiscoveryService::getMarkdownPageFiles()) }} pages -
-
-
- -
-
-
- {{--

- - 3.48% - Since last week -

--}} -
-
-
-
-
-
-
-
-
Documentation Pages
- {{ count(DiscoveryService::getDocumentationPageFiles()) }} pages -
-
-
- -
-
-
- {{--

- - 1.10% - Since yesterday -

--}} -
-
-
-
-
-
-
-
-
Markdown Posts
- {{ count(DiscoveryService::getMarkdownPostFiles()) }} posts -
-
-
- -
-
-
- {{--

- - 12% - Since last month -

--}} -
-
-
-
-
- - -
-
-
-
-
-
-
-
-
-

Blade Pages

-
-
-
-
- - - - - - - - - @foreach (\Hyde\Framework\Models\Pages\BladePage::all() as $page) - - - - - @endforeach - -
TitleSource File
- - {{ Hyde::makeTitle($page->view) }} - - - {{ $page->getSourcePath() }} -
-
- -
-
-
-
-
-

Markdown Pages

-
-
-
-
- - - - - - - - - @foreach (\Hyde\Framework\Models\Pages\MarkdownPage::all() as $page) - - - - - @endforeach - -
TitleSource File
- - {{ Hyde::makeTitle($page->view) }} - - - {{ $page->getSourcePath() }} -
-
-
-
-
-
-
-
-
-
Welcome to Hyde! -
-

Project Details

-
-
-
-
- -
- - - - - - - - - - - - - - - - - - - - - - -
Project Name:{{ config('hyde.name', Hyde::makeTitle(basename(Hyde::path()))) }}
Project Path:{{ Hyde::path() }}
Framework Version:{{ Hyde::version() }}
PHP Version:{{ PHP_VERSION }} ({{ PHP_SAPI }})
-
-
-
-
-
-
diff --git a/projects/shelf/admin/resources/views/pages/docs.blade.php b/projects/shelf/admin/resources/views/pages/docs.blade.php deleted file mode 100644 index ddcb9f13802..00000000000 --- a/projects/shelf/admin/resources/views/pages/docs.blade.php +++ /dev/null @@ -1,59 +0,0 @@ -@php -use Hyde\Framework\Models\Pages\DocumentationPage; -@endphp - - - -
-

Your Documentation Pages

-

Here you'll find an overview of your Documentation pages.

-
-
-
- -
-
- -
-
-
-

Documentation Pages

-
-
- {{-- --}} -
-
-
-
- - - - - - - - - - @foreach (DocumentationPage::all() as $page) - - - - - - @endforeach - -
TitleSource File
- - {{ $page->title }} - - - {{ $page->getSourcePath() }} -
-
-
-
-
\ No newline at end of file diff --git a/projects/shelf/admin/resources/views/pages/media.blade.php b/projects/shelf/admin/resources/views/pages/media.blade.php deleted file mode 100644 index a275c87633e..00000000000 --- a/projects/shelf/admin/resources/views/pages/media.blade.php +++ /dev/null @@ -1,113 +0,0 @@ -@php -use Hyde\Framework\Services\DiscoveryService; -@endphp - - - -
-

Your Media Library

-

Here you'll find an overview of your site's media assets.

-
-
-
- -
-
- -
-
-
-

Media Files

-
-
- {{-- --}} -
-
-
-
- - - - - - - - - - - - @foreach (DiscoveryService::getMediaAssetFiles() as $file) - - - - - - - @endforeach - -
FilenameTypeSizeLast modified
- - {{ basename($file) }} - - - @php - $ext = pathinfo($file, PATHINFO_EXTENSION); - if (in_array($ext, ['jpg', 'jpeg', 'png', 'gif', 'ico', 'svg'])) { - echo 'Image'; - } elseif (in_array($ext, ['css', 'scss', 'sass'])) { - echo 'Stylesheet'; - } elseif (in_array($ext, ['js', 'ts', 'php'])) { - echo 'Script'; - } elseif (in_array($ext, ['mp3', 'wav', 'ogg'])) { - echo 'Audio'; - } elseif (in_array($ext, ['mp4', 'webm', 'ogg'])) { - echo 'Video'; - } else { - echo 'File'; - } - @endphp - - @php - $size = filesize($file); - if ($size < 1024) { echo $size . ' bytes' ; } elseif ($size < 1048576) { echo - round($size / 1024, 2) . ' KB' ; } else { echo round($size / 1048576, 2) . ' MB' ; } - @endphp - {{ \Carbon\Carbon::parse(filemtime($file))->diffForHumans() }} -
-
-
- - -
-
-
-

Image Gallery

-
-
- {{-- --}} -
-
-
-
-
- @foreach (DiscoveryService::getMediaAssetFiles() as $file) - @if(in_array(pathinfo($file, PATHINFO_EXTENSION), ['jpg', 'jpeg', 'png', 'gif', 'ico', 'svg'])) - - {{ basename($file) }} - - @endif - @endforeach -
-
-
-
-
\ No newline at end of file diff --git a/projects/shelf/admin/resources/views/pages/pages.blade.php b/projects/shelf/admin/resources/views/pages/pages.blade.php deleted file mode 100644 index b8aaa1392eb..00000000000 --- a/projects/shelf/admin/resources/views/pages/pages.blade.php +++ /dev/null @@ -1,103 +0,0 @@ -@php -use Hyde\Framework\Models\Pages\BladePage; -use Hyde\Framework\Models\Pages\MarkdownPage; -@endphp - - - -
-

Your pages

-

Here you'll find an overview of your Blade and Markdown pages.

-
-
-
- -
-
- -
-
-
-

Blade Pages

-
-
- {{-- --}} -
-
-
-
- - - - - - - - - - @foreach (BladePage::all() as $page) - - - - - @endforeach - -
TitleSource File
- - {{ Hyde::makeTitle($page->view) }} - - - {{ $page->getSourcePath() }} -
- -
-
- - -
-
-
-

Markdown Pages

-
-
- {{-- --}} -
-
-
-
- - - - - - - - - - @foreach (MarkdownPage::all() as $page) - - - - - @endforeach - -
TitleSource File
- - {{ $page->title }} - - - {{ $page->getSourcePath() }} -
- -
-
-
-
\ No newline at end of file diff --git a/projects/shelf/admin/resources/views/pages/posts.blade.php b/projects/shelf/admin/resources/views/pages/posts.blade.php deleted file mode 100644 index 47ab953d670..00000000000 --- a/projects/shelf/admin/resources/views/pages/posts.blade.php +++ /dev/null @@ -1,70 +0,0 @@ -@php -use Hyde\Framework\Models\Pages\MarkdownPage; -@endphp - - - -
-

Your Blog Posts

-

Here you'll find an overview of your Markdown blog posts.

-
-
-
- -
-
- -
-
-
-

Markdown Posts

-
-
- {{-- --}} -
-
-
-
- - - - - - - - - - - - - @foreach (MarkdownPost::all() as $post) - - - - - - - - @endforeach - -
TitleDateCategoryAuthorSource File
- - {{ $post->title }} - - - {{ $post->date->short }} - - {{ $post->category ?? 'Uncategorized' }} - - {{ $post->author->getName() }} - - {{ $post->getSourcePath() }} -
-
-
-
-
\ No newline at end of file diff --git a/projects/shelf/admin/src/Admin.php b/projects/shelf/admin/src/Admin.php deleted file mode 100644 index 0bfb8b22aed..00000000000 --- a/projects/shelf/admin/src/Admin.php +++ /dev/null @@ -1,8 +0,0 @@ -route = $this->request()?->get('route', 'dashboard') ?? 'dashboard'; - } - - public function getRouteKey(): string - { - return 'admin'; - } - - public function navigationMenuTitle(): string - { - return 'Admin Panel'; - } - - public function request(): ?Request - { - return isset($_SERVER['REQUEST_METHOD']) - ? Request::capture() - : null; - } - - public function view(): string - { - $view = 'hyde-admin::pages.'.$this->route; - - return view()->exists($view) ? $view : 'hyde-admin::pages.404'; - } -} diff --git a/projects/shelf/admin/src/AdminServiceProvider.php b/projects/shelf/admin/src/AdminServiceProvider.php deleted file mode 100644 index 5e71791df80..00000000000 --- a/projects/shelf/admin/src/AdminServiceProvider.php +++ /dev/null @@ -1,18 +0,0 @@ -loadViewsFrom(__DIR__.'/../resources/views', 'hyde-admin'); - - Hyde::routes()->addRoute( - (new AdminPage('hyde-admin::dashboard'))->getRoute() - ); - } -} diff --git a/projects/shelf/single-file-dashboard/dashboard-manual.txt b/projects/shelf/single-file-dashboard/dashboard-manual.txt deleted file mode 100644 index 3eb28cc16ed..00000000000 --- a/projects/shelf/single-file-dashboard/dashboard-manual.txt +++ /dev/null @@ -1,68 +0,0 @@ -HYDERC DASHBOARD MANUAL - -IMPORTANT NOTE - -As this is alpha stage software there may be bugs, -and usage is at your own risk. You should always keep -backups using Git version control or similar. - -A version allowing for community editing by creating -a public static HTML dashboard is planned, this would -then link to files on GitHub for collaboration. -Though, this idea may instead be handled in a separate -package included as a dashboard.blade.php file, -using the default layout. - - -SECURITY - -This is not a traditional CMS like WordPress and similar. -It's never supposed to be on production systems. -Instead, it's a local developer tool. -Think of it as an integrated development environment -specifically tailored for use with HydePHP projects. - -As the dashboard modifies files on the computer running it -and gives arbitrary access to the server by running shell -commands, opening files, and executing programs, it is -extremely important that the dashboard is not exposed -to the internet. You must only ever use this dashboard -as a local development tool. - -A basic check is made to block requests not made from -localhost as an extra precaution. You should still -never make the dashboard.php file publicly accessible. - -Also note that error reporting is enabled by default, -as the dashboard assumes that all who can access it -are authorized to use the system running it. - -The app is not safe against XSS/script injection either -as not all output is sanitized or escaped; and the -output that is escaped, is only made so to prevent -visual glitches, like displaying source HTML tags. - - -LICENSE - -MIT License - -Copyright (c) 2022 Caen De Silva - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. \ No newline at end of file diff --git a/projects/shelf/single-file-dashboard/dashboard.php b/projects/shelf/single-file-dashboard/dashboard.php deleted file mode 100644 index 0b608c757ac..00000000000 --- a/projects/shelf/single-file-dashboard/dashboard.php +++ /dev/null @@ -1,465 +0,0 @@ -HTTP/1.1 403 - Access Denied'; - echo '

You must be on localhost to access this page. Refusing to serve request.

'; - exit; -} - -// Load the same autoloader as the project -require_once sprintf('%s/vendor/autoload.php', BASE_PATH); - -use Hyde\Framework\Exceptions\FileNotFoundException; -use Hyde\Framework\Exceptions\UnsupportedPageTypeException; -use Hyde\Framework\Models\BladePage; -use Hyde\Framework\Models\DocumentationPage; -use Hyde\Framework\Models\MarkdownPage; -use Hyde\Framework\Models\MarkdownPost; -use Hyde\Framework\Services\DiscoveryService; -use Hyde\Hyde; - -const VERSION = 'dev-master'; - -// Run the dashboard app -try { - -// Create the Laravel app, and boot it up - try { - $app = require_once sprintf('%s/app/bootstrap.php', BASE_PATH); - } catch (\Throwable $th) { - try { - $app = require_once sprintf('%s/bootstrap/app.php', BASE_PATH); - } catch (\Throwable $th) { - throw $th; - } - } - $kernel = $app->make(Illuminate\Contracts\Console\Kernel::class); - $kernel->bootstrap(); - Hyde::setBasePath(BASE_PATH); - - // Create the Hyde interface - $hyde = new class() extends Hyde {}; - - // Create the project configuration class - $project = new class - { - public string $path; - public string $name; - - public function __construct() - { - $this->path = BASE_PATH; - $this->name = config('site.name', ucwords(str_replace('-', ' ', basename(BASE_PATH)))); - } - }; - - // Set the app name - $appname = e($project->name).' CMS'; - - // Get the request page - $page = $_GET['page'] ?? 'index'; - if ($page === 'dashboard' || $page === '') { - $page = 'index'; - } - - // Key => label - $routes = [ - 'index' => 'Dashboard', - '404' => '404 Page Not Found', - 'manual'=> 'Manual', - 'file-viewer' => 'File Viewer', - ]; - - if (! isset($routes[$page])) { - header('HTTP/1.1 404 Not Found'); - $page = '404'; - } - - // Set the page name - $pagename = $appname.' - '.$routes[$page]; - - // Helper functions - function icon(string $name) - { - $icons = [ - 'blade' => 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAACXBIWXMAAAPoAAAD6AG1e1JrAAAABlBMVEX/LR//LB96KezJAAAAAnRSTlN3CW8xmq0AAAA7SURBVAjXATAAz/8Ax/8AOfcAGcMARZwAbYgAbaYAbbYAbBEAbOMAY8cAZzcAcHcAPecAzZ8A8H8A+P+i4xJQuZ3gxwAAAABJRU5ErkJggg==', - 'markdown' => 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAKAQMAAACHcEzfAAAACXBIWXMAAAPoAAAD6AG1e1JrAAAABlBMVEVCQkJBQUFtOGGCAAAAAnRSTlPBCd2uk5MAAAAiSURBVAjXY2BgYKj/x+D3jMEljcEBiJwY/NIY/P6BBBkYAHYfCAEd79fPAAAAAElFTkSuQmCC', - 'documentation' => 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAACXBIWXMAAAPoAAAD6AG1e1JrAAAABlBMVEVXV1dUVFSxYS6RAAAAAnRSTlPnEHobuHcAAAArSURBVAjXY/j/nwGIHsgzPPBneJDO8KCc4QEzCD1+zPD4MJQBEXnADlQJABfcFU91j91PAAAAAElFTkSuQmCC', - ]; - - return $icons[$name] ?? ''; - } ?> - - - - - - - - - -<?= $pagename ?> - - - - - - - - - -
-
- -
-
-

-
- - -

- Project Information -

-
-
-
-
-

Installation Details

- - - - - - - - - - - - - - - -
Project NameProject PathFramework Version
name) ?>path) ?>version()) ?>
-
-
-

Content Overview

- - - - - - - - - - - - - - - - - -
Blade PagesMarkdown PagesDocumentation PagesBlog Posts
pages pages pages posts
-
-
- -

Your Pages

- - - - - - - - - - - - - - - - - - - - - - - - - - -
TypePage NameFile Path
- - Blade - - view ?> - - view.BladePage::$fileExtension ?> -
- - Markdown - - title ?> - - slug.MarkdownPage::$fileExtension ?> -
-
-
-
-
- -
-
-
- -
- type = $this->qualifyType($type); - $this->filename = urldecode($file); - $this->contentpath = $this->getContentpath(); - $this->filepath = Hyde::path($this->contentpath); - } - - protected function qualifyType(string $type) - { - $type = strtolower($type); - if ($type === 'bladepage') { - return BladePage::class; - } elseif ($type === 'markdownpage') { - return MarkdownPage::class; - } elseif ($type === 'documentationpage') { - return DocumentationPage::class; - } elseif ($type === 'markdownpost') { - return MarkdownPost::class; - } else { - throw new UnsupportedPageTypeException('Invalid file type'); - } - } - - protected function getContentpath() - { - $class = $this->type; - $filename = $this->filename; - $filepath = $class::$sourceDirectory.'/'.$filename.$class::$fileExtension; - if (! file_exists(Hyde::path($filepath))) { - throw new FileNotFoundException($filepath); - } - - return $filepath; - } - - public function getContents() - { - return file_get_contents($this->filepath); - } - }; - ?> - -
-

Showing file contentpath) ?>

- -
- -
-
-
-
getContents()) ?>
-
-
- -
-
- -
- - - - -
-
- -
- - - Go Back to dashboard? - -
-
-
- -
-
-
- - - - HydeCMS - - This page was generated in ms. - -
-
- -
-
-
- - - - - - - -Error'; - echo '

An error occurred while processing your request.

'; - echo '
'.$th->getMessage().'
'; - echo '

Extra information:

'; - echo '
'.$th->getTraceAsString().print_r($th, true).'
'; - exit($th->getCode()); - } From b2864c82b70f33bda266ae76b2221f8bddd00946 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 19:51:12 +0200 Subject: [PATCH 019/768] Revert "Delete projects/shelf directory" This reverts commit db4d79b74d419debeb474c35704e8db83e2e8567. --- projects/shelf/README.md | 3 + projects/shelf/admin/CONTRIBUTING.md | 55 +++ projects/shelf/admin/LICENSE.md | 21 + projects/shelf/admin/README.md | 52 ++ projects/shelf/admin/composer.json | 55 +++ projects/shelf/admin/config/config.php | 8 + .../resources/views/components/card.blade.php | 3 + .../views/components/header.blade.php | 8 + .../views/components/sidebar-link.blade.php | 16 + .../admin/resources/views/dashboard.blade.php | 48 ++ .../resources/views/layouts/footer.blade.php | 39 ++ .../views/layouts/navigation.blade.php | 17 + .../resources/views/layouts/sidebar.blade.php | 58 +++ .../admin/resources/views/pages/404.blade.php | 11 + .../resources/views/pages/dashboard.blade.php | 219 +++++++++ .../resources/views/pages/docs.blade.php | 59 +++ .../resources/views/pages/media.blade.php | 113 +++++ .../resources/views/pages/pages.blade.php | 103 ++++ .../resources/views/pages/posts.blade.php | 70 +++ projects/shelf/admin/src/Admin.php | 8 + projects/shelf/admin/src/AdminPage.php | 49 ++ .../shelf/admin/src/AdminServiceProvider.php | 18 + .../dashboard-manual.txt | 68 +++ .../shelf/single-file-dashboard/dashboard.php | 465 ++++++++++++++++++ 24 files changed, 1566 insertions(+) create mode 100644 projects/shelf/README.md create mode 100644 projects/shelf/admin/CONTRIBUTING.md create mode 100644 projects/shelf/admin/LICENSE.md create mode 100644 projects/shelf/admin/README.md create mode 100644 projects/shelf/admin/composer.json create mode 100644 projects/shelf/admin/config/config.php create mode 100644 projects/shelf/admin/resources/views/components/card.blade.php create mode 100644 projects/shelf/admin/resources/views/components/header.blade.php create mode 100644 projects/shelf/admin/resources/views/components/sidebar-link.blade.php create mode 100644 projects/shelf/admin/resources/views/dashboard.blade.php create mode 100644 projects/shelf/admin/resources/views/layouts/footer.blade.php create mode 100644 projects/shelf/admin/resources/views/layouts/navigation.blade.php create mode 100644 projects/shelf/admin/resources/views/layouts/sidebar.blade.php create mode 100644 projects/shelf/admin/resources/views/pages/404.blade.php create mode 100644 projects/shelf/admin/resources/views/pages/dashboard.blade.php create mode 100644 projects/shelf/admin/resources/views/pages/docs.blade.php create mode 100644 projects/shelf/admin/resources/views/pages/media.blade.php create mode 100644 projects/shelf/admin/resources/views/pages/pages.blade.php create mode 100644 projects/shelf/admin/resources/views/pages/posts.blade.php create mode 100644 projects/shelf/admin/src/Admin.php create mode 100644 projects/shelf/admin/src/AdminPage.php create mode 100644 projects/shelf/admin/src/AdminServiceProvider.php create mode 100644 projects/shelf/single-file-dashboard/dashboard-manual.txt create mode 100644 projects/shelf/single-file-dashboard/dashboard.php diff --git a/projects/shelf/README.md b/projects/shelf/README.md new file mode 100644 index 00000000000..ff9fa6ffdbc --- /dev/null +++ b/projects/shelf/README.md @@ -0,0 +1,3 @@ +# The Shelf + +A collection of work-in-progress projects that may or may not work. diff --git a/projects/shelf/admin/CONTRIBUTING.md b/projects/shelf/admin/CONTRIBUTING.md new file mode 100644 index 00000000000..b4ae1c4a7cf --- /dev/null +++ b/projects/shelf/admin/CONTRIBUTING.md @@ -0,0 +1,55 @@ +# Contributing + +Contributions are **welcome** and will be fully **credited**. + +Please read and understand the contribution guide before creating an issue or pull request. + +## Etiquette + +This project is open source, and as such, the maintainers give their free time to build and maintain the source code +held within. They make the code freely available in the hope that it will be of use to other developers. It would be +extremely unfair for them to suffer abuse or anger for their hard work. + +Please be considerate towards maintainers when raising issues or presenting pull requests. Let's show the +world that developers are civilized and selfless people. + +It's the duty of the maintainer to ensure that all submissions to the project are of sufficient +quality to benefit the project. Many developers have different skillsets, strengths, and weaknesses. Respect the maintainer's decision, and do not be upset or abusive if your submission is not used. + +## Viability + +When requesting or submitting new features, first consider whether it might be useful to others. Open +source projects are used by many developers, who may have entirely different needs to your own. Think about +whether or not your feature is likely to be used by other users of the project. + +## Procedure + +Before filing an issue: + +- Attempt to replicate the problem, to ensure that it wasn't a coincidental incident. +- Check to make sure your feature suggestion isn't already present within the project. +- Check the pull requests tab to ensure that the bug doesn't have a fix in progress. +- Check the pull requests tab to ensure that the feature isn't already in progress. + +Before submitting a pull request: + +- Check the codebase to ensure that your feature doesn't already exist. +- Check the pull requests to ensure that another person hasn't already submitted the feature or fix. + +## Requirements + +If the project maintainer has any additional requirements, you will find them listed here. + +- **[PSR-2 Coding Standard](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-2-coding-style-guide.md)** - The easiest way to apply the conventions is to install [PHP Code Sniffer](https://pear.php.net/package/PHP_CodeSniffer). + +- **Add tests!** - Your patch won't be accepted if it doesn't have tests. + +- **Document any change in behaviour** - Make sure the `README.md` and any other relevant documentation are kept up-to-date. + +- **Consider our release cycle** - We try to follow [SemVer v2.0.0](https://semver.org/). Randomly breaking public APIs is not an option. + +- **One pull request per feature** - If you want to do more than one thing, send multiple pull requests. + +- **Send coherent history** - Make sure each individual commit in your pull request is meaningful. If you had to make multiple intermediate commits while developing, please [squash them](https://www.git-scm.com/book/en/v2/Git-Tools-Rewriting-History#Changing-Multiple-Commit-Messages) before submitting. + +**Happy coding**! diff --git a/projects/shelf/admin/LICENSE.md b/projects/shelf/admin/LICENSE.md new file mode 100644 index 00000000000..f9d246d3801 --- /dev/null +++ b/projects/shelf/admin/LICENSE.md @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) Caen De Silva + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. \ No newline at end of file diff --git a/projects/shelf/admin/README.md b/projects/shelf/admin/README.md new file mode 100644 index 00000000000..b750da0a788 --- /dev/null +++ b/projects/shelf/admin/README.md @@ -0,0 +1,52 @@ +# Very short description of the package + +[![Latest Version on Packagist](https://img.shields.io/packagist/v/hyde/admin.svg?style=flat-square)](https://packagist.org/packages/hyde/admin) +[![Total Downloads](https://img.shields.io/packagist/dt/hyde/admin.svg?style=flat-square)](https://packagist.org/packages/hyde/admin) +![GitHub Actions](https://github.com/hyde/admin/actions/workflows/main.yml/badge.svg) + +This is where your description should go. Try and limit it to a paragraph or two, and maybe throw in a mention of what PSRs you support to avoid any confusion with users and contributors. + +## Installation + +You can install the package via composer: + +```bash +composer require hyde/admin +``` + +## Usage + +```php +// Usage description here +``` + +### Testing + +```bash +composer test +``` + +### Changelog + +Please see [CHANGELOG](CHANGELOG.md) for more information what has changed recently. + +## Contributing + +Please see [CONTRIBUTING](CONTRIBUTING.md) for details. + +### Security + +If you discover any security related issues, please email caen@desilva.se instead of using the issue tracker. + +## Credits + +- [Caen De Silva](https://github.com/hyde) +- [All Contributors](../../contributors) + +## License + +The MIT License (MIT). Please see [License File](LICENSE.md) for more information. + +## Laravel Package Boilerplate + +This package was generated using the [Laravel Package Boilerplate](https://laravelpackageboilerplate.com). diff --git a/projects/shelf/admin/composer.json b/projects/shelf/admin/composer.json new file mode 100644 index 00000000000..a82bdf4a7bc --- /dev/null +++ b/projects/shelf/admin/composer.json @@ -0,0 +1,55 @@ +{ + "name": "hyde/admin", + "description": "Experimental admin panel for local HydePHP development", + "keywords": [ + "hyde", + "admin" + ], + "homepage": "https://github.com/hyde/admin", + "license": "MIT", + "type": "library", + "authors": [ + { + "name": "Caen De Silva", + "email": "caen@desilva.se", + "role": "Developer" + } + ], + "require": { + "php": "^7.4|^8.0", + "illuminate/support": "^9.5", + "hyde/framework": "dev-master" + }, + "require-dev": { + "orchestra/testbench": "^6.0", + "phpunit/phpunit": "^9.0" + }, + "autoload": { + "psr-4": { + "Hyde\\Admin\\": "src" + } + }, + "autoload-dev": { + "psr-4": { + "Hyde\\Admin\\Tests\\": "tests" + } + }, + "scripts": { + "test": "vendor/bin/phpunit", + "test-coverage": "vendor/bin/phpunit --coverage-html coverage" + + }, + "config": { + "sort-packages": true + }, + "extra": { + "laravel": { + "providers": [ + "Hyde\\Admin\\AdminServiceProvider" + ], + "aliases": { + "Admin": "Hyde\\Admin\\AdminFacade" + } + } + } +} diff --git a/projects/shelf/admin/config/config.php b/projects/shelf/admin/config/config.php new file mode 100644 index 00000000000..aaec0920123 --- /dev/null +++ b/projects/shelf/admin/config/config.php @@ -0,0 +1,8 @@ +merge(['class' => 'relative flex flex-col min-w-0 break-words bg-white w-full mb-6 px-6 py-4 shadow-lg rounded']) }}> + {{ $slot }} + \ No newline at end of file diff --git a/projects/shelf/admin/resources/views/components/header.blade.php b/projects/shelf/admin/resources/views/components/header.blade.php new file mode 100644 index 00000000000..35fc4964955 --- /dev/null +++ b/projects/shelf/admin/resources/views/components/header.blade.php @@ -0,0 +1,8 @@ + +
+
+
+ {{ $slot }} +
+
+
\ No newline at end of file diff --git a/projects/shelf/admin/resources/views/components/sidebar-link.blade.php b/projects/shelf/admin/resources/views/components/sidebar-link.blade.php new file mode 100644 index 00000000000..cbd9bec9e98 --- /dev/null +++ b/projects/shelf/admin/resources/views/components/sidebar-link.blade.php @@ -0,0 +1,16 @@ +@props([ + 'route', + 'label', + 'icon' => 'file', + 'active' => $page->route == $route +]) + + $active ])> + $active, + 'text-slate-300' => ! $active + ])> +{{ $label }} diff --git a/projects/shelf/admin/resources/views/dashboard.blade.php b/projects/shelf/admin/resources/views/dashboard.blade.php new file mode 100644 index 00000000000..76fa4aff324 --- /dev/null +++ b/projects/shelf/admin/resources/views/dashboard.blade.php @@ -0,0 +1,48 @@ + + + + + + + + + + + Dashboard | {{ config('hyde.name') }} Admin + + + +
+ @include('hyde-admin::layouts.sidebar') + +
+ @include('hyde-admin::layouts.navigation') + +
+ @include($page->view()) +
+ + @include('hyde-admin::layouts.footer') +
+
+ + \ No newline at end of file diff --git a/projects/shelf/admin/resources/views/layouts/footer.blade.php b/projects/shelf/admin/resources/views/layouts/footer.blade.php new file mode 100644 index 00000000000..9bfde1b88d9 --- /dev/null +++ b/projects/shelf/admin/resources/views/layouts/footer.blade.php @@ -0,0 +1,39 @@ + \ No newline at end of file diff --git a/projects/shelf/admin/resources/views/layouts/navigation.blade.php b/projects/shelf/admin/resources/views/layouts/navigation.blade.php new file mode 100644 index 00000000000..9caed5e8351 --- /dev/null +++ b/projects/shelf/admin/resources/views/layouts/navigation.blade.php @@ -0,0 +1,17 @@ + \ No newline at end of file diff --git a/projects/shelf/admin/resources/views/layouts/sidebar.blade.php b/projects/shelf/admin/resources/views/layouts/sidebar.blade.php new file mode 100644 index 00000000000..ce79d113e84 --- /dev/null +++ b/projects/shelf/admin/resources/views/layouts/sidebar.blade.php @@ -0,0 +1,58 @@ + \ No newline at end of file diff --git a/projects/shelf/admin/resources/views/pages/404.blade.php b/projects/shelf/admin/resources/views/pages/404.blade.php new file mode 100644 index 00000000000..28e9dbea345 --- /dev/null +++ b/projects/shelf/admin/resources/views/pages/404.blade.php @@ -0,0 +1,11 @@ + + + + + \ No newline at end of file diff --git a/projects/shelf/admin/resources/views/pages/dashboard.blade.php b/projects/shelf/admin/resources/views/pages/dashboard.blade.php new file mode 100644 index 00000000000..10dc9bedd28 --- /dev/null +++ b/projects/shelf/admin/resources/views/pages/dashboard.blade.php @@ -0,0 +1,219 @@ +@php +use Hyde\Framework\Services\DiscoveryService; +@endphp + + + +
+
+
+
+
+
+
Blade Pages
+ {{ count(DiscoveryService::getBladePageFiles()) }} pages +
+
+
+ +
+
+
+ {{--

+ + 3.48% + Since last month +

--}} +
+
+
+
+
+
+
+
+
Markdown Pages
+ {{ count(DiscoveryService::getMarkdownPageFiles()) }} pages +
+
+
+ +
+
+
+ {{--

+ + 3.48% + Since last week +

--}} +
+
+
+
+
+
+
+
+
Documentation Pages
+ {{ count(DiscoveryService::getDocumentationPageFiles()) }} pages +
+
+
+ +
+
+
+ {{--

+ + 1.10% + Since yesterday +

--}} +
+
+
+
+
+
+
+
+
Markdown Posts
+ {{ count(DiscoveryService::getMarkdownPostFiles()) }} posts +
+
+
+ +
+
+
+ {{--

+ + 12% + Since last month +

--}} +
+
+
+
+
+ + +
+
+
+
+
+
+
+
+
+

Blade Pages

+
+
+
+
+ + + + + + + + + @foreach (\Hyde\Framework\Models\Pages\BladePage::all() as $page) + + + + + @endforeach + +
TitleSource File
+ + {{ Hyde::makeTitle($page->view) }} + + + {{ $page->getSourcePath() }} +
+
+ +
+
+
+
+
+

Markdown Pages

+
+
+
+
+ + + + + + + + + @foreach (\Hyde\Framework\Models\Pages\MarkdownPage::all() as $page) + + + + + @endforeach + +
TitleSource File
+ + {{ Hyde::makeTitle($page->view) }} + + + {{ $page->getSourcePath() }} +
+
+
+
+
+
+
+
+
+
Welcome to Hyde! +
+

Project Details

+
+
+
+
+ +
+ + + + + + + + + + + + + + + + + + + + + + +
Project Name:{{ config('hyde.name', Hyde::makeTitle(basename(Hyde::path()))) }}
Project Path:{{ Hyde::path() }}
Framework Version:{{ Hyde::version() }}
PHP Version:{{ PHP_VERSION }} ({{ PHP_SAPI }})
+
+
+
+
+
+
diff --git a/projects/shelf/admin/resources/views/pages/docs.blade.php b/projects/shelf/admin/resources/views/pages/docs.blade.php new file mode 100644 index 00000000000..ddcb9f13802 --- /dev/null +++ b/projects/shelf/admin/resources/views/pages/docs.blade.php @@ -0,0 +1,59 @@ +@php +use Hyde\Framework\Models\Pages\DocumentationPage; +@endphp + + + +
+

Your Documentation Pages

+

Here you'll find an overview of your Documentation pages.

+
+
+
+ +
+
+ +
+
+
+

Documentation Pages

+
+
+ {{-- --}} +
+
+
+
+ + + + + + + + + + @foreach (DocumentationPage::all() as $page) + + + + + + @endforeach + +
TitleSource File
+ + {{ $page->title }} + + + {{ $page->getSourcePath() }} +
+
+
+
+
\ No newline at end of file diff --git a/projects/shelf/admin/resources/views/pages/media.blade.php b/projects/shelf/admin/resources/views/pages/media.blade.php new file mode 100644 index 00000000000..a275c87633e --- /dev/null +++ b/projects/shelf/admin/resources/views/pages/media.blade.php @@ -0,0 +1,113 @@ +@php +use Hyde\Framework\Services\DiscoveryService; +@endphp + + + +
+

Your Media Library

+

Here you'll find an overview of your site's media assets.

+
+
+
+ +
+
+ +
+
+
+

Media Files

+
+
+ {{-- --}} +
+
+
+
+ + + + + + + + + + + + @foreach (DiscoveryService::getMediaAssetFiles() as $file) + + + + + + + @endforeach + +
FilenameTypeSizeLast modified
+ + {{ basename($file) }} + + + @php + $ext = pathinfo($file, PATHINFO_EXTENSION); + if (in_array($ext, ['jpg', 'jpeg', 'png', 'gif', 'ico', 'svg'])) { + echo 'Image'; + } elseif (in_array($ext, ['css', 'scss', 'sass'])) { + echo 'Stylesheet'; + } elseif (in_array($ext, ['js', 'ts', 'php'])) { + echo 'Script'; + } elseif (in_array($ext, ['mp3', 'wav', 'ogg'])) { + echo 'Audio'; + } elseif (in_array($ext, ['mp4', 'webm', 'ogg'])) { + echo 'Video'; + } else { + echo 'File'; + } + @endphp + + @php + $size = filesize($file); + if ($size < 1024) { echo $size . ' bytes' ; } elseif ($size < 1048576) { echo + round($size / 1024, 2) . ' KB' ; } else { echo round($size / 1048576, 2) . ' MB' ; } + @endphp + {{ \Carbon\Carbon::parse(filemtime($file))->diffForHumans() }} +
+
+
+ + +
+
+
+

Image Gallery

+
+
+ {{-- --}} +
+
+
+
+
+ @foreach (DiscoveryService::getMediaAssetFiles() as $file) + @if(in_array(pathinfo($file, PATHINFO_EXTENSION), ['jpg', 'jpeg', 'png', 'gif', 'ico', 'svg'])) + + {{ basename($file) }} + + @endif + @endforeach +
+
+
+
+
\ No newline at end of file diff --git a/projects/shelf/admin/resources/views/pages/pages.blade.php b/projects/shelf/admin/resources/views/pages/pages.blade.php new file mode 100644 index 00000000000..b8aaa1392eb --- /dev/null +++ b/projects/shelf/admin/resources/views/pages/pages.blade.php @@ -0,0 +1,103 @@ +@php +use Hyde\Framework\Models\Pages\BladePage; +use Hyde\Framework\Models\Pages\MarkdownPage; +@endphp + + + +
+

Your pages

+

Here you'll find an overview of your Blade and Markdown pages.

+
+
+
+ +
+
+ +
+
+
+

Blade Pages

+
+
+ {{-- --}} +
+
+
+
+ + + + + + + + + + @foreach (BladePage::all() as $page) + + + + + @endforeach + +
TitleSource File
+ + {{ Hyde::makeTitle($page->view) }} + + + {{ $page->getSourcePath() }} +
+ +
+
+ + +
+
+
+

Markdown Pages

+
+
+ {{-- --}} +
+
+
+
+ + + + + + + + + + @foreach (MarkdownPage::all() as $page) + + + + + @endforeach + +
TitleSource File
+ + {{ $page->title }} + + + {{ $page->getSourcePath() }} +
+ +
+
+
+
\ No newline at end of file diff --git a/projects/shelf/admin/resources/views/pages/posts.blade.php b/projects/shelf/admin/resources/views/pages/posts.blade.php new file mode 100644 index 00000000000..47ab953d670 --- /dev/null +++ b/projects/shelf/admin/resources/views/pages/posts.blade.php @@ -0,0 +1,70 @@ +@php +use Hyde\Framework\Models\Pages\MarkdownPage; +@endphp + + + +
+

Your Blog Posts

+

Here you'll find an overview of your Markdown blog posts.

+
+
+
+ +
+
+ +
+
+
+

Markdown Posts

+
+
+ {{-- --}} +
+
+
+
+ + + + + + + + + + + + + @foreach (MarkdownPost::all() as $post) + + + + + + + + @endforeach + +
TitleDateCategoryAuthorSource File
+ + {{ $post->title }} + + + {{ $post->date->short }} + + {{ $post->category ?? 'Uncategorized' }} + + {{ $post->author->getName() }} + + {{ $post->getSourcePath() }} +
+
+
+
+
\ No newline at end of file diff --git a/projects/shelf/admin/src/Admin.php b/projects/shelf/admin/src/Admin.php new file mode 100644 index 00000000000..0bfb8b22aed --- /dev/null +++ b/projects/shelf/admin/src/Admin.php @@ -0,0 +1,8 @@ +route = $this->request()?->get('route', 'dashboard') ?? 'dashboard'; + } + + public function getRouteKey(): string + { + return 'admin'; + } + + public function navigationMenuTitle(): string + { + return 'Admin Panel'; + } + + public function request(): ?Request + { + return isset($_SERVER['REQUEST_METHOD']) + ? Request::capture() + : null; + } + + public function view(): string + { + $view = 'hyde-admin::pages.'.$this->route; + + return view()->exists($view) ? $view : 'hyde-admin::pages.404'; + } +} diff --git a/projects/shelf/admin/src/AdminServiceProvider.php b/projects/shelf/admin/src/AdminServiceProvider.php new file mode 100644 index 00000000000..5e71791df80 --- /dev/null +++ b/projects/shelf/admin/src/AdminServiceProvider.php @@ -0,0 +1,18 @@ +loadViewsFrom(__DIR__.'/../resources/views', 'hyde-admin'); + + Hyde::routes()->addRoute( + (new AdminPage('hyde-admin::dashboard'))->getRoute() + ); + } +} diff --git a/projects/shelf/single-file-dashboard/dashboard-manual.txt b/projects/shelf/single-file-dashboard/dashboard-manual.txt new file mode 100644 index 00000000000..3eb28cc16ed --- /dev/null +++ b/projects/shelf/single-file-dashboard/dashboard-manual.txt @@ -0,0 +1,68 @@ +HYDERC DASHBOARD MANUAL + +IMPORTANT NOTE + +As this is alpha stage software there may be bugs, +and usage is at your own risk. You should always keep +backups using Git version control or similar. + +A version allowing for community editing by creating +a public static HTML dashboard is planned, this would +then link to files on GitHub for collaboration. +Though, this idea may instead be handled in a separate +package included as a dashboard.blade.php file, +using the default layout. + + +SECURITY + +This is not a traditional CMS like WordPress and similar. +It's never supposed to be on production systems. +Instead, it's a local developer tool. +Think of it as an integrated development environment +specifically tailored for use with HydePHP projects. + +As the dashboard modifies files on the computer running it +and gives arbitrary access to the server by running shell +commands, opening files, and executing programs, it is +extremely important that the dashboard is not exposed +to the internet. You must only ever use this dashboard +as a local development tool. + +A basic check is made to block requests not made from +localhost as an extra precaution. You should still +never make the dashboard.php file publicly accessible. + +Also note that error reporting is enabled by default, +as the dashboard assumes that all who can access it +are authorized to use the system running it. + +The app is not safe against XSS/script injection either +as not all output is sanitized or escaped; and the +output that is escaped, is only made so to prevent +visual glitches, like displaying source HTML tags. + + +LICENSE + +MIT License + +Copyright (c) 2022 Caen De Silva + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. \ No newline at end of file diff --git a/projects/shelf/single-file-dashboard/dashboard.php b/projects/shelf/single-file-dashboard/dashboard.php new file mode 100644 index 00000000000..0b608c757ac --- /dev/null +++ b/projects/shelf/single-file-dashboard/dashboard.php @@ -0,0 +1,465 @@ +HTTP/1.1 403 - Access Denied'; + echo '

You must be on localhost to access this page. Refusing to serve request.

'; + exit; +} + +// Load the same autoloader as the project +require_once sprintf('%s/vendor/autoload.php', BASE_PATH); + +use Hyde\Framework\Exceptions\FileNotFoundException; +use Hyde\Framework\Exceptions\UnsupportedPageTypeException; +use Hyde\Framework\Models\BladePage; +use Hyde\Framework\Models\DocumentationPage; +use Hyde\Framework\Models\MarkdownPage; +use Hyde\Framework\Models\MarkdownPost; +use Hyde\Framework\Services\DiscoveryService; +use Hyde\Hyde; + +const VERSION = 'dev-master'; + +// Run the dashboard app +try { + +// Create the Laravel app, and boot it up + try { + $app = require_once sprintf('%s/app/bootstrap.php', BASE_PATH); + } catch (\Throwable $th) { + try { + $app = require_once sprintf('%s/bootstrap/app.php', BASE_PATH); + } catch (\Throwable $th) { + throw $th; + } + } + $kernel = $app->make(Illuminate\Contracts\Console\Kernel::class); + $kernel->bootstrap(); + Hyde::setBasePath(BASE_PATH); + + // Create the Hyde interface + $hyde = new class() extends Hyde {}; + + // Create the project configuration class + $project = new class + { + public string $path; + public string $name; + + public function __construct() + { + $this->path = BASE_PATH; + $this->name = config('site.name', ucwords(str_replace('-', ' ', basename(BASE_PATH)))); + } + }; + + // Set the app name + $appname = e($project->name).' CMS'; + + // Get the request page + $page = $_GET['page'] ?? 'index'; + if ($page === 'dashboard' || $page === '') { + $page = 'index'; + } + + // Key => label + $routes = [ + 'index' => 'Dashboard', + '404' => '404 Page Not Found', + 'manual'=> 'Manual', + 'file-viewer' => 'File Viewer', + ]; + + if (! isset($routes[$page])) { + header('HTTP/1.1 404 Not Found'); + $page = '404'; + } + + // Set the page name + $pagename = $appname.' - '.$routes[$page]; + + // Helper functions + function icon(string $name) + { + $icons = [ + 'blade' => 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAACXBIWXMAAAPoAAAD6AG1e1JrAAAABlBMVEX/LR//LB96KezJAAAAAnRSTlN3CW8xmq0AAAA7SURBVAjXATAAz/8Ax/8AOfcAGcMARZwAbYgAbaYAbbYAbBEAbOMAY8cAZzcAcHcAPecAzZ8A8H8A+P+i4xJQuZ3gxwAAAABJRU5ErkJggg==', + 'markdown' => 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAKAQMAAACHcEzfAAAACXBIWXMAAAPoAAAD6AG1e1JrAAAABlBMVEVCQkJBQUFtOGGCAAAAAnRSTlPBCd2uk5MAAAAiSURBVAjXY2BgYKj/x+D3jMEljcEBiJwY/NIY/P6BBBkYAHYfCAEd79fPAAAAAElFTkSuQmCC', + 'documentation' => 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAACXBIWXMAAAPoAAAD6AG1e1JrAAAABlBMVEVXV1dUVFSxYS6RAAAAAnRSTlPnEHobuHcAAAArSURBVAjXY/j/nwGIHsgzPPBneJDO8KCc4QEzCD1+zPD4MJQBEXnADlQJABfcFU91j91PAAAAAElFTkSuQmCC', + ]; + + return $icons[$name] ?? ''; + } ?> + + + + + + + + + +<?= $pagename ?> + + + + + + + + + +
+
+ +
+
+

+
+ + +

+ Project Information +

+
+
+
+
+

Installation Details

+ + + + + + + + + + + + + + + +
Project NameProject PathFramework Version
name) ?>path) ?>version()) ?>
+
+
+

Content Overview

+ + + + + + + + + + + + + + + + + +
Blade PagesMarkdown PagesDocumentation PagesBlog Posts
pages pages pages posts
+
+
+ +

Your Pages

+ + + + + + + + + + + + + + + + + + + + + + + + + + +
TypePage NameFile Path
+ + Blade + + view ?> + + view.BladePage::$fileExtension ?> +
+ + Markdown + + title ?> + + slug.MarkdownPage::$fileExtension ?> +
+
+
+
+
+ +
+
+
+ +
+ type = $this->qualifyType($type); + $this->filename = urldecode($file); + $this->contentpath = $this->getContentpath(); + $this->filepath = Hyde::path($this->contentpath); + } + + protected function qualifyType(string $type) + { + $type = strtolower($type); + if ($type === 'bladepage') { + return BladePage::class; + } elseif ($type === 'markdownpage') { + return MarkdownPage::class; + } elseif ($type === 'documentationpage') { + return DocumentationPage::class; + } elseif ($type === 'markdownpost') { + return MarkdownPost::class; + } else { + throw new UnsupportedPageTypeException('Invalid file type'); + } + } + + protected function getContentpath() + { + $class = $this->type; + $filename = $this->filename; + $filepath = $class::$sourceDirectory.'/'.$filename.$class::$fileExtension; + if (! file_exists(Hyde::path($filepath))) { + throw new FileNotFoundException($filepath); + } + + return $filepath; + } + + public function getContents() + { + return file_get_contents($this->filepath); + } + }; + ?> + +
+

Showing file contentpath) ?>

+ +
+ +
+
+
+
getContents()) ?>
+
+
+ +
+
+ +
+ + + + +
+
+ +
+ + + Go Back to dashboard? + +
+
+
+ +
+
+
+ + + + HydeCMS + + This page was generated in ms. + +
+
+ +
+
+
+ + + + + + + +Error'; + echo '

An error occurred while processing your request.

'; + echo '
'.$th->getMessage().'
'; + echo '

Extra information:

'; + echo '
'.$th->getTraceAsString().print_r($th, true).'
'; + exit($th->getCode()); + } From b4e2cc9c5bc7b8c846a557c5ecdc9278ebbbcff7 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 19:53:19 +0200 Subject: [PATCH 020/768] Merge release manager readme into release script --- projects/release-manager/release.php | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/projects/release-manager/release.php b/projects/release-manager/release.php index f53e433e774..b2cdff77430 100644 --- a/projects/release-manager/release.php +++ b/projects/release-manager/release.php @@ -1,5 +1,13 @@ Date: Wed, 26 Oct 2022 19:53:34 +0200 Subject: [PATCH 021/768] Delete README.md --- projects/release-manager/README.md | 7 ------- 1 file changed, 7 deletions(-) delete mode 100644 projects/release-manager/README.md diff --git a/projects/release-manager/README.md b/projects/release-manager/README.md deleted file mode 100644 index daebf0a05fe..00000000000 --- a/projects/release-manager/README.md +++ /dev/null @@ -1,7 +0,0 @@ -# Hyde Releases - -While in the v0.x range, we consider both major and minor release versions to be the same. This means that when a new feature is added, it should be added as a minor version even if it is breaking. Patch versions should always be compatible. Once we reach v1.0 we will follow semantic versioning strictly. - -The versioning between the Framework and Hyde packages are linked together Meaning that if Hyde get's a minor release, so must Framework, and vice versa. To make this easier, we also publish minor releases in the monorepo. Patch releases are not published in the monorepo, and are instead handled by the individual packages. - -To make this all easier, this directory contains tools to automate part of the process. The release manager only works for minor releases as patch releases are handled by the individual packages, and we are still in the v0.x range. From e629dfc5c480ba8b53bce3d7a7a58a8d3721dbe6 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 19:55:25 +0200 Subject: [PATCH 022/768] Move release manager script to new bin directory --- {projects/release-manager => bin}/release.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) rename {projects/release-manager => bin}/release.php (91%) diff --git a/projects/release-manager/release.php b/bin/release.php similarity index 91% rename from projects/release-manager/release.php rename to bin/release.php index b2cdff77430..2b67fa18025 100644 --- a/projects/release-manager/release.php +++ b/bin/release.php @@ -28,13 +28,13 @@ $shortVersion = substr($shortVersion, 0, strpos($shortVersion, '.')); echo "Short version: $shortVersion\n"; -$composerJson = json_decode(file_get_contents(__DIR__.'./../../packages/hyde/composer.json'), true); +$composerJson = json_decode(file_get_contents(__DIR__ . './../../packages/hyde/composer.json'), true); $composerJson['require']['hyde/framework'] = "^0.$shortVersion"; -file_put_contents(__DIR__.'./../../packages/hyde/composer.json', json_encode($composerJson, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES)); +file_put_contents(__DIR__ . './../../packages/hyde/composer.json', json_encode($composerJson, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES)); echo "Transforming upcoming release notes... \n"; -$notes = file_get_contents(__DIR__.'/../../RELEASE_NOTES.md'); +$notes = file_get_contents(__DIR__ . '/../../RELEASE_NOTES.md'); $notes = str_replace("\r", '', $notes); @@ -68,7 +68,7 @@ echo "Done. \n"; echo 'Resetting upcoming release notes stub'; -file_put_contents(__DIR__.'/../../RELEASE_NOTES.md', '## [Unreleased] - YYYY-MM-DD +file_put_contents(__DIR__ . '/../../RELEASE_NOTES.md', '## [Unreleased] - YYYY-MM-DD ### About @@ -100,12 +100,12 @@ echo 'Updating changelog with the upcoming release notes... '; -$changelog = file_get_contents(__DIR__.'/../../CHANGELOG.md'); +$changelog = file_get_contents(__DIR__ . '/../../CHANGELOG.md'); $needle = ''; $changelog = substr_replace($changelog, $needle."\n\n".$notes, strpos($changelog, $needle), strlen($needle)); -file_put_contents(__DIR__.'/../../CHANGELOG.md', $changelog); +file_put_contents(__DIR__ . '/../../CHANGELOG.md', $changelog); echo "Done. \n"; From 81910125ab0783386e0e793051db549bc01bda54 Mon Sep 17 00:00:00 2001 From: StyleCI Bot Date: Wed, 26 Oct 2022 17:55:45 +0000 Subject: [PATCH 023/768] Apply fixes from StyleCI --- bin/release.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/bin/release.php b/bin/release.php index 2b67fa18025..b2cdff77430 100644 --- a/bin/release.php +++ b/bin/release.php @@ -28,13 +28,13 @@ $shortVersion = substr($shortVersion, 0, strpos($shortVersion, '.')); echo "Short version: $shortVersion\n"; -$composerJson = json_decode(file_get_contents(__DIR__ . './../../packages/hyde/composer.json'), true); +$composerJson = json_decode(file_get_contents(__DIR__.'./../../packages/hyde/composer.json'), true); $composerJson['require']['hyde/framework'] = "^0.$shortVersion"; -file_put_contents(__DIR__ . './../../packages/hyde/composer.json', json_encode($composerJson, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES)); +file_put_contents(__DIR__.'./../../packages/hyde/composer.json', json_encode($composerJson, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES)); echo "Transforming upcoming release notes... \n"; -$notes = file_get_contents(__DIR__ . '/../../RELEASE_NOTES.md'); +$notes = file_get_contents(__DIR__.'/../../RELEASE_NOTES.md'); $notes = str_replace("\r", '', $notes); @@ -68,7 +68,7 @@ echo "Done. \n"; echo 'Resetting upcoming release notes stub'; -file_put_contents(__DIR__ . '/../../RELEASE_NOTES.md', '## [Unreleased] - YYYY-MM-DD +file_put_contents(__DIR__.'/../../RELEASE_NOTES.md', '## [Unreleased] - YYYY-MM-DD ### About @@ -100,12 +100,12 @@ echo 'Updating changelog with the upcoming release notes... '; -$changelog = file_get_contents(__DIR__ . '/../../CHANGELOG.md'); +$changelog = file_get_contents(__DIR__.'/../../CHANGELOG.md'); $needle = ''; $changelog = substr_replace($changelog, $needle."\n\n".$notes, strpos($changelog, $needle), strlen($needle)); -file_put_contents(__DIR__ . '/../../CHANGELOG.md', $changelog); +file_put_contents(__DIR__.'/../../CHANGELOG.md', $changelog); echo "Done. \n"; From 15daa54499f04fc92c5e432f9c7166de8e7ae5f7 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 19:59:15 +0200 Subject: [PATCH 024/768] Delete projects/shelf directory --- projects/shelf/README.md | 3 - projects/shelf/admin/CONTRIBUTING.md | 55 --- projects/shelf/admin/LICENSE.md | 21 - projects/shelf/admin/README.md | 52 -- projects/shelf/admin/composer.json | 55 --- projects/shelf/admin/config/config.php | 8 - .../resources/views/components/card.blade.php | 3 - .../views/components/header.blade.php | 8 - .../views/components/sidebar-link.blade.php | 16 - .../admin/resources/views/dashboard.blade.php | 48 -- .../resources/views/layouts/footer.blade.php | 39 -- .../views/layouts/navigation.blade.php | 17 - .../resources/views/layouts/sidebar.blade.php | 58 --- .../admin/resources/views/pages/404.blade.php | 11 - .../resources/views/pages/dashboard.blade.php | 219 --------- .../resources/views/pages/docs.blade.php | 59 --- .../resources/views/pages/media.blade.php | 113 ----- .../resources/views/pages/pages.blade.php | 103 ---- .../resources/views/pages/posts.blade.php | 70 --- projects/shelf/admin/src/Admin.php | 8 - projects/shelf/admin/src/AdminPage.php | 49 -- .../shelf/admin/src/AdminServiceProvider.php | 18 - .../dashboard-manual.txt | 68 --- .../shelf/single-file-dashboard/dashboard.php | 465 ------------------ 24 files changed, 1566 deletions(-) delete mode 100644 projects/shelf/README.md delete mode 100644 projects/shelf/admin/CONTRIBUTING.md delete mode 100644 projects/shelf/admin/LICENSE.md delete mode 100644 projects/shelf/admin/README.md delete mode 100644 projects/shelf/admin/composer.json delete mode 100644 projects/shelf/admin/config/config.php delete mode 100644 projects/shelf/admin/resources/views/components/card.blade.php delete mode 100644 projects/shelf/admin/resources/views/components/header.blade.php delete mode 100644 projects/shelf/admin/resources/views/components/sidebar-link.blade.php delete mode 100644 projects/shelf/admin/resources/views/dashboard.blade.php delete mode 100644 projects/shelf/admin/resources/views/layouts/footer.blade.php delete mode 100644 projects/shelf/admin/resources/views/layouts/navigation.blade.php delete mode 100644 projects/shelf/admin/resources/views/layouts/sidebar.blade.php delete mode 100644 projects/shelf/admin/resources/views/pages/404.blade.php delete mode 100644 projects/shelf/admin/resources/views/pages/dashboard.blade.php delete mode 100644 projects/shelf/admin/resources/views/pages/docs.blade.php delete mode 100644 projects/shelf/admin/resources/views/pages/media.blade.php delete mode 100644 projects/shelf/admin/resources/views/pages/pages.blade.php delete mode 100644 projects/shelf/admin/resources/views/pages/posts.blade.php delete mode 100644 projects/shelf/admin/src/Admin.php delete mode 100644 projects/shelf/admin/src/AdminPage.php delete mode 100644 projects/shelf/admin/src/AdminServiceProvider.php delete mode 100644 projects/shelf/single-file-dashboard/dashboard-manual.txt delete mode 100644 projects/shelf/single-file-dashboard/dashboard.php diff --git a/projects/shelf/README.md b/projects/shelf/README.md deleted file mode 100644 index ff9fa6ffdbc..00000000000 --- a/projects/shelf/README.md +++ /dev/null @@ -1,3 +0,0 @@ -# The Shelf - -A collection of work-in-progress projects that may or may not work. diff --git a/projects/shelf/admin/CONTRIBUTING.md b/projects/shelf/admin/CONTRIBUTING.md deleted file mode 100644 index b4ae1c4a7cf..00000000000 --- a/projects/shelf/admin/CONTRIBUTING.md +++ /dev/null @@ -1,55 +0,0 @@ -# Contributing - -Contributions are **welcome** and will be fully **credited**. - -Please read and understand the contribution guide before creating an issue or pull request. - -## Etiquette - -This project is open source, and as such, the maintainers give their free time to build and maintain the source code -held within. They make the code freely available in the hope that it will be of use to other developers. It would be -extremely unfair for them to suffer abuse or anger for their hard work. - -Please be considerate towards maintainers when raising issues or presenting pull requests. Let's show the -world that developers are civilized and selfless people. - -It's the duty of the maintainer to ensure that all submissions to the project are of sufficient -quality to benefit the project. Many developers have different skillsets, strengths, and weaknesses. Respect the maintainer's decision, and do not be upset or abusive if your submission is not used. - -## Viability - -When requesting or submitting new features, first consider whether it might be useful to others. Open -source projects are used by many developers, who may have entirely different needs to your own. Think about -whether or not your feature is likely to be used by other users of the project. - -## Procedure - -Before filing an issue: - -- Attempt to replicate the problem, to ensure that it wasn't a coincidental incident. -- Check to make sure your feature suggestion isn't already present within the project. -- Check the pull requests tab to ensure that the bug doesn't have a fix in progress. -- Check the pull requests tab to ensure that the feature isn't already in progress. - -Before submitting a pull request: - -- Check the codebase to ensure that your feature doesn't already exist. -- Check the pull requests to ensure that another person hasn't already submitted the feature or fix. - -## Requirements - -If the project maintainer has any additional requirements, you will find them listed here. - -- **[PSR-2 Coding Standard](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-2-coding-style-guide.md)** - The easiest way to apply the conventions is to install [PHP Code Sniffer](https://pear.php.net/package/PHP_CodeSniffer). - -- **Add tests!** - Your patch won't be accepted if it doesn't have tests. - -- **Document any change in behaviour** - Make sure the `README.md` and any other relevant documentation are kept up-to-date. - -- **Consider our release cycle** - We try to follow [SemVer v2.0.0](https://semver.org/). Randomly breaking public APIs is not an option. - -- **One pull request per feature** - If you want to do more than one thing, send multiple pull requests. - -- **Send coherent history** - Make sure each individual commit in your pull request is meaningful. If you had to make multiple intermediate commits while developing, please [squash them](https://www.git-scm.com/book/en/v2/Git-Tools-Rewriting-History#Changing-Multiple-Commit-Messages) before submitting. - -**Happy coding**! diff --git a/projects/shelf/admin/LICENSE.md b/projects/shelf/admin/LICENSE.md deleted file mode 100644 index f9d246d3801..00000000000 --- a/projects/shelf/admin/LICENSE.md +++ /dev/null @@ -1,21 +0,0 @@ -MIT License - -Copyright (c) Caen De Silva - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. \ No newline at end of file diff --git a/projects/shelf/admin/README.md b/projects/shelf/admin/README.md deleted file mode 100644 index b750da0a788..00000000000 --- a/projects/shelf/admin/README.md +++ /dev/null @@ -1,52 +0,0 @@ -# Very short description of the package - -[![Latest Version on Packagist](https://img.shields.io/packagist/v/hyde/admin.svg?style=flat-square)](https://packagist.org/packages/hyde/admin) -[![Total Downloads](https://img.shields.io/packagist/dt/hyde/admin.svg?style=flat-square)](https://packagist.org/packages/hyde/admin) -![GitHub Actions](https://github.com/hyde/admin/actions/workflows/main.yml/badge.svg) - -This is where your description should go. Try and limit it to a paragraph or two, and maybe throw in a mention of what PSRs you support to avoid any confusion with users and contributors. - -## Installation - -You can install the package via composer: - -```bash -composer require hyde/admin -``` - -## Usage - -```php -// Usage description here -``` - -### Testing - -```bash -composer test -``` - -### Changelog - -Please see [CHANGELOG](CHANGELOG.md) for more information what has changed recently. - -## Contributing - -Please see [CONTRIBUTING](CONTRIBUTING.md) for details. - -### Security - -If you discover any security related issues, please email caen@desilva.se instead of using the issue tracker. - -## Credits - -- [Caen De Silva](https://github.com/hyde) -- [All Contributors](../../contributors) - -## License - -The MIT License (MIT). Please see [License File](LICENSE.md) for more information. - -## Laravel Package Boilerplate - -This package was generated using the [Laravel Package Boilerplate](https://laravelpackageboilerplate.com). diff --git a/projects/shelf/admin/composer.json b/projects/shelf/admin/composer.json deleted file mode 100644 index a82bdf4a7bc..00000000000 --- a/projects/shelf/admin/composer.json +++ /dev/null @@ -1,55 +0,0 @@ -{ - "name": "hyde/admin", - "description": "Experimental admin panel for local HydePHP development", - "keywords": [ - "hyde", - "admin" - ], - "homepage": "https://github.com/hyde/admin", - "license": "MIT", - "type": "library", - "authors": [ - { - "name": "Caen De Silva", - "email": "caen@desilva.se", - "role": "Developer" - } - ], - "require": { - "php": "^7.4|^8.0", - "illuminate/support": "^9.5", - "hyde/framework": "dev-master" - }, - "require-dev": { - "orchestra/testbench": "^6.0", - "phpunit/phpunit": "^9.0" - }, - "autoload": { - "psr-4": { - "Hyde\\Admin\\": "src" - } - }, - "autoload-dev": { - "psr-4": { - "Hyde\\Admin\\Tests\\": "tests" - } - }, - "scripts": { - "test": "vendor/bin/phpunit", - "test-coverage": "vendor/bin/phpunit --coverage-html coverage" - - }, - "config": { - "sort-packages": true - }, - "extra": { - "laravel": { - "providers": [ - "Hyde\\Admin\\AdminServiceProvider" - ], - "aliases": { - "Admin": "Hyde\\Admin\\AdminFacade" - } - } - } -} diff --git a/projects/shelf/admin/config/config.php b/projects/shelf/admin/config/config.php deleted file mode 100644 index aaec0920123..00000000000 --- a/projects/shelf/admin/config/config.php +++ /dev/null @@ -1,8 +0,0 @@ -merge(['class' => 'relative flex flex-col min-w-0 break-words bg-white w-full mb-6 px-6 py-4 shadow-lg rounded']) }}> - {{ $slot }} - \ No newline at end of file diff --git a/projects/shelf/admin/resources/views/components/header.blade.php b/projects/shelf/admin/resources/views/components/header.blade.php deleted file mode 100644 index 35fc4964955..00000000000 --- a/projects/shelf/admin/resources/views/components/header.blade.php +++ /dev/null @@ -1,8 +0,0 @@ - -
-
-
- {{ $slot }} -
-
-
\ No newline at end of file diff --git a/projects/shelf/admin/resources/views/components/sidebar-link.blade.php b/projects/shelf/admin/resources/views/components/sidebar-link.blade.php deleted file mode 100644 index cbd9bec9e98..00000000000 --- a/projects/shelf/admin/resources/views/components/sidebar-link.blade.php +++ /dev/null @@ -1,16 +0,0 @@ -@props([ - 'route', - 'label', - 'icon' => 'file', - 'active' => $page->route == $route -]) - - $active ])> - $active, - 'text-slate-300' => ! $active - ])> -{{ $label }} diff --git a/projects/shelf/admin/resources/views/dashboard.blade.php b/projects/shelf/admin/resources/views/dashboard.blade.php deleted file mode 100644 index 76fa4aff324..00000000000 --- a/projects/shelf/admin/resources/views/dashboard.blade.php +++ /dev/null @@ -1,48 +0,0 @@ - - - - - - - - - - - Dashboard | {{ config('hyde.name') }} Admin - - - -
- @include('hyde-admin::layouts.sidebar') - -
- @include('hyde-admin::layouts.navigation') - -
- @include($page->view()) -
- - @include('hyde-admin::layouts.footer') -
-
- - \ No newline at end of file diff --git a/projects/shelf/admin/resources/views/layouts/footer.blade.php b/projects/shelf/admin/resources/views/layouts/footer.blade.php deleted file mode 100644 index 9bfde1b88d9..00000000000 --- a/projects/shelf/admin/resources/views/layouts/footer.blade.php +++ /dev/null @@ -1,39 +0,0 @@ - \ No newline at end of file diff --git a/projects/shelf/admin/resources/views/layouts/navigation.blade.php b/projects/shelf/admin/resources/views/layouts/navigation.blade.php deleted file mode 100644 index 9caed5e8351..00000000000 --- a/projects/shelf/admin/resources/views/layouts/navigation.blade.php +++ /dev/null @@ -1,17 +0,0 @@ - \ No newline at end of file diff --git a/projects/shelf/admin/resources/views/layouts/sidebar.blade.php b/projects/shelf/admin/resources/views/layouts/sidebar.blade.php deleted file mode 100644 index ce79d113e84..00000000000 --- a/projects/shelf/admin/resources/views/layouts/sidebar.blade.php +++ /dev/null @@ -1,58 +0,0 @@ - \ No newline at end of file diff --git a/projects/shelf/admin/resources/views/pages/404.blade.php b/projects/shelf/admin/resources/views/pages/404.blade.php deleted file mode 100644 index 28e9dbea345..00000000000 --- a/projects/shelf/admin/resources/views/pages/404.blade.php +++ /dev/null @@ -1,11 +0,0 @@ - - - - - \ No newline at end of file diff --git a/projects/shelf/admin/resources/views/pages/dashboard.blade.php b/projects/shelf/admin/resources/views/pages/dashboard.blade.php deleted file mode 100644 index 10dc9bedd28..00000000000 --- a/projects/shelf/admin/resources/views/pages/dashboard.blade.php +++ /dev/null @@ -1,219 +0,0 @@ -@php -use Hyde\Framework\Services\DiscoveryService; -@endphp - - - -
-
-
-
-
-
-
Blade Pages
- {{ count(DiscoveryService::getBladePageFiles()) }} pages -
-
-
- -
-
-
- {{--

- - 3.48% - Since last month -

--}} -
-
-
-
-
-
-
-
-
Markdown Pages
- {{ count(DiscoveryService::getMarkdownPageFiles()) }} pages -
-
-
- -
-
-
- {{--

- - 3.48% - Since last week -

--}} -
-
-
-
-
-
-
-
-
Documentation Pages
- {{ count(DiscoveryService::getDocumentationPageFiles()) }} pages -
-
-
- -
-
-
- {{--

- - 1.10% - Since yesterday -

--}} -
-
-
-
-
-
-
-
-
Markdown Posts
- {{ count(DiscoveryService::getMarkdownPostFiles()) }} posts -
-
-
- -
-
-
- {{--

- - 12% - Since last month -

--}} -
-
-
-
-
- - -
-
-
-
-
-
-
-
-
-

Blade Pages

-
-
-
-
- - - - - - - - - @foreach (\Hyde\Framework\Models\Pages\BladePage::all() as $page) - - - - - @endforeach - -
TitleSource File
- - {{ Hyde::makeTitle($page->view) }} - - - {{ $page->getSourcePath() }} -
-
- -
-
-
-
-
-

Markdown Pages

-
-
-
-
- - - - - - - - - @foreach (\Hyde\Framework\Models\Pages\MarkdownPage::all() as $page) - - - - - @endforeach - -
TitleSource File
- - {{ Hyde::makeTitle($page->view) }} - - - {{ $page->getSourcePath() }} -
-
-
-
-
-
-
-
-
-
Welcome to Hyde! -
-

Project Details

-
-
-
-
- -
- - - - - - - - - - - - - - - - - - - - - - -
Project Name:{{ config('hyde.name', Hyde::makeTitle(basename(Hyde::path()))) }}
Project Path:{{ Hyde::path() }}
Framework Version:{{ Hyde::version() }}
PHP Version:{{ PHP_VERSION }} ({{ PHP_SAPI }})
-
-
-
-
-
-
diff --git a/projects/shelf/admin/resources/views/pages/docs.blade.php b/projects/shelf/admin/resources/views/pages/docs.blade.php deleted file mode 100644 index ddcb9f13802..00000000000 --- a/projects/shelf/admin/resources/views/pages/docs.blade.php +++ /dev/null @@ -1,59 +0,0 @@ -@php -use Hyde\Framework\Models\Pages\DocumentationPage; -@endphp - - - -
-

Your Documentation Pages

-

Here you'll find an overview of your Documentation pages.

-
-
-
- -
-
- -
-
-
-

Documentation Pages

-
-
- {{-- --}} -
-
-
-
- - - - - - - - - - @foreach (DocumentationPage::all() as $page) - - - - - - @endforeach - -
TitleSource File
- - {{ $page->title }} - - - {{ $page->getSourcePath() }} -
-
-
-
-
\ No newline at end of file diff --git a/projects/shelf/admin/resources/views/pages/media.blade.php b/projects/shelf/admin/resources/views/pages/media.blade.php deleted file mode 100644 index a275c87633e..00000000000 --- a/projects/shelf/admin/resources/views/pages/media.blade.php +++ /dev/null @@ -1,113 +0,0 @@ -@php -use Hyde\Framework\Services\DiscoveryService; -@endphp - - - -
-

Your Media Library

-

Here you'll find an overview of your site's media assets.

-
-
-
- -
-
- -
-
-
-

Media Files

-
-
- {{-- --}} -
-
-
-
- - - - - - - - - - - - @foreach (DiscoveryService::getMediaAssetFiles() as $file) - - - - - - - @endforeach - -
FilenameTypeSizeLast modified
- - {{ basename($file) }} - - - @php - $ext = pathinfo($file, PATHINFO_EXTENSION); - if (in_array($ext, ['jpg', 'jpeg', 'png', 'gif', 'ico', 'svg'])) { - echo 'Image'; - } elseif (in_array($ext, ['css', 'scss', 'sass'])) { - echo 'Stylesheet'; - } elseif (in_array($ext, ['js', 'ts', 'php'])) { - echo 'Script'; - } elseif (in_array($ext, ['mp3', 'wav', 'ogg'])) { - echo 'Audio'; - } elseif (in_array($ext, ['mp4', 'webm', 'ogg'])) { - echo 'Video'; - } else { - echo 'File'; - } - @endphp - - @php - $size = filesize($file); - if ($size < 1024) { echo $size . ' bytes' ; } elseif ($size < 1048576) { echo - round($size / 1024, 2) . ' KB' ; } else { echo round($size / 1048576, 2) . ' MB' ; } - @endphp - {{ \Carbon\Carbon::parse(filemtime($file))->diffForHumans() }} -
-
-
- - -
-
-
-

Image Gallery

-
-
- {{-- --}} -
-
-
-
-
- @foreach (DiscoveryService::getMediaAssetFiles() as $file) - @if(in_array(pathinfo($file, PATHINFO_EXTENSION), ['jpg', 'jpeg', 'png', 'gif', 'ico', 'svg'])) - - {{ basename($file) }} - - @endif - @endforeach -
-
-
-
-
\ No newline at end of file diff --git a/projects/shelf/admin/resources/views/pages/pages.blade.php b/projects/shelf/admin/resources/views/pages/pages.blade.php deleted file mode 100644 index b8aaa1392eb..00000000000 --- a/projects/shelf/admin/resources/views/pages/pages.blade.php +++ /dev/null @@ -1,103 +0,0 @@ -@php -use Hyde\Framework\Models\Pages\BladePage; -use Hyde\Framework\Models\Pages\MarkdownPage; -@endphp - - - -
-

Your pages

-

Here you'll find an overview of your Blade and Markdown pages.

-
-
-
- -
-
- -
-
-
-

Blade Pages

-
-
- {{-- --}} -
-
-
-
- - - - - - - - - - @foreach (BladePage::all() as $page) - - - - - @endforeach - -
TitleSource File
- - {{ Hyde::makeTitle($page->view) }} - - - {{ $page->getSourcePath() }} -
- -
-
- - -
-
-
-

Markdown Pages

-
-
- {{-- --}} -
-
-
-
- - - - - - - - - - @foreach (MarkdownPage::all() as $page) - - - - - @endforeach - -
TitleSource File
- - {{ $page->title }} - - - {{ $page->getSourcePath() }} -
- -
-
-
-
\ No newline at end of file diff --git a/projects/shelf/admin/resources/views/pages/posts.blade.php b/projects/shelf/admin/resources/views/pages/posts.blade.php deleted file mode 100644 index 47ab953d670..00000000000 --- a/projects/shelf/admin/resources/views/pages/posts.blade.php +++ /dev/null @@ -1,70 +0,0 @@ -@php -use Hyde\Framework\Models\Pages\MarkdownPage; -@endphp - - - -
-

Your Blog Posts

-

Here you'll find an overview of your Markdown blog posts.

-
-
-
- -
-
- -
-
-
-

Markdown Posts

-
-
- {{-- --}} -
-
-
-
- - - - - - - - - - - - - @foreach (MarkdownPost::all() as $post) - - - - - - - - @endforeach - -
TitleDateCategoryAuthorSource File
- - {{ $post->title }} - - - {{ $post->date->short }} - - {{ $post->category ?? 'Uncategorized' }} - - {{ $post->author->getName() }} - - {{ $post->getSourcePath() }} -
-
-
-
-
\ No newline at end of file diff --git a/projects/shelf/admin/src/Admin.php b/projects/shelf/admin/src/Admin.php deleted file mode 100644 index 0bfb8b22aed..00000000000 --- a/projects/shelf/admin/src/Admin.php +++ /dev/null @@ -1,8 +0,0 @@ -route = $this->request()?->get('route', 'dashboard') ?? 'dashboard'; - } - - public function getRouteKey(): string - { - return 'admin'; - } - - public function navigationMenuTitle(): string - { - return 'Admin Panel'; - } - - public function request(): ?Request - { - return isset($_SERVER['REQUEST_METHOD']) - ? Request::capture() - : null; - } - - public function view(): string - { - $view = 'hyde-admin::pages.'.$this->route; - - return view()->exists($view) ? $view : 'hyde-admin::pages.404'; - } -} diff --git a/projects/shelf/admin/src/AdminServiceProvider.php b/projects/shelf/admin/src/AdminServiceProvider.php deleted file mode 100644 index 5e71791df80..00000000000 --- a/projects/shelf/admin/src/AdminServiceProvider.php +++ /dev/null @@ -1,18 +0,0 @@ -loadViewsFrom(__DIR__.'/../resources/views', 'hyde-admin'); - - Hyde::routes()->addRoute( - (new AdminPage('hyde-admin::dashboard'))->getRoute() - ); - } -} diff --git a/projects/shelf/single-file-dashboard/dashboard-manual.txt b/projects/shelf/single-file-dashboard/dashboard-manual.txt deleted file mode 100644 index 3eb28cc16ed..00000000000 --- a/projects/shelf/single-file-dashboard/dashboard-manual.txt +++ /dev/null @@ -1,68 +0,0 @@ -HYDERC DASHBOARD MANUAL - -IMPORTANT NOTE - -As this is alpha stage software there may be bugs, -and usage is at your own risk. You should always keep -backups using Git version control or similar. - -A version allowing for community editing by creating -a public static HTML dashboard is planned, this would -then link to files on GitHub for collaboration. -Though, this idea may instead be handled in a separate -package included as a dashboard.blade.php file, -using the default layout. - - -SECURITY - -This is not a traditional CMS like WordPress and similar. -It's never supposed to be on production systems. -Instead, it's a local developer tool. -Think of it as an integrated development environment -specifically tailored for use with HydePHP projects. - -As the dashboard modifies files on the computer running it -and gives arbitrary access to the server by running shell -commands, opening files, and executing programs, it is -extremely important that the dashboard is not exposed -to the internet. You must only ever use this dashboard -as a local development tool. - -A basic check is made to block requests not made from -localhost as an extra precaution. You should still -never make the dashboard.php file publicly accessible. - -Also note that error reporting is enabled by default, -as the dashboard assumes that all who can access it -are authorized to use the system running it. - -The app is not safe against XSS/script injection either -as not all output is sanitized or escaped; and the -output that is escaped, is only made so to prevent -visual glitches, like displaying source HTML tags. - - -LICENSE - -MIT License - -Copyright (c) 2022 Caen De Silva - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. \ No newline at end of file diff --git a/projects/shelf/single-file-dashboard/dashboard.php b/projects/shelf/single-file-dashboard/dashboard.php deleted file mode 100644 index 0b608c757ac..00000000000 --- a/projects/shelf/single-file-dashboard/dashboard.php +++ /dev/null @@ -1,465 +0,0 @@ -HTTP/1.1 403 - Access Denied'; - echo '

You must be on localhost to access this page. Refusing to serve request.

'; - exit; -} - -// Load the same autoloader as the project -require_once sprintf('%s/vendor/autoload.php', BASE_PATH); - -use Hyde\Framework\Exceptions\FileNotFoundException; -use Hyde\Framework\Exceptions\UnsupportedPageTypeException; -use Hyde\Framework\Models\BladePage; -use Hyde\Framework\Models\DocumentationPage; -use Hyde\Framework\Models\MarkdownPage; -use Hyde\Framework\Models\MarkdownPost; -use Hyde\Framework\Services\DiscoveryService; -use Hyde\Hyde; - -const VERSION = 'dev-master'; - -// Run the dashboard app -try { - -// Create the Laravel app, and boot it up - try { - $app = require_once sprintf('%s/app/bootstrap.php', BASE_PATH); - } catch (\Throwable $th) { - try { - $app = require_once sprintf('%s/bootstrap/app.php', BASE_PATH); - } catch (\Throwable $th) { - throw $th; - } - } - $kernel = $app->make(Illuminate\Contracts\Console\Kernel::class); - $kernel->bootstrap(); - Hyde::setBasePath(BASE_PATH); - - // Create the Hyde interface - $hyde = new class() extends Hyde {}; - - // Create the project configuration class - $project = new class - { - public string $path; - public string $name; - - public function __construct() - { - $this->path = BASE_PATH; - $this->name = config('site.name', ucwords(str_replace('-', ' ', basename(BASE_PATH)))); - } - }; - - // Set the app name - $appname = e($project->name).' CMS'; - - // Get the request page - $page = $_GET['page'] ?? 'index'; - if ($page === 'dashboard' || $page === '') { - $page = 'index'; - } - - // Key => label - $routes = [ - 'index' => 'Dashboard', - '404' => '404 Page Not Found', - 'manual'=> 'Manual', - 'file-viewer' => 'File Viewer', - ]; - - if (! isset($routes[$page])) { - header('HTTP/1.1 404 Not Found'); - $page = '404'; - } - - // Set the page name - $pagename = $appname.' - '.$routes[$page]; - - // Helper functions - function icon(string $name) - { - $icons = [ - 'blade' => 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAACXBIWXMAAAPoAAAD6AG1e1JrAAAABlBMVEX/LR//LB96KezJAAAAAnRSTlN3CW8xmq0AAAA7SURBVAjXATAAz/8Ax/8AOfcAGcMARZwAbYgAbaYAbbYAbBEAbOMAY8cAZzcAcHcAPecAzZ8A8H8A+P+i4xJQuZ3gxwAAAABJRU5ErkJggg==', - 'markdown' => 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAKAQMAAACHcEzfAAAACXBIWXMAAAPoAAAD6AG1e1JrAAAABlBMVEVCQkJBQUFtOGGCAAAAAnRSTlPBCd2uk5MAAAAiSURBVAjXY2BgYKj/x+D3jMEljcEBiJwY/NIY/P6BBBkYAHYfCAEd79fPAAAAAElFTkSuQmCC', - 'documentation' => 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAACXBIWXMAAAPoAAAD6AG1e1JrAAAABlBMVEVXV1dUVFSxYS6RAAAAAnRSTlPnEHobuHcAAAArSURBVAjXY/j/nwGIHsgzPPBneJDO8KCc4QEzCD1+zPD4MJQBEXnADlQJABfcFU91j91PAAAAAElFTkSuQmCC', - ]; - - return $icons[$name] ?? ''; - } ?> - - - - - - - - - -<?= $pagename ?> - - - - - - - - - -
-
- -
-
-

-
- - -

- Project Information -

-
-
-
-
-

Installation Details

- - - - - - - - - - - - - - - -
Project NameProject PathFramework Version
name) ?>path) ?>version()) ?>
-
-
-

Content Overview

- - - - - - - - - - - - - - - - - -
Blade PagesMarkdown PagesDocumentation PagesBlog Posts
pages pages pages posts
-
-
- -

Your Pages

- - - - - - - - - - - - - - - - - - - - - - - - - - -
TypePage NameFile Path
- - Blade - - view ?> - - view.BladePage::$fileExtension ?> -
- - Markdown - - title ?> - - slug.MarkdownPage::$fileExtension ?> -
-
-
-
-
- -
-
-
- -
- type = $this->qualifyType($type); - $this->filename = urldecode($file); - $this->contentpath = $this->getContentpath(); - $this->filepath = Hyde::path($this->contentpath); - } - - protected function qualifyType(string $type) - { - $type = strtolower($type); - if ($type === 'bladepage') { - return BladePage::class; - } elseif ($type === 'markdownpage') { - return MarkdownPage::class; - } elseif ($type === 'documentationpage') { - return DocumentationPage::class; - } elseif ($type === 'markdownpost') { - return MarkdownPost::class; - } else { - throw new UnsupportedPageTypeException('Invalid file type'); - } - } - - protected function getContentpath() - { - $class = $this->type; - $filename = $this->filename; - $filepath = $class::$sourceDirectory.'/'.$filename.$class::$fileExtension; - if (! file_exists(Hyde::path($filepath))) { - throw new FileNotFoundException($filepath); - } - - return $filepath; - } - - public function getContents() - { - return file_get_contents($this->filepath); - } - }; - ?> - -
-

Showing file contentpath) ?>

- -
- -
-
-
-
getContents()) ?>
-
-
- -
-
- -
- - - - -
-
- -
- - - Go Back to dashboard? - -
-
-
- -
-
-
- - - - HydeCMS - - This page was generated in ms. - -
-
- -
-
-
- - - - - - - -Error'; - echo '

An error occurred while processing your request.

'; - echo '
'.$th->getMessage().'
'; - echo '

Extra information:

'; - echo '
'.$th->getTraceAsString().print_r($th, true).'
'; - exit($th->getCode()); - } From 3376ab9e824b5fee7831ff34edb5a0d76dc02ce5 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 19:59:55 +0200 Subject: [PATCH 025/768] Delete projects/templates directory --- projects/templates/README.md | 7 - projects/templates/dashboard.blade.php | 348 ------------------------- 2 files changed, 355 deletions(-) delete mode 100644 projects/templates/README.md delete mode 100644 projects/templates/dashboard.blade.php diff --git a/projects/templates/README.md b/projects/templates/README.md deleted file mode 100644 index c8f0389463a..00000000000 --- a/projects/templates/README.md +++ /dev/null @@ -1,7 +0,0 @@ -# HydePHP Page Templates - -A collection of page templates for use with HydePHP. - -Templates that are whole projects should be in their own repository but may be linked here. - -Contributions are very welcome! \ No newline at end of file diff --git a/projects/templates/dashboard.blade.php b/projects/templates/dashboard.blade.php deleted file mode 100644 index 51b62944a8f..00000000000 --- a/projects/templates/dashboard.blade.php +++ /dev/null @@ -1,348 +0,0 @@ -@php - use Hyde\Framework\Models\Pages\BladePage; - use Hyde\Framework\Models\Pages\MarkdownPage; - use Hyde\Framework\Models\Pages\DocumentationPage; - use Hyde\Framework\Models\Pages\MarkdownPost; - use Hyde\Framework\Services\DiscoveryService; - - $github = new class { - public bool $enabled; - - public function __construct() { - $this->enabled = (config('hyde.github_dashboard.enabled', false) === true) - && (config('hyde.github_dashboard.username') !== null) - && (config('hyde.github_dashboard.repository') !== null) - && (config('hyde.github_dashboard.branch') !== null); - } - - public function getLink(string $path): string { - $action = config('hyde.github_dashboard.action', 'view') === 'edit' ? 'edit' : 'blob'; - return sprintf("https://github.com/%s/%s/%s/%s/%s", - config('hyde.github_dashboard.username'), - config('hyde.github_dashboard.repository'), - $action, - config('hyde.github_dashboard.branch'), - $path - ); - } - - public function link(string $path): string { - return $this->enabled - ? ''.e($path).'' - : e($path); - } - }; -@endphp - -@extends('hyde::layouts.app') -@section('content') - @php($title = "Dashboard") - - - -
-
-

Project Dashboard

-

- - Here you can get a quick overview of your project. - -

-

- While this is useful when developing locally, - you may not want to use it when compiling - for production. -

-
- -
-
-

Project Details

-
- -
-

Installation Details

- - - - - - - - - - - - - - - - - -
Project NameProject PathFramework VersionPHP Version
{{ config('site.name', Hyde::makeTitle(basename(Hyde::path()))) }}{{ Hyde::path() }}{{ Hyde::version() }}{{ PHP_VERSION }} ({{ PHP_SAPI }})
- -

GitHub Integration

- - - - - - - - - - - @if (config('hyde.github_dashboard.enabled', false)) - - - - @else - - @endif - - -
UsernameRepositoryBranch
- - {{ config('hyde.github_dashboard.username', '') }} - - - - {{ config('hyde.github_dashboard.repository', '') }} - - - - {{ config('hyde.github_dashboard.branch', '') }} - - -

- - GitHub Dashboard Integrations is not enabled. - -

-
- - Show configuration guide. - -

- The GitHub integration allows you to easily - open dashboard files in your GitHub repository. -
- To enable it, you need to let Hyde know where - your GitHub repository is located.
- The repository is assumed to be a top level installation of Hyde/Hyde. -
- Add the following to your config/hyde.php file: -

-
'github_dashboard' => [
    'enabled' => true,
    'username' => 'octocat',
    'repository' => 'homepage',
    'branch' => 'main',
]
-
-
-
-
- -
-
-

Your Content

-
- -

Content Overview

- - - - - - - - - - - - - - - - - -
Blade PagesMarkdown PagesDocumentation PagesBlog Posts
- - {{ count(DiscoveryService::getBladePageFiles()) }} pages - - - - {{ count(DiscoveryService::getMarkdownPageFiles()) }} pages - - - - {{ count(DiscoveryService::getDocumentationPageFiles()) }} pages - - - - {{ count(DiscoveryService::getMarkdownPostFiles()) }} posts - -
- -
-

- Blade Pages - # -

- - - - - - - - - @foreach (BladePage::all() as $page) - - - - - @endforeach - -
TitleSource File
- - {{ Hyde::makeTitle($page->view) }} - - - {!! $github->link(BladePage::$sourceDirectory .'/'. $page->slug . BladePage::$fileExtension) !!} -
-
- -
-

- Markdown Pages - # -

- - - - - - - - - @foreach (MarkdownPage::all() as $page) - - - - - @endforeach - -
TitleSource File
- - {{ $page->title }} - - - {!! $github->link(MarkdownPage::$sourceDirectory .'/'. $page->slug . MarkdownPage::$fileExtension) !!} -
-
- -
-

- Documentation Pages - # -

- - - - - - - - - @foreach (DocumentationPage::all() as $page) - - - - - @endforeach - -
TitleSource File
- - {{ $page->title }} - - - {!! $github->link(DocumentationPage::$sourceDirectory .'/'. $page->slug . DocumentationPage::$fileExtension) !!} -
-
- -
-

- Blog Posts - # -

- - - - - - - - - @foreach (MarkdownPost::all() as $post) - - - - - @endforeach - -
TitleSource File
- - {{ $post->title }} - - - {!! $github->link(MarkdownPost::$sourceDirectory .'/'. $post->slug . MarkdownPost::$fileExtension) !!} -
-
-
-
-@endsection From 11de4f5db70ed47d47a9f75f4ea1b44715669c95 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:12:23 +0200 Subject: [PATCH 026/768] Move Commands namespace into Hyde\Console namespace --- config/commands.php | 2 +- .../Commands/HydeBuildRssFeedCommand.php | 2 +- .../Commands/HydeBuildSearchCommand.php | 2 +- .../Commands/HydeBuildSiteCommand.php | 2 +- .../Commands/HydeBuildSitemapCommand.php | 2 +- .../Commands/HydeDebugCommand.php | 2 +- .../Commands/HydeMakePageCommand.php | 2 +- .../Commands/HydeMakePostCommand.php | 2 +- .../Commands/HydePackageDiscoverCommand.php | 2 +- .../Commands/HydePublishHomepageCommand.php | 2 +- .../Commands/HydePublishViewsCommand.php | 2 +- .../Commands/HydeRebuildStaticSiteCommand.php | 2 +- .../Commands/HydeRouteListCommand.php | 2 +- .../Commands/HydeServeCommand.php | 2 +- .../Commands/HydeUpdateConfigsCommand.php | 2 +- .../Commands/HydeValidateCommand.php | 2 +- .../Actions/CreatesNewMarkdownPostFile.php | 2 +- .../src/Framework/HydeServiceProvider.php | 30 +++++++++---------- .../src/Framework/Services/BuildService.php | 2 +- .../Commands/HydeBuildRssFeedCommandTest.php | 2 +- .../Commands/HydeBuildSearchCommandTest.php | 2 +- .../Commands/HydeBuildSitemapCommandTest.php | 2 +- .../Commands/HydeMakePageCommandTest.php | 2 +- .../HydePackageDiscoverCommandTest.php | 2 +- .../HydePublishHomepageCommandTest.php | 2 +- .../Commands/HydePublishViewsCommandTest.php | 2 +- .../HydeRebuildStaticSiteCommandTest.php | 2 +- .../Commands/HydeRouteListCommandTest.php | 2 +- .../Feature/Commands/HydeServeCommandTest.php | 2 +- .../Commands/HydeUpdateConfigsCommandTest.php | 2 +- .../Commands/HydeValidateCommandTest.php | 2 +- .../Feature/Services/BuildTaskServiceTest.php | 2 +- .../tests/Feature/StaticSiteServiceTest.php | 2 +- 33 files changed, 47 insertions(+), 47 deletions(-) rename packages/framework/src/{Framework => Console}/Commands/HydeBuildRssFeedCommand.php (93%) rename packages/framework/src/{Framework => Console}/Commands/HydeBuildSearchCommand.php (94%) rename packages/framework/src/{Framework => Console}/Commands/HydeBuildSiteCommand.php (99%) rename packages/framework/src/{Framework => Console}/Commands/HydeBuildSitemapCommand.php (94%) rename packages/framework/src/{Framework => Console}/Commands/HydeDebugCommand.php (98%) rename packages/framework/src/{Framework => Console}/Commands/HydeMakePageCommand.php (98%) rename packages/framework/src/{Framework => Console}/Commands/HydeMakePostCommand.php (98%) rename packages/framework/src/{Framework => Console}/Commands/HydePackageDiscoverCommand.php (94%) rename packages/framework/src/{Framework => Console}/Commands/HydePublishHomepageCommand.php (98%) rename packages/framework/src/{Framework => Console}/Commands/HydePublishViewsCommand.php (98%) rename packages/framework/src/{Framework => Console}/Commands/HydeRebuildStaticSiteCommand.php (98%) rename packages/framework/src/{Framework => Console}/Commands/HydeRouteListCommand.php (98%) rename packages/framework/src/{Framework => Console}/Commands/HydeServeCommand.php (96%) rename packages/framework/src/{Framework => Console}/Commands/HydeUpdateConfigsCommand.php (95%) rename packages/framework/src/{Framework => Console}/Commands/HydeValidateCommand.php (97%) diff --git a/config/commands.php b/config/commands.php index 2b45dcc1be5..9ae1367d4f2 100644 --- a/config/commands.php +++ b/config/commands.php @@ -58,7 +58,7 @@ NunoMaduro\LaravelConsoleSummary\SummaryCommand::class, Symfony\Component\Console\Command\DumpCompletionCommand::class, Symfony\Component\Console\Command\HelpCommand::class, - Hyde\Framework\Commands\HydeDebugCommand::class, + \Hyde\Console\Commands\HydeDebugCommand::class, ], /* diff --git a/packages/framework/src/Framework/Commands/HydeBuildRssFeedCommand.php b/packages/framework/src/Console/Commands/HydeBuildRssFeedCommand.php similarity index 93% rename from packages/framework/src/Framework/Commands/HydeBuildRssFeedCommand.php rename to packages/framework/src/Console/Commands/HydeBuildRssFeedCommand.php index 6e5648dbcf0..cea7fd9aba4 100644 --- a/packages/framework/src/Framework/Commands/HydeBuildRssFeedCommand.php +++ b/packages/framework/src/Console/Commands/HydeBuildRssFeedCommand.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Commands; +namespace Hyde\Console\Commands; use Hyde\Framework\Actions\PostBuildTasks\GenerateRssFeed; use LaravelZero\Framework\Commands\Command; diff --git a/packages/framework/src/Framework/Commands/HydeBuildSearchCommand.php b/packages/framework/src/Console/Commands/HydeBuildSearchCommand.php similarity index 94% rename from packages/framework/src/Framework/Commands/HydeBuildSearchCommand.php rename to packages/framework/src/Console/Commands/HydeBuildSearchCommand.php index 81ae04129ec..fd529d6590e 100644 --- a/packages/framework/src/Framework/Commands/HydeBuildSearchCommand.php +++ b/packages/framework/src/Console/Commands/HydeBuildSearchCommand.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Commands; +namespace Hyde\Console\Commands; use Hyde\Framework\Actions\PostBuildTasks\GenerateSearch; use LaravelZero\Framework\Commands\Command; diff --git a/packages/framework/src/Framework/Commands/HydeBuildSiteCommand.php b/packages/framework/src/Console/Commands/HydeBuildSiteCommand.php similarity index 99% rename from packages/framework/src/Framework/Commands/HydeBuildSiteCommand.php rename to packages/framework/src/Console/Commands/HydeBuildSiteCommand.php index 3d40639c7e1..13dec77d62f 100644 --- a/packages/framework/src/Framework/Commands/HydeBuildSiteCommand.php +++ b/packages/framework/src/Console/Commands/HydeBuildSiteCommand.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Commands; +namespace Hyde\Console\Commands; use Exception; use Hyde\Framework\Actions\PostBuildTasks\GenerateRssFeed; diff --git a/packages/framework/src/Framework/Commands/HydeBuildSitemapCommand.php b/packages/framework/src/Console/Commands/HydeBuildSitemapCommand.php similarity index 94% rename from packages/framework/src/Framework/Commands/HydeBuildSitemapCommand.php rename to packages/framework/src/Console/Commands/HydeBuildSitemapCommand.php index d73142eeef3..920a885637b 100644 --- a/packages/framework/src/Framework/Commands/HydeBuildSitemapCommand.php +++ b/packages/framework/src/Console/Commands/HydeBuildSitemapCommand.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Commands; +namespace Hyde\Console\Commands; use Hyde\Framework\Actions\PostBuildTasks\GenerateSitemap; use LaravelZero\Framework\Commands\Command; diff --git a/packages/framework/src/Framework/Commands/HydeDebugCommand.php b/packages/framework/src/Console/Commands/HydeDebugCommand.php similarity index 98% rename from packages/framework/src/Framework/Commands/HydeDebugCommand.php rename to packages/framework/src/Console/Commands/HydeDebugCommand.php index 0b2868cf356..9cb25c8a40b 100644 --- a/packages/framework/src/Framework/Commands/HydeDebugCommand.php +++ b/packages/framework/src/Console/Commands/HydeDebugCommand.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Commands; +namespace Hyde\Console\Commands; use Composer\InstalledVersions; use Hyde\Hyde; diff --git a/packages/framework/src/Framework/Commands/HydeMakePageCommand.php b/packages/framework/src/Console/Commands/HydeMakePageCommand.php similarity index 98% rename from packages/framework/src/Framework/Commands/HydeMakePageCommand.php rename to packages/framework/src/Console/Commands/HydeMakePageCommand.php index 63a86e7f963..41d5693571e 100644 --- a/packages/framework/src/Framework/Commands/HydeMakePageCommand.php +++ b/packages/framework/src/Console/Commands/HydeMakePageCommand.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Commands; +namespace Hyde\Console\Commands; use Hyde\Framework\Actions\CreatesNewPageSourceFile; use Hyde\Framework\Exceptions\UnsupportedPageTypeException; diff --git a/packages/framework/src/Framework/Commands/HydeMakePostCommand.php b/packages/framework/src/Console/Commands/HydeMakePostCommand.php similarity index 98% rename from packages/framework/src/Framework/Commands/HydeMakePostCommand.php rename to packages/framework/src/Console/Commands/HydeMakePostCommand.php index 40899962d17..30be35c9b1c 100644 --- a/packages/framework/src/Framework/Commands/HydeMakePostCommand.php +++ b/packages/framework/src/Console/Commands/HydeMakePostCommand.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Commands; +namespace Hyde\Console\Commands; use Exception; use Hyde\Framework\Actions\CreatesNewMarkdownPostFile; diff --git a/packages/framework/src/Framework/Commands/HydePackageDiscoverCommand.php b/packages/framework/src/Console/Commands/HydePackageDiscoverCommand.php similarity index 94% rename from packages/framework/src/Framework/Commands/HydePackageDiscoverCommand.php rename to packages/framework/src/Console/Commands/HydePackageDiscoverCommand.php index fd15ceb064d..5097a5cb6d9 100644 --- a/packages/framework/src/Framework/Commands/HydePackageDiscoverCommand.php +++ b/packages/framework/src/Console/Commands/HydePackageDiscoverCommand.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Commands; +namespace Hyde\Console\Commands; use Hyde\Hyde; use Illuminate\Foundation\Console\PackageDiscoverCommand as BaseCommand; diff --git a/packages/framework/src/Framework/Commands/HydePublishHomepageCommand.php b/packages/framework/src/Console/Commands/HydePublishHomepageCommand.php similarity index 98% rename from packages/framework/src/Framework/Commands/HydePublishHomepageCommand.php rename to packages/framework/src/Console/Commands/HydePublishHomepageCommand.php index de05387d985..bdfc71aaad3 100644 --- a/packages/framework/src/Framework/Commands/HydePublishHomepageCommand.php +++ b/packages/framework/src/Console/Commands/HydePublishHomepageCommand.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Commands; +namespace Hyde\Console\Commands; use Hyde\Framework\Actions\PublishesHomepageView; use Hyde\Framework\Services\ChecksumService; diff --git a/packages/framework/src/Framework/Commands/HydePublishViewsCommand.php b/packages/framework/src/Console/Commands/HydePublishViewsCommand.php similarity index 98% rename from packages/framework/src/Framework/Commands/HydePublishViewsCommand.php rename to packages/framework/src/Console/Commands/HydePublishViewsCommand.php index 6cb8d1faff8..f417cef94a8 100644 --- a/packages/framework/src/Framework/Commands/HydePublishViewsCommand.php +++ b/packages/framework/src/Console/Commands/HydePublishViewsCommand.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Commands; +namespace Hyde\Console\Commands; use Hyde\Framework\Actions\PublishesHydeViews; use Hyde\Hyde; diff --git a/packages/framework/src/Framework/Commands/HydeRebuildStaticSiteCommand.php b/packages/framework/src/Console/Commands/HydeRebuildStaticSiteCommand.php similarity index 98% rename from packages/framework/src/Framework/Commands/HydeRebuildStaticSiteCommand.php rename to packages/framework/src/Console/Commands/HydeRebuildStaticSiteCommand.php index 808295b7270..8238b2500c0 100644 --- a/packages/framework/src/Framework/Commands/HydeRebuildStaticSiteCommand.php +++ b/packages/framework/src/Console/Commands/HydeRebuildStaticSiteCommand.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Commands; +namespace Hyde\Console\Commands; use Exception; use Hyde\Framework\Services\BuildService; diff --git a/packages/framework/src/Framework/Commands/HydeRouteListCommand.php b/packages/framework/src/Console/Commands/HydeRouteListCommand.php similarity index 98% rename from packages/framework/src/Framework/Commands/HydeRouteListCommand.php rename to packages/framework/src/Console/Commands/HydeRouteListCommand.php index e1bb9cc2101..e79f03ee7dd 100644 --- a/packages/framework/src/Framework/Commands/HydeRouteListCommand.php +++ b/packages/framework/src/Console/Commands/HydeRouteListCommand.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Commands; +namespace Hyde\Console\Commands; use Hyde\Framework\Services\DiscoveryService; use Hyde\Hyde; diff --git a/packages/framework/src/Framework/Commands/HydeServeCommand.php b/packages/framework/src/Console/Commands/HydeServeCommand.php similarity index 96% rename from packages/framework/src/Framework/Commands/HydeServeCommand.php rename to packages/framework/src/Console/Commands/HydeServeCommand.php index b1247ca8469..48bc604f6bb 100644 --- a/packages/framework/src/Framework/Commands/HydeServeCommand.php +++ b/packages/framework/src/Console/Commands/HydeServeCommand.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Commands; +namespace Hyde\Console\Commands; use Hyde\Hyde; use LaravelZero\Framework\Commands\Command; diff --git a/packages/framework/src/Framework/Commands/HydeUpdateConfigsCommand.php b/packages/framework/src/Console/Commands/HydeUpdateConfigsCommand.php similarity index 95% rename from packages/framework/src/Framework/Commands/HydeUpdateConfigsCommand.php rename to packages/framework/src/Console/Commands/HydeUpdateConfigsCommand.php index 7e395691841..35ba3f7d25a 100644 --- a/packages/framework/src/Framework/Commands/HydeUpdateConfigsCommand.php +++ b/packages/framework/src/Console/Commands/HydeUpdateConfigsCommand.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Commands; +namespace Hyde\Console\Commands; use Hyde\Hyde; use Illuminate\Support\Facades\File; diff --git a/packages/framework/src/Framework/Commands/HydeValidateCommand.php b/packages/framework/src/Console/Commands/HydeValidateCommand.php similarity index 97% rename from packages/framework/src/Framework/Commands/HydeValidateCommand.php rename to packages/framework/src/Console/Commands/HydeValidateCommand.php index b8f29d92a4a..34421d1b9f1 100644 --- a/packages/framework/src/Framework/Commands/HydeValidateCommand.php +++ b/packages/framework/src/Console/Commands/HydeValidateCommand.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Commands; +namespace Hyde\Console\Commands; use Hyde\Framework\Services\ValidationService; use LaravelZero\Framework\Commands\Command; diff --git a/packages/framework/src/Framework/Actions/CreatesNewMarkdownPostFile.php b/packages/framework/src/Framework/Actions/CreatesNewMarkdownPostFile.php index 724e5832d1b..20a33ae58ab 100644 --- a/packages/framework/src/Framework/Actions/CreatesNewMarkdownPostFile.php +++ b/packages/framework/src/Framework/Actions/CreatesNewMarkdownPostFile.php @@ -15,7 +15,7 @@ * using the Hyde command, and converts and formats the * data input by the user, and then saves the file. * - * @see \Hyde\Framework\Commands\HydeMakePostCommand + * @see \Hyde\Console\Commands\HydeMakePostCommand */ class CreatesNewMarkdownPostFile { diff --git a/packages/framework/src/Framework/HydeServiceProvider.php b/packages/framework/src/Framework/HydeServiceProvider.php index 9a9e1204ceb..379da278ad8 100644 --- a/packages/framework/src/Framework/HydeServiceProvider.php +++ b/packages/framework/src/Framework/HydeServiceProvider.php @@ -109,23 +109,23 @@ protected function initializeConfiguration() protected function registerHydeConsoleCommands(): void { $this->commands([ - Commands\HydePublishHomepageCommand::class, - Commands\HydeUpdateConfigsCommand::class, - Commands\HydePublishViewsCommand::class, - Commands\HydeRebuildStaticSiteCommand::class, - Commands\HydeBuildSiteCommand::class, - Commands\HydeBuildSitemapCommand::class, - Commands\HydeBuildRssFeedCommand::class, - Commands\HydeBuildSearchCommand::class, - Commands\HydeRouteListCommand::class, - Commands\HydeMakePostCommand::class, - Commands\HydeMakePageCommand::class, - Commands\HydeValidateCommand::class, + \Hyde\Console\Commands\HydePublishHomepageCommand::class, + \Hyde\Console\Commands\HydeUpdateConfigsCommand::class, + \Hyde\Console\Commands\HydePublishViewsCommand::class, + \Hyde\Console\Commands\HydeRebuildStaticSiteCommand::class, + \Hyde\Console\Commands\HydeBuildSiteCommand::class, + \Hyde\Console\Commands\HydeBuildSitemapCommand::class, + \Hyde\Console\Commands\HydeBuildRssFeedCommand::class, + \Hyde\Console\Commands\HydeBuildSearchCommand::class, + \Hyde\Console\Commands\HydeRouteListCommand::class, + \Hyde\Console\Commands\HydeMakePostCommand::class, + \Hyde\Console\Commands\HydeMakePageCommand::class, + \Hyde\Console\Commands\HydeValidateCommand::class, // Commands\HydeInstallCommand::class, - Commands\HydeDebugCommand::class, - Commands\HydeServeCommand::class, + \Hyde\Console\Commands\HydeDebugCommand::class, + \Hyde\Console\Commands\HydeServeCommand::class, - Commands\HydePackageDiscoverCommand::class, + \Hyde\Console\Commands\HydePackageDiscoverCommand::class, ]); } diff --git a/packages/framework/src/Framework/Services/BuildService.php b/packages/framework/src/Framework/Services/BuildService.php index 776bfe5b8a2..a065fe431d7 100644 --- a/packages/framework/src/Framework/Services/BuildService.php +++ b/packages/framework/src/Framework/Services/BuildService.php @@ -20,7 +20,7 @@ * * Handles the build loop which generates the static site. * - * @see \Hyde\Framework\Commands\HydeBuildSiteCommand + * @see \Hyde\Console\Commands\HydeBuildSiteCommand * @see \Hyde\Framework\Testing\Feature\StaticSiteServiceTest */ class BuildService diff --git a/packages/framework/tests/Feature/Commands/HydeBuildRssFeedCommandTest.php b/packages/framework/tests/Feature/Commands/HydeBuildRssFeedCommandTest.php index 24826a9ffaa..92257f1000f 100644 --- a/packages/framework/tests/Feature/Commands/HydeBuildRssFeedCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeBuildRssFeedCommandTest.php @@ -8,7 +8,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Framework\Commands\HydeBuildRssFeedCommand + * @covers \Hyde\Console\Commands\HydeBuildRssFeedCommand * @covers \Hyde\Framework\Actions\PostBuildTasks\GenerateRssFeed */ class HydeBuildRssFeedCommandTest extends TestCase diff --git a/packages/framework/tests/Feature/Commands/HydeBuildSearchCommandTest.php b/packages/framework/tests/Feature/Commands/HydeBuildSearchCommandTest.php index 867b68d923b..4bcc29239f0 100644 --- a/packages/framework/tests/Feature/Commands/HydeBuildSearchCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeBuildSearchCommandTest.php @@ -11,7 +11,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Framework\Commands\HydeBuildSearchCommand + * @covers \Hyde\Console\Commands\HydeBuildSearchCommand * @covers \Hyde\Framework\Actions\PostBuildTasks\GenerateSearch */ class HydeBuildSearchCommandTest extends TestCase diff --git a/packages/framework/tests/Feature/Commands/HydeBuildSitemapCommandTest.php b/packages/framework/tests/Feature/Commands/HydeBuildSitemapCommandTest.php index 3e8007b5d48..0337a1c967e 100644 --- a/packages/framework/tests/Feature/Commands/HydeBuildSitemapCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeBuildSitemapCommandTest.php @@ -8,7 +8,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Framework\Commands\HydeBuildSitemapCommand + * @covers \Hyde\Console\Commands\HydeBuildSitemapCommand * @covers \Hyde\Framework\Actions\PostBuildTasks\GenerateSitemap */ class HydeBuildSitemapCommandTest extends TestCase diff --git a/packages/framework/tests/Feature/Commands/HydeMakePageCommandTest.php b/packages/framework/tests/Feature/Commands/HydeMakePageCommandTest.php index b20970261dc..83988067c02 100644 --- a/packages/framework/tests/Feature/Commands/HydeMakePageCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeMakePageCommandTest.php @@ -10,7 +10,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Framework\Commands\HydeMakePageCommand + * @covers \Hyde\Console\Commands\HydeMakePageCommand */ class HydeMakePageCommandTest extends TestCase { diff --git a/packages/framework/tests/Feature/Commands/HydePackageDiscoverCommandTest.php b/packages/framework/tests/Feature/Commands/HydePackageDiscoverCommandTest.php index f6cdde9fff3..d5b83c6b3b3 100644 --- a/packages/framework/tests/Feature/Commands/HydePackageDiscoverCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydePackageDiscoverCommandTest.php @@ -9,7 +9,7 @@ use Illuminate\Foundation\PackageManifest; /** - * @covers \Hyde\Framework\Commands\HydePackageDiscoverCommand + * @covers \Hyde\Console\Commands\HydePackageDiscoverCommand */ class HydePackageDiscoverCommandTest extends TestCase { diff --git a/packages/framework/tests/Feature/Commands/HydePublishHomepageCommandTest.php b/packages/framework/tests/Feature/Commands/HydePublishHomepageCommandTest.php index 99a153984e5..1caf6050c64 100644 --- a/packages/framework/tests/Feature/Commands/HydePublishHomepageCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydePublishHomepageCommandTest.php @@ -8,7 +8,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Framework\Commands\HydePublishHomepageCommand + * @covers \Hyde\Console\Commands\HydePublishHomepageCommand */ class HydePublishHomepageCommandTest extends TestCase { diff --git a/packages/framework/tests/Feature/Commands/HydePublishViewsCommandTest.php b/packages/framework/tests/Feature/Commands/HydePublishViewsCommandTest.php index 1b6b2f5e11a..e2fbc9cb806 100644 --- a/packages/framework/tests/Feature/Commands/HydePublishViewsCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydePublishViewsCommandTest.php @@ -8,7 +8,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Framework\Commands\HydePublishViewsCommand + * @covers \Hyde\Console\Commands\HydePublishViewsCommand */ class HydePublishViewsCommandTest extends TestCase { diff --git a/packages/framework/tests/Feature/Commands/HydeRebuildStaticSiteCommandTest.php b/packages/framework/tests/Feature/Commands/HydeRebuildStaticSiteCommandTest.php index 457ee191f46..fbbd712ba30 100644 --- a/packages/framework/tests/Feature/Commands/HydeRebuildStaticSiteCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeRebuildStaticSiteCommandTest.php @@ -8,7 +8,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Framework\Commands\HydeRebuildStaticSiteCommand + * @covers \Hyde\Console\Commands\HydeRebuildStaticSiteCommand */ class HydeRebuildStaticSiteCommandTest extends TestCase { diff --git a/packages/framework/tests/Feature/Commands/HydeRouteListCommandTest.php b/packages/framework/tests/Feature/Commands/HydeRouteListCommandTest.php index fcaeccee998..64337722787 100644 --- a/packages/framework/tests/Feature/Commands/HydeRouteListCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeRouteListCommandTest.php @@ -7,7 +7,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Framework\Commands\HydeRouteListCommand + * @covers \Hyde\Console\Commands\HydeRouteListCommand */ class HydeRouteListCommandTest extends TestCase { diff --git a/packages/framework/tests/Feature/Commands/HydeServeCommandTest.php b/packages/framework/tests/Feature/Commands/HydeServeCommandTest.php index e5c3a559e56..4d75feb3619 100644 --- a/packages/framework/tests/Feature/Commands/HydeServeCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeServeCommandTest.php @@ -7,7 +7,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Framework\Commands\HydeServeCommand + * @covers \Hyde\Console\Commands\HydeServeCommand */ class HydeServeCommandTest extends TestCase { diff --git a/packages/framework/tests/Feature/Commands/HydeUpdateConfigsCommandTest.php b/packages/framework/tests/Feature/Commands/HydeUpdateConfigsCommandTest.php index 70ed94fa9fd..ac83daa2c86 100644 --- a/packages/framework/tests/Feature/Commands/HydeUpdateConfigsCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeUpdateConfigsCommandTest.php @@ -9,7 +9,7 @@ use Illuminate\Support\Facades\File; /** - * @covers \Hyde\Framework\Commands\HydeUpdateConfigsCommand + * @covers \Hyde\Console\Commands\HydeUpdateConfigsCommand */ class HydeUpdateConfigsCommandTest extends TestCase { diff --git a/packages/framework/tests/Feature/Commands/HydeValidateCommandTest.php b/packages/framework/tests/Feature/Commands/HydeValidateCommandTest.php index b2e68f5d83f..0b4e708f08d 100644 --- a/packages/framework/tests/Feature/Commands/HydeValidateCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeValidateCommandTest.php @@ -7,7 +7,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Framework\Commands\HydeValidateCommand + * @covers \Hyde\Console\Commands\HydeValidateCommand * @covers \Hyde\Framework\Services\ValidationService * @covers \Hyde\Framework\Models\Support\ValidationResult * diff --git a/packages/framework/tests/Feature/Services/BuildTaskServiceTest.php b/packages/framework/tests/Feature/Services/BuildTaskServiceTest.php index ef039917c1c..d1178920823 100644 --- a/packages/framework/tests/Feature/Services/BuildTaskServiceTest.php +++ b/packages/framework/tests/Feature/Services/BuildTaskServiceTest.php @@ -22,7 +22,7 @@ class BuildTaskServiceTest extends TestCase { /** - * @covers \Hyde\Framework\Commands\HydeBuildSiteCommand::runPostBuildActions + * @covers \Hyde\Console\Commands\HydeBuildSiteCommand::runPostBuildActions */ public function test_build_command_can_run_post_build_tasks() { diff --git a/packages/framework/tests/Feature/StaticSiteServiceTest.php b/packages/framework/tests/Feature/StaticSiteServiceTest.php index 60f3460129c..2a5e281f84c 100644 --- a/packages/framework/tests/Feature/StaticSiteServiceTest.php +++ b/packages/framework/tests/Feature/StaticSiteServiceTest.php @@ -10,7 +10,7 @@ use Illuminate\Support\Facades\File; /** - * @covers \Hyde\Framework\Commands\HydeBuildSiteCommand + * @covers \Hyde\Console\Commands\HydeBuildSiteCommand * @covers \Hyde\Framework\Services\BuildService */ class StaticSiteServiceTest extends TestCase From d1675aa282ec372bbfb931b59342fd8a2220d333 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:20:29 +0200 Subject: [PATCH 027/768] Remove "Hyde" prefix from the console command class names --- config/commands.php | 2 +- ...eedCommand.php => BuildRssFeedCommand.php} | 2 +- ...archCommand.php => BuildSearchCommand.php} | 2 +- ...ldSiteCommand.php => BuildSiteCommand.php} | 2 +- ...mapCommand.php => BuildSitemapCommand.php} | 2 +- ...{HydeDebugCommand.php => DebugCommand.php} | 2 +- ...akePageCommand.php => MakePageCommand.php} | 2 +- ...akePostCommand.php => MakePostCommand.php} | 2 +- ...Command.php => PackageDiscoverCommand.php} | 2 +- ...Command.php => PublishHomepageCommand.php} | 2 +- ...ewsCommand.php => PublishViewsCommand.php} | 2 +- ...mmand.php => RebuildStaticSiteCommand.php} | 2 +- ...teListCommand.php => RouteListCommand.php} | 2 +- ...{HydeServeCommand.php => ServeCommand.php} | 2 +- ...gsCommand.php => UpdateConfigsCommand.php} | 2 +- ...alidateCommand.php => ValidateCommand.php} | 2 +- .../Actions/CreatesNewMarkdownPostFile.php | 2 +- .../src/Framework/HydeServiceProvider.php | 30 +++++++++---------- .../src/Framework/Services/BuildService.php | 2 +- .../Commands/HydeBuildRssFeedCommandTest.php | 2 +- .../Commands/HydeBuildSearchCommandTest.php | 2 +- .../Commands/HydeBuildSitemapCommandTest.php | 2 +- .../Commands/HydeMakePageCommandTest.php | 2 +- .../HydePackageDiscoverCommandTest.php | 2 +- .../HydePublishHomepageCommandTest.php | 2 +- .../Commands/HydePublishViewsCommandTest.php | 2 +- .../HydeRebuildStaticSiteCommandTest.php | 2 +- .../Commands/HydeRouteListCommandTest.php | 2 +- .../Feature/Commands/HydeServeCommandTest.php | 2 +- .../Commands/HydeUpdateConfigsCommandTest.php | 2 +- .../Commands/HydeValidateCommandTest.php | 2 +- .../Feature/Services/BuildTaskServiceTest.php | 2 +- .../tests/Feature/StaticSiteServiceTest.php | 2 +- 33 files changed, 47 insertions(+), 47 deletions(-) rename packages/framework/src/Console/Commands/{HydeBuildRssFeedCommand.php => BuildRssFeedCommand.php} (92%) rename packages/framework/src/Console/Commands/{HydeBuildSearchCommand.php => BuildSearchCommand.php} (92%) rename packages/framework/src/Console/Commands/{HydeBuildSiteCommand.php => BuildSiteCommand.php} (99%) rename packages/framework/src/Console/Commands/{HydeBuildSitemapCommand.php => BuildSitemapCommand.php} (92%) rename packages/framework/src/Console/Commands/{HydeDebugCommand.php => DebugCommand.php} (97%) rename packages/framework/src/Console/Commands/{HydeMakePageCommand.php => MakePageCommand.php} (98%) rename packages/framework/src/Console/Commands/{HydeMakePostCommand.php => MakePostCommand.php} (98%) rename packages/framework/src/Console/Commands/{HydePackageDiscoverCommand.php => PackageDiscoverCommand.php} (90%) rename packages/framework/src/Console/Commands/{HydePublishHomepageCommand.php => PublishHomepageCommand.php} (98%) rename packages/framework/src/Console/Commands/{HydePublishViewsCommand.php => PublishViewsCommand.php} (98%) rename packages/framework/src/Console/Commands/{HydeRebuildStaticSiteCommand.php => RebuildStaticSiteCommand.php} (98%) rename packages/framework/src/Console/Commands/{HydeRouteListCommand.php => RouteListCommand.php} (97%) rename packages/framework/src/Console/Commands/{HydeServeCommand.php => ServeCommand.php} (96%) rename packages/framework/src/Console/Commands/{HydeUpdateConfigsCommand.php => UpdateConfigsCommand.php} (93%) rename packages/framework/src/Console/Commands/{HydeValidateCommand.php => ValidateCommand.php} (97%) diff --git a/config/commands.php b/config/commands.php index 9ae1367d4f2..d15ac8b7ac1 100644 --- a/config/commands.php +++ b/config/commands.php @@ -58,7 +58,7 @@ NunoMaduro\LaravelConsoleSummary\SummaryCommand::class, Symfony\Component\Console\Command\DumpCompletionCommand::class, Symfony\Component\Console\Command\HelpCommand::class, - \Hyde\Console\Commands\HydeDebugCommand::class, + \Hyde\Console\Commands\DebugCommand::class, ], /* diff --git a/packages/framework/src/Console/Commands/HydeBuildRssFeedCommand.php b/packages/framework/src/Console/Commands/BuildRssFeedCommand.php similarity index 92% rename from packages/framework/src/Console/Commands/HydeBuildRssFeedCommand.php rename to packages/framework/src/Console/Commands/BuildRssFeedCommand.php index cea7fd9aba4..27ec83910ae 100644 --- a/packages/framework/src/Console/Commands/HydeBuildRssFeedCommand.php +++ b/packages/framework/src/Console/Commands/BuildRssFeedCommand.php @@ -12,7 +12,7 @@ * * @see \Hyde\Framework\Testing\Feature\Commands\HydeBuildRssFeedCommandTest */ -class HydeBuildRssFeedCommand extends Command +class BuildRssFeedCommand extends Command { protected $signature = 'build:rss'; protected $description = 'Generate the RSS feed'; diff --git a/packages/framework/src/Console/Commands/HydeBuildSearchCommand.php b/packages/framework/src/Console/Commands/BuildSearchCommand.php similarity index 92% rename from packages/framework/src/Console/Commands/HydeBuildSearchCommand.php rename to packages/framework/src/Console/Commands/BuildSearchCommand.php index fd529d6590e..dda84826691 100644 --- a/packages/framework/src/Console/Commands/HydeBuildSearchCommand.php +++ b/packages/framework/src/Console/Commands/BuildSearchCommand.php @@ -12,7 +12,7 @@ * * @see \Hyde\Framework\Testing\Feature\Commands\HydeBuildSearchCommandTest */ -class HydeBuildSearchCommand extends Command +class BuildSearchCommand extends Command { protected $signature = 'build:search'; protected $description = 'Generate the docs/search.json'; diff --git a/packages/framework/src/Console/Commands/HydeBuildSiteCommand.php b/packages/framework/src/Console/Commands/BuildSiteCommand.php similarity index 99% rename from packages/framework/src/Console/Commands/HydeBuildSiteCommand.php rename to packages/framework/src/Console/Commands/BuildSiteCommand.php index 13dec77d62f..46bddc3c593 100644 --- a/packages/framework/src/Console/Commands/HydeBuildSiteCommand.php +++ b/packages/framework/src/Console/Commands/BuildSiteCommand.php @@ -21,7 +21,7 @@ * * @see \Hyde\Framework\Testing\Feature\StaticSiteServiceTest */ -class HydeBuildSiteCommand extends Command +class BuildSiteCommand extends Command { /** * The signature of the command. diff --git a/packages/framework/src/Console/Commands/HydeBuildSitemapCommand.php b/packages/framework/src/Console/Commands/BuildSitemapCommand.php similarity index 92% rename from packages/framework/src/Console/Commands/HydeBuildSitemapCommand.php rename to packages/framework/src/Console/Commands/BuildSitemapCommand.php index 920a885637b..e710dd7a2da 100644 --- a/packages/framework/src/Console/Commands/HydeBuildSitemapCommand.php +++ b/packages/framework/src/Console/Commands/BuildSitemapCommand.php @@ -12,7 +12,7 @@ * * @see \Hyde\Framework\Testing\Feature\Commands\HydeBuildSitemapCommandTest */ -class HydeBuildSitemapCommand extends Command +class BuildSitemapCommand extends Command { protected $signature = 'build:sitemap'; protected $description = 'Generate the sitemap.xml'; diff --git a/packages/framework/src/Console/Commands/HydeDebugCommand.php b/packages/framework/src/Console/Commands/DebugCommand.php similarity index 97% rename from packages/framework/src/Console/Commands/HydeDebugCommand.php rename to packages/framework/src/Console/Commands/DebugCommand.php index 9cb25c8a40b..957db4bb736 100644 --- a/packages/framework/src/Console/Commands/HydeDebugCommand.php +++ b/packages/framework/src/Console/Commands/DebugCommand.php @@ -11,7 +11,7 @@ /** * Hyde Command to print debug information. */ -class HydeDebugCommand extends Command +class DebugCommand extends Command { /** * The signature of the command. diff --git a/packages/framework/src/Console/Commands/HydeMakePageCommand.php b/packages/framework/src/Console/Commands/MakePageCommand.php similarity index 98% rename from packages/framework/src/Console/Commands/HydeMakePageCommand.php rename to packages/framework/src/Console/Commands/MakePageCommand.php index 41d5693571e..97f8e6638bc 100644 --- a/packages/framework/src/Console/Commands/HydeMakePageCommand.php +++ b/packages/framework/src/Console/Commands/MakePageCommand.php @@ -16,7 +16,7 @@ * * @see \Hyde\Framework\Testing\Feature\Commands\HydeMakePageCommandTest */ -class HydeMakePageCommand extends Command +class MakePageCommand extends Command { /** * The name and signature of the console command. diff --git a/packages/framework/src/Console/Commands/HydeMakePostCommand.php b/packages/framework/src/Console/Commands/MakePostCommand.php similarity index 98% rename from packages/framework/src/Console/Commands/HydeMakePostCommand.php rename to packages/framework/src/Console/Commands/MakePostCommand.php index 30be35c9b1c..195805af19b 100644 --- a/packages/framework/src/Console/Commands/HydeMakePostCommand.php +++ b/packages/framework/src/Console/Commands/MakePostCommand.php @@ -11,7 +11,7 @@ /** * Hyde Command to scaffold a new Markdown Post. */ -class HydeMakePostCommand extends Command +class MakePostCommand extends Command { /** * The signature of the command. diff --git a/packages/framework/src/Console/Commands/HydePackageDiscoverCommand.php b/packages/framework/src/Console/Commands/PackageDiscoverCommand.php similarity index 90% rename from packages/framework/src/Console/Commands/HydePackageDiscoverCommand.php rename to packages/framework/src/Console/Commands/PackageDiscoverCommand.php index 5097a5cb6d9..aaec2182792 100644 --- a/packages/framework/src/Console/Commands/HydePackageDiscoverCommand.php +++ b/packages/framework/src/Console/Commands/PackageDiscoverCommand.php @@ -11,7 +11,7 @@ /** * @see \Hyde\Framework\Testing\Feature\Commands\HydePackageDiscoverCommandTest */ -class HydePackageDiscoverCommand extends BaseCommand +class PackageDiscoverCommand extends BaseCommand { /** @var true */ protected $hidden = true; diff --git a/packages/framework/src/Console/Commands/HydePublishHomepageCommand.php b/packages/framework/src/Console/Commands/PublishHomepageCommand.php similarity index 98% rename from packages/framework/src/Console/Commands/HydePublishHomepageCommand.php rename to packages/framework/src/Console/Commands/PublishHomepageCommand.php index bdfc71aaad3..20ba9f725c6 100644 --- a/packages/framework/src/Console/Commands/HydePublishHomepageCommand.php +++ b/packages/framework/src/Console/Commands/PublishHomepageCommand.php @@ -15,7 +15,7 @@ * * @see \Hyde\Framework\Testing\Feature\Commands\HydePublishHomepageCommandTest */ -class HydePublishHomepageCommand extends Command +class PublishHomepageCommand extends Command { /** @var string */ protected $signature = 'publish:homepage {homepage? : The name of the page to publish} diff --git a/packages/framework/src/Console/Commands/HydePublishViewsCommand.php b/packages/framework/src/Console/Commands/PublishViewsCommand.php similarity index 98% rename from packages/framework/src/Console/Commands/HydePublishViewsCommand.php rename to packages/framework/src/Console/Commands/PublishViewsCommand.php index f417cef94a8..accaf0123a7 100644 --- a/packages/framework/src/Console/Commands/HydePublishViewsCommand.php +++ b/packages/framework/src/Console/Commands/PublishViewsCommand.php @@ -11,7 +11,7 @@ /** * Publish the Hyde Blade views. */ -class HydePublishViewsCommand extends Command +class PublishViewsCommand extends Command { /** @var string */ protected $signature = 'publish:views {category? : The category to publish}'; diff --git a/packages/framework/src/Console/Commands/HydeRebuildStaticSiteCommand.php b/packages/framework/src/Console/Commands/RebuildStaticSiteCommand.php similarity index 98% rename from packages/framework/src/Console/Commands/HydeRebuildStaticSiteCommand.php rename to packages/framework/src/Console/Commands/RebuildStaticSiteCommand.php index 8238b2500c0..25dc5b5f77e 100644 --- a/packages/framework/src/Console/Commands/HydeRebuildStaticSiteCommand.php +++ b/packages/framework/src/Console/Commands/RebuildStaticSiteCommand.php @@ -16,7 +16,7 @@ * * @see \Hyde\Framework\Testing\Feature\Commands\HydeRebuildStaticSiteCommandTest */ -class HydeRebuildStaticSiteCommand extends Command +class RebuildStaticSiteCommand extends Command { /** * The signature of the command. diff --git a/packages/framework/src/Console/Commands/HydeRouteListCommand.php b/packages/framework/src/Console/Commands/RouteListCommand.php similarity index 97% rename from packages/framework/src/Console/Commands/HydeRouteListCommand.php rename to packages/framework/src/Console/Commands/RouteListCommand.php index e79f03ee7dd..3e244fb9144 100644 --- a/packages/framework/src/Console/Commands/HydeRouteListCommand.php +++ b/packages/framework/src/Console/Commands/RouteListCommand.php @@ -13,7 +13,7 @@ * * @see \Hyde\Framework\Testing\Feature\Commands\HydeRouteListCommandTest */ -class HydeRouteListCommand extends Command +class RouteListCommand extends Command { protected $signature = 'route:list'; protected $description = 'Display all registered routes.'; diff --git a/packages/framework/src/Console/Commands/HydeServeCommand.php b/packages/framework/src/Console/Commands/ServeCommand.php similarity index 96% rename from packages/framework/src/Console/Commands/HydeServeCommand.php rename to packages/framework/src/Console/Commands/ServeCommand.php index 48bc604f6bb..9541bc2793a 100644 --- a/packages/framework/src/Console/Commands/HydeServeCommand.php +++ b/packages/framework/src/Console/Commands/ServeCommand.php @@ -10,7 +10,7 @@ /** * Start the realtime compiler server. */ -class HydeServeCommand extends Command +class ServeCommand extends Command { /** * The signature of the command. diff --git a/packages/framework/src/Console/Commands/HydeUpdateConfigsCommand.php b/packages/framework/src/Console/Commands/UpdateConfigsCommand.php similarity index 93% rename from packages/framework/src/Console/Commands/HydeUpdateConfigsCommand.php rename to packages/framework/src/Console/Commands/UpdateConfigsCommand.php index 35ba3f7d25a..e1957125f35 100644 --- a/packages/framework/src/Console/Commands/HydeUpdateConfigsCommand.php +++ b/packages/framework/src/Console/Commands/UpdateConfigsCommand.php @@ -13,7 +13,7 @@ * * @see \Hyde\Framework\Testing\Feature\Commands\HydeUpdateConfigsCommandTest */ -class HydeUpdateConfigsCommand extends Command +class UpdateConfigsCommand extends Command { /** @var string */ protected $signature = 'update:configs'; diff --git a/packages/framework/src/Console/Commands/HydeValidateCommand.php b/packages/framework/src/Console/Commands/ValidateCommand.php similarity index 97% rename from packages/framework/src/Console/Commands/HydeValidateCommand.php rename to packages/framework/src/Console/Commands/ValidateCommand.php index 34421d1b9f1..4ba9168242c 100644 --- a/packages/framework/src/Console/Commands/HydeValidateCommand.php +++ b/packages/framework/src/Console/Commands/ValidateCommand.php @@ -10,7 +10,7 @@ /** * @see \Hyde\Framework\Testing\Feature\Commands\HydeValidateCommandTest */ -class HydeValidateCommand extends Command +class ValidateCommand extends Command { /** @var string */ protected $signature = 'validate'; diff --git a/packages/framework/src/Framework/Actions/CreatesNewMarkdownPostFile.php b/packages/framework/src/Framework/Actions/CreatesNewMarkdownPostFile.php index 20a33ae58ab..0ba057e89da 100644 --- a/packages/framework/src/Framework/Actions/CreatesNewMarkdownPostFile.php +++ b/packages/framework/src/Framework/Actions/CreatesNewMarkdownPostFile.php @@ -15,7 +15,7 @@ * using the Hyde command, and converts and formats the * data input by the user, and then saves the file. * - * @see \Hyde\Console\Commands\HydeMakePostCommand + * @see \Hyde\Console\Commands\MakePostCommand */ class CreatesNewMarkdownPostFile { diff --git a/packages/framework/src/Framework/HydeServiceProvider.php b/packages/framework/src/Framework/HydeServiceProvider.php index 379da278ad8..902d378e814 100644 --- a/packages/framework/src/Framework/HydeServiceProvider.php +++ b/packages/framework/src/Framework/HydeServiceProvider.php @@ -109,23 +109,23 @@ protected function initializeConfiguration() protected function registerHydeConsoleCommands(): void { $this->commands([ - \Hyde\Console\Commands\HydePublishHomepageCommand::class, - \Hyde\Console\Commands\HydeUpdateConfigsCommand::class, - \Hyde\Console\Commands\HydePublishViewsCommand::class, - \Hyde\Console\Commands\HydeRebuildStaticSiteCommand::class, - \Hyde\Console\Commands\HydeBuildSiteCommand::class, - \Hyde\Console\Commands\HydeBuildSitemapCommand::class, - \Hyde\Console\Commands\HydeBuildRssFeedCommand::class, - \Hyde\Console\Commands\HydeBuildSearchCommand::class, - \Hyde\Console\Commands\HydeRouteListCommand::class, - \Hyde\Console\Commands\HydeMakePostCommand::class, - \Hyde\Console\Commands\HydeMakePageCommand::class, - \Hyde\Console\Commands\HydeValidateCommand::class, + \Hyde\Console\Commands\PublishHomepageCommand::class, + \Hyde\Console\Commands\UpdateConfigsCommand::class, + \Hyde\Console\Commands\PublishViewsCommand::class, + \Hyde\Console\Commands\RebuildStaticSiteCommand::class, + \Hyde\Console\Commands\BuildSiteCommand::class, + \Hyde\Console\Commands\BuildSitemapCommand::class, + \Hyde\Console\Commands\BuildRssFeedCommand::class, + \Hyde\Console\Commands\BuildSearchCommand::class, + \Hyde\Console\Commands\RouteListCommand::class, + \Hyde\Console\Commands\MakePostCommand::class, + \Hyde\Console\Commands\MakePageCommand::class, + \Hyde\Console\Commands\ValidateCommand::class, // Commands\HydeInstallCommand::class, - \Hyde\Console\Commands\HydeDebugCommand::class, - \Hyde\Console\Commands\HydeServeCommand::class, + \Hyde\Console\Commands\DebugCommand::class, + \Hyde\Console\Commands\ServeCommand::class, - \Hyde\Console\Commands\HydePackageDiscoverCommand::class, + \Hyde\Console\Commands\PackageDiscoverCommand::class, ]); } diff --git a/packages/framework/src/Framework/Services/BuildService.php b/packages/framework/src/Framework/Services/BuildService.php index a065fe431d7..c9405d6f2ac 100644 --- a/packages/framework/src/Framework/Services/BuildService.php +++ b/packages/framework/src/Framework/Services/BuildService.php @@ -20,7 +20,7 @@ * * Handles the build loop which generates the static site. * - * @see \Hyde\Console\Commands\HydeBuildSiteCommand + * @see \Hyde\Console\Commands\BuildSiteCommand * @see \Hyde\Framework\Testing\Feature\StaticSiteServiceTest */ class BuildService diff --git a/packages/framework/tests/Feature/Commands/HydeBuildRssFeedCommandTest.php b/packages/framework/tests/Feature/Commands/HydeBuildRssFeedCommandTest.php index 92257f1000f..f4056500797 100644 --- a/packages/framework/tests/Feature/Commands/HydeBuildRssFeedCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeBuildRssFeedCommandTest.php @@ -8,7 +8,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Console\Commands\HydeBuildRssFeedCommand + * @covers \Hyde\Console\Commands\BuildRssFeedCommand * @covers \Hyde\Framework\Actions\PostBuildTasks\GenerateRssFeed */ class HydeBuildRssFeedCommandTest extends TestCase diff --git a/packages/framework/tests/Feature/Commands/HydeBuildSearchCommandTest.php b/packages/framework/tests/Feature/Commands/HydeBuildSearchCommandTest.php index 4bcc29239f0..c5f698f243b 100644 --- a/packages/framework/tests/Feature/Commands/HydeBuildSearchCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeBuildSearchCommandTest.php @@ -11,7 +11,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Console\Commands\HydeBuildSearchCommand + * @covers \Hyde\Console\Commands\BuildSearchCommand * @covers \Hyde\Framework\Actions\PostBuildTasks\GenerateSearch */ class HydeBuildSearchCommandTest extends TestCase diff --git a/packages/framework/tests/Feature/Commands/HydeBuildSitemapCommandTest.php b/packages/framework/tests/Feature/Commands/HydeBuildSitemapCommandTest.php index 0337a1c967e..0c0e3979693 100644 --- a/packages/framework/tests/Feature/Commands/HydeBuildSitemapCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeBuildSitemapCommandTest.php @@ -8,7 +8,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Console\Commands\HydeBuildSitemapCommand + * @covers \Hyde\Console\Commands\BuildSitemapCommand * @covers \Hyde\Framework\Actions\PostBuildTasks\GenerateSitemap */ class HydeBuildSitemapCommandTest extends TestCase diff --git a/packages/framework/tests/Feature/Commands/HydeMakePageCommandTest.php b/packages/framework/tests/Feature/Commands/HydeMakePageCommandTest.php index 83988067c02..8257939b0d8 100644 --- a/packages/framework/tests/Feature/Commands/HydeMakePageCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeMakePageCommandTest.php @@ -10,7 +10,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Console\Commands\HydeMakePageCommand + * @covers \Hyde\Console\Commands\MakePageCommand */ class HydeMakePageCommandTest extends TestCase { diff --git a/packages/framework/tests/Feature/Commands/HydePackageDiscoverCommandTest.php b/packages/framework/tests/Feature/Commands/HydePackageDiscoverCommandTest.php index d5b83c6b3b3..9a62c45cad3 100644 --- a/packages/framework/tests/Feature/Commands/HydePackageDiscoverCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydePackageDiscoverCommandTest.php @@ -9,7 +9,7 @@ use Illuminate\Foundation\PackageManifest; /** - * @covers \Hyde\Console\Commands\HydePackageDiscoverCommand + * @covers \Hyde\Console\Commands\PackageDiscoverCommand */ class HydePackageDiscoverCommandTest extends TestCase { diff --git a/packages/framework/tests/Feature/Commands/HydePublishHomepageCommandTest.php b/packages/framework/tests/Feature/Commands/HydePublishHomepageCommandTest.php index 1caf6050c64..ea722fd6623 100644 --- a/packages/framework/tests/Feature/Commands/HydePublishHomepageCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydePublishHomepageCommandTest.php @@ -8,7 +8,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Console\Commands\HydePublishHomepageCommand + * @covers \Hyde\Console\Commands\PublishHomepageCommand */ class HydePublishHomepageCommandTest extends TestCase { diff --git a/packages/framework/tests/Feature/Commands/HydePublishViewsCommandTest.php b/packages/framework/tests/Feature/Commands/HydePublishViewsCommandTest.php index e2fbc9cb806..a18a5b13782 100644 --- a/packages/framework/tests/Feature/Commands/HydePublishViewsCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydePublishViewsCommandTest.php @@ -8,7 +8,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Console\Commands\HydePublishViewsCommand + * @covers \Hyde\Console\Commands\PublishViewsCommand */ class HydePublishViewsCommandTest extends TestCase { diff --git a/packages/framework/tests/Feature/Commands/HydeRebuildStaticSiteCommandTest.php b/packages/framework/tests/Feature/Commands/HydeRebuildStaticSiteCommandTest.php index fbbd712ba30..47348c4acf0 100644 --- a/packages/framework/tests/Feature/Commands/HydeRebuildStaticSiteCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeRebuildStaticSiteCommandTest.php @@ -8,7 +8,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Console\Commands\HydeRebuildStaticSiteCommand + * @covers \Hyde\Console\Commands\RebuildStaticSiteCommand */ class HydeRebuildStaticSiteCommandTest extends TestCase { diff --git a/packages/framework/tests/Feature/Commands/HydeRouteListCommandTest.php b/packages/framework/tests/Feature/Commands/HydeRouteListCommandTest.php index 64337722787..2b6626c20f8 100644 --- a/packages/framework/tests/Feature/Commands/HydeRouteListCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeRouteListCommandTest.php @@ -7,7 +7,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Console\Commands\HydeRouteListCommand + * @covers \Hyde\Console\Commands\RouteListCommand */ class HydeRouteListCommandTest extends TestCase { diff --git a/packages/framework/tests/Feature/Commands/HydeServeCommandTest.php b/packages/framework/tests/Feature/Commands/HydeServeCommandTest.php index 4d75feb3619..8df7207c635 100644 --- a/packages/framework/tests/Feature/Commands/HydeServeCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeServeCommandTest.php @@ -7,7 +7,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Console\Commands\HydeServeCommand + * @covers \Hyde\Console\Commands\ServeCommand */ class HydeServeCommandTest extends TestCase { diff --git a/packages/framework/tests/Feature/Commands/HydeUpdateConfigsCommandTest.php b/packages/framework/tests/Feature/Commands/HydeUpdateConfigsCommandTest.php index ac83daa2c86..3b5880a5d75 100644 --- a/packages/framework/tests/Feature/Commands/HydeUpdateConfigsCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeUpdateConfigsCommandTest.php @@ -9,7 +9,7 @@ use Illuminate\Support\Facades\File; /** - * @covers \Hyde\Console\Commands\HydeUpdateConfigsCommand + * @covers \Hyde\Console\Commands\UpdateConfigsCommand */ class HydeUpdateConfigsCommandTest extends TestCase { diff --git a/packages/framework/tests/Feature/Commands/HydeValidateCommandTest.php b/packages/framework/tests/Feature/Commands/HydeValidateCommandTest.php index 0b4e708f08d..2dddca3398f 100644 --- a/packages/framework/tests/Feature/Commands/HydeValidateCommandTest.php +++ b/packages/framework/tests/Feature/Commands/HydeValidateCommandTest.php @@ -7,7 +7,7 @@ use Hyde\Testing\TestCase; /** - * @covers \Hyde\Console\Commands\HydeValidateCommand + * @covers \Hyde\Console\Commands\ValidateCommand * @covers \Hyde\Framework\Services\ValidationService * @covers \Hyde\Framework\Models\Support\ValidationResult * diff --git a/packages/framework/tests/Feature/Services/BuildTaskServiceTest.php b/packages/framework/tests/Feature/Services/BuildTaskServiceTest.php index d1178920823..cc17d1c8089 100644 --- a/packages/framework/tests/Feature/Services/BuildTaskServiceTest.php +++ b/packages/framework/tests/Feature/Services/BuildTaskServiceTest.php @@ -22,7 +22,7 @@ class BuildTaskServiceTest extends TestCase { /** - * @covers \Hyde\Console\Commands\HydeBuildSiteCommand::runPostBuildActions + * @covers \Hyde\Console\Commands\BuildSiteCommand::runPostBuildActions */ public function test_build_command_can_run_post_build_tasks() { diff --git a/packages/framework/tests/Feature/StaticSiteServiceTest.php b/packages/framework/tests/Feature/StaticSiteServiceTest.php index 2a5e281f84c..adecf6872d9 100644 --- a/packages/framework/tests/Feature/StaticSiteServiceTest.php +++ b/packages/framework/tests/Feature/StaticSiteServiceTest.php @@ -10,7 +10,7 @@ use Illuminate\Support\Facades\File; /** - * @covers \Hyde\Console\Commands\HydeBuildSiteCommand + * @covers \Hyde\Console\Commands\BuildSiteCommand * @covers \Hyde\Framework\Services\BuildService */ class StaticSiteServiceTest extends TestCase From f3cedbfebb11673ab34a5d29d8bc8a53967aa2d6 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:27:36 +0200 Subject: [PATCH 028/768] Remove "Hyde" prefix for tests which subjects were renamed --- ...eBuildRssFeedCommandTest.php => BuildRssFeedCommandTest.php} | 2 +- ...ydeBuildSearchCommandTest.php => BuildSearchCommandTest.php} | 2 +- ...eBuildSitemapCommandTest.php => BuildSitemapCommandTest.php} | 2 +- .../{HydeMakePageCommandTest.php => MakePageCommandTest.php} | 2 +- ...geDiscoverCommandTest.php => PackageDiscoverCommandTest.php} | 2 +- ...shHomepageCommandTest.php => PublishHomepageCommandTest.php} | 2 +- ...ePublishViewsCommandTest.php => PublishViewsCommandTest.php} | 2 +- ...aticSiteCommandTest.php => RebuildStaticSiteCommandTest.php} | 2 +- .../{HydeRouteListCommandTest.php => RouteListCommandTest.php} | 2 +- .../Commands/{HydeServeCommandTest.php => ServeCommandTest.php} | 2 +- ...pdateConfigsCommandTest.php => UpdateConfigsCommandTest.php} | 2 +- .../{HydeValidateCommandTest.php => ValidateCommandTest.php} | 2 +- .../framework/tests/Feature/Services/ValidationServiceTest.php | 2 +- 13 files changed, 13 insertions(+), 13 deletions(-) rename packages/framework/tests/Feature/Commands/{HydeBuildRssFeedCommandTest.php => BuildRssFeedCommandTest.php} (96%) rename packages/framework/tests/Feature/Commands/{HydeBuildSearchCommandTest.php => BuildSearchCommandTest.php} (98%) rename packages/framework/tests/Feature/Commands/{HydeBuildSitemapCommandTest.php => BuildSitemapCommandTest.php} (93%) rename packages/framework/tests/Feature/Commands/{HydeMakePageCommandTest.php => MakePageCommandTest.php} (99%) rename packages/framework/tests/Feature/Commands/{HydePackageDiscoverCommandTest.php => PackageDiscoverCommandTest.php} (93%) rename packages/framework/tests/Feature/Commands/{HydePublishHomepageCommandTest.php => PublishHomepageCommandTest.php} (98%) rename packages/framework/tests/Feature/Commands/{HydePublishViewsCommandTest.php => PublishViewsCommandTest.php} (96%) rename packages/framework/tests/Feature/Commands/{HydeRebuildStaticSiteCommandTest.php => RebuildStaticSiteCommandTest.php} (97%) rename packages/framework/tests/Feature/Commands/{HydeRouteListCommandTest.php => RouteListCommandTest.php} (95%) rename packages/framework/tests/Feature/Commands/{HydeServeCommandTest.php => ServeCommandTest.php} (89%) rename packages/framework/tests/Feature/Commands/{HydeUpdateConfigsCommandTest.php => UpdateConfigsCommandTest.php} (96%) rename packages/framework/tests/Feature/Commands/{HydeValidateCommandTest.php => ValidateCommandTest.php} (95%) diff --git a/packages/framework/tests/Feature/Commands/HydeBuildRssFeedCommandTest.php b/packages/framework/tests/Feature/Commands/BuildRssFeedCommandTest.php similarity index 96% rename from packages/framework/tests/Feature/Commands/HydeBuildRssFeedCommandTest.php rename to packages/framework/tests/Feature/Commands/BuildRssFeedCommandTest.php index f4056500797..19567251b09 100644 --- a/packages/framework/tests/Feature/Commands/HydeBuildRssFeedCommandTest.php +++ b/packages/framework/tests/Feature/Commands/BuildRssFeedCommandTest.php @@ -11,7 +11,7 @@ * @covers \Hyde\Console\Commands\BuildRssFeedCommand * @covers \Hyde\Framework\Actions\PostBuildTasks\GenerateRssFeed */ -class HydeBuildRssFeedCommandTest extends TestCase +class BuildRssFeedCommandTest extends TestCase { public function test_rss_feed_is_generated_when_conditions_are_met() { diff --git a/packages/framework/tests/Feature/Commands/HydeBuildSearchCommandTest.php b/packages/framework/tests/Feature/Commands/BuildSearchCommandTest.php similarity index 98% rename from packages/framework/tests/Feature/Commands/HydeBuildSearchCommandTest.php rename to packages/framework/tests/Feature/Commands/BuildSearchCommandTest.php index c5f698f243b..1abaa7d33bb 100644 --- a/packages/framework/tests/Feature/Commands/HydeBuildSearchCommandTest.php +++ b/packages/framework/tests/Feature/Commands/BuildSearchCommandTest.php @@ -14,7 +14,7 @@ * @covers \Hyde\Console\Commands\BuildSearchCommand * @covers \Hyde\Framework\Actions\PostBuildTasks\GenerateSearch */ -class HydeBuildSearchCommandTest extends TestCase +class BuildSearchCommandTest extends TestCase { protected function setUp(): void { diff --git a/packages/framework/tests/Feature/Commands/HydeBuildSitemapCommandTest.php b/packages/framework/tests/Feature/Commands/BuildSitemapCommandTest.php similarity index 93% rename from packages/framework/tests/Feature/Commands/HydeBuildSitemapCommandTest.php rename to packages/framework/tests/Feature/Commands/BuildSitemapCommandTest.php index 0c0e3979693..c2a85a0625c 100644 --- a/packages/framework/tests/Feature/Commands/HydeBuildSitemapCommandTest.php +++ b/packages/framework/tests/Feature/Commands/BuildSitemapCommandTest.php @@ -11,7 +11,7 @@ * @covers \Hyde\Console\Commands\BuildSitemapCommand * @covers \Hyde\Framework\Actions\PostBuildTasks\GenerateSitemap */ -class HydeBuildSitemapCommandTest extends TestCase +class BuildSitemapCommandTest extends TestCase { public function test_sitemap_is_generated_when_conditions_are_met() { diff --git a/packages/framework/tests/Feature/Commands/HydeMakePageCommandTest.php b/packages/framework/tests/Feature/Commands/MakePageCommandTest.php similarity index 99% rename from packages/framework/tests/Feature/Commands/HydeMakePageCommandTest.php rename to packages/framework/tests/Feature/Commands/MakePageCommandTest.php index 8257939b0d8..e3cf802eb66 100644 --- a/packages/framework/tests/Feature/Commands/HydeMakePageCommandTest.php +++ b/packages/framework/tests/Feature/Commands/MakePageCommandTest.php @@ -12,7 +12,7 @@ /** * @covers \Hyde\Console\Commands\MakePageCommand */ -class HydeMakePageCommandTest extends TestCase +class MakePageCommandTest extends TestCase { protected string $markdownPath; protected string $bladePath; diff --git a/packages/framework/tests/Feature/Commands/HydePackageDiscoverCommandTest.php b/packages/framework/tests/Feature/Commands/PackageDiscoverCommandTest.php similarity index 93% rename from packages/framework/tests/Feature/Commands/HydePackageDiscoverCommandTest.php rename to packages/framework/tests/Feature/Commands/PackageDiscoverCommandTest.php index 9a62c45cad3..033b43c65d1 100644 --- a/packages/framework/tests/Feature/Commands/HydePackageDiscoverCommandTest.php +++ b/packages/framework/tests/Feature/Commands/PackageDiscoverCommandTest.php @@ -11,7 +11,7 @@ /** * @covers \Hyde\Console\Commands\PackageDiscoverCommand */ -class HydePackageDiscoverCommandTest extends TestCase +class PackageDiscoverCommandTest extends TestCase { public function test_package_discover_command_can_run() { diff --git a/packages/framework/tests/Feature/Commands/HydePublishHomepageCommandTest.php b/packages/framework/tests/Feature/Commands/PublishHomepageCommandTest.php similarity index 98% rename from packages/framework/tests/Feature/Commands/HydePublishHomepageCommandTest.php rename to packages/framework/tests/Feature/Commands/PublishHomepageCommandTest.php index ea722fd6623..bec3d4763ef 100644 --- a/packages/framework/tests/Feature/Commands/HydePublishHomepageCommandTest.php +++ b/packages/framework/tests/Feature/Commands/PublishHomepageCommandTest.php @@ -10,7 +10,7 @@ /** * @covers \Hyde\Console\Commands\PublishHomepageCommand */ -class HydePublishHomepageCommandTest extends TestCase +class PublishHomepageCommandTest extends TestCase { protected string $file; diff --git a/packages/framework/tests/Feature/Commands/HydePublishViewsCommandTest.php b/packages/framework/tests/Feature/Commands/PublishViewsCommandTest.php similarity index 96% rename from packages/framework/tests/Feature/Commands/HydePublishViewsCommandTest.php rename to packages/framework/tests/Feature/Commands/PublishViewsCommandTest.php index a18a5b13782..96d63528b3e 100644 --- a/packages/framework/tests/Feature/Commands/HydePublishViewsCommandTest.php +++ b/packages/framework/tests/Feature/Commands/PublishViewsCommandTest.php @@ -10,7 +10,7 @@ /** * @covers \Hyde\Console\Commands\PublishViewsCommand */ -class HydePublishViewsCommandTest extends TestCase +class PublishViewsCommandTest extends TestCase { protected function setUp(): void { diff --git a/packages/framework/tests/Feature/Commands/HydeRebuildStaticSiteCommandTest.php b/packages/framework/tests/Feature/Commands/RebuildStaticSiteCommandTest.php similarity index 97% rename from packages/framework/tests/Feature/Commands/HydeRebuildStaticSiteCommandTest.php rename to packages/framework/tests/Feature/Commands/RebuildStaticSiteCommandTest.php index 47348c4acf0..52fd10467cb 100644 --- a/packages/framework/tests/Feature/Commands/HydeRebuildStaticSiteCommandTest.php +++ b/packages/framework/tests/Feature/Commands/RebuildStaticSiteCommandTest.php @@ -10,7 +10,7 @@ /** * @covers \Hyde\Console\Commands\RebuildStaticSiteCommand */ -class HydeRebuildStaticSiteCommandTest extends TestCase +class RebuildStaticSiteCommandTest extends TestCase { public function test_handle_is_successful_with_valid_path() { diff --git a/packages/framework/tests/Feature/Commands/HydeRouteListCommandTest.php b/packages/framework/tests/Feature/Commands/RouteListCommandTest.php similarity index 95% rename from packages/framework/tests/Feature/Commands/HydeRouteListCommandTest.php rename to packages/framework/tests/Feature/Commands/RouteListCommandTest.php index 2b6626c20f8..0fdf675c70e 100644 --- a/packages/framework/tests/Feature/Commands/HydeRouteListCommandTest.php +++ b/packages/framework/tests/Feature/Commands/RouteListCommandTest.php @@ -9,7 +9,7 @@ /** * @covers \Hyde\Console\Commands\RouteListCommand */ -class HydeRouteListCommandTest extends TestCase +class RouteListCommandTest extends TestCase { public function testRouteListCommand() { diff --git a/packages/framework/tests/Feature/Commands/HydeServeCommandTest.php b/packages/framework/tests/Feature/Commands/ServeCommandTest.php similarity index 89% rename from packages/framework/tests/Feature/Commands/HydeServeCommandTest.php rename to packages/framework/tests/Feature/Commands/ServeCommandTest.php index 8df7207c635..ca6a10204dd 100644 --- a/packages/framework/tests/Feature/Commands/HydeServeCommandTest.php +++ b/packages/framework/tests/Feature/Commands/ServeCommandTest.php @@ -9,7 +9,7 @@ /** * @covers \Hyde\Console\Commands\ServeCommand */ -class HydeServeCommandTest extends TestCase +class ServeCommandTest extends TestCase { public function test_hyde_serve_command() { diff --git a/packages/framework/tests/Feature/Commands/HydeUpdateConfigsCommandTest.php b/packages/framework/tests/Feature/Commands/UpdateConfigsCommandTest.php similarity index 96% rename from packages/framework/tests/Feature/Commands/HydeUpdateConfigsCommandTest.php rename to packages/framework/tests/Feature/Commands/UpdateConfigsCommandTest.php index 3b5880a5d75..e79e7034f1e 100644 --- a/packages/framework/tests/Feature/Commands/HydeUpdateConfigsCommandTest.php +++ b/packages/framework/tests/Feature/Commands/UpdateConfigsCommandTest.php @@ -11,7 +11,7 @@ /** * @covers \Hyde\Console\Commands\UpdateConfigsCommand */ -class HydeUpdateConfigsCommandTest extends TestCase +class UpdateConfigsCommandTest extends TestCase { /** Setup */ public function setUp(): void diff --git a/packages/framework/tests/Feature/Commands/HydeValidateCommandTest.php b/packages/framework/tests/Feature/Commands/ValidateCommandTest.php similarity index 95% rename from packages/framework/tests/Feature/Commands/HydeValidateCommandTest.php rename to packages/framework/tests/Feature/Commands/ValidateCommandTest.php index 2dddca3398f..c550c0b56b7 100644 --- a/packages/framework/tests/Feature/Commands/HydeValidateCommandTest.php +++ b/packages/framework/tests/Feature/Commands/ValidateCommandTest.php @@ -13,7 +13,7 @@ * * @see \Hyde\Framework\Testing\Feature\Services\ValidationServiceTest */ -class HydeValidateCommandTest extends TestCase +class ValidateCommandTest extends TestCase { public function test_validate_command_can_run() { diff --git a/packages/framework/tests/Feature/Services/ValidationServiceTest.php b/packages/framework/tests/Feature/Services/ValidationServiceTest.php index 6fd2a11bb7d..19ea66e166b 100644 --- a/packages/framework/tests/Feature/Services/ValidationServiceTest.php +++ b/packages/framework/tests/Feature/Services/ValidationServiceTest.php @@ -15,7 +15,7 @@ * @covers \Hyde\Framework\Services\ValidationService * @covers \Hyde\Framework\Models\Support\ValidationResult * - * @see \Hyde\Framework\Testing\Feature\Commands\HydeValidateCommandTest + * @see \Hyde\Framework\Testing\Feature\Commands\ValidateCommandTest */ class ValidationServiceTest extends TestCase { From c2efd840704f1d3fffb13926c2045de871ff26eb Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:25:04 +0200 Subject: [PATCH 029/768] Add missing coverage tag --- packages/framework/tests/Feature/Commands/DebugCommandTest.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/framework/tests/Feature/Commands/DebugCommandTest.php b/packages/framework/tests/Feature/Commands/DebugCommandTest.php index 5b362ed8915..b6b3be045a2 100644 --- a/packages/framework/tests/Feature/Commands/DebugCommandTest.php +++ b/packages/framework/tests/Feature/Commands/DebugCommandTest.php @@ -6,6 +6,9 @@ use Hyde\Testing\TestCase; +/** + * @covers \Hyde\Console\Commands\DebugCommand + */ class DebugCommandTest extends TestCase { public function test_debug_command_can_run() From 6915a41fd80b3e2444fc73b82f4d2890ee96775d Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:28:00 +0200 Subject: [PATCH 030/768] Put test in the proper namespace --- .../Feature/{Commands => }/StaticSiteBuilderPostModuleTest.php | 2 +- packages/framework/tests/Unit/MarkdownPostParserTest.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) rename packages/framework/tests/Feature/{Commands => }/StaticSiteBuilderPostModuleTest.php (98%) diff --git a/packages/framework/tests/Feature/Commands/StaticSiteBuilderPostModuleTest.php b/packages/framework/tests/Feature/StaticSiteBuilderPostModuleTest.php similarity index 98% rename from packages/framework/tests/Feature/Commands/StaticSiteBuilderPostModuleTest.php rename to packages/framework/tests/Feature/StaticSiteBuilderPostModuleTest.php index be5c8086a61..54266a9930e 100644 --- a/packages/framework/tests/Feature/Commands/StaticSiteBuilderPostModuleTest.php +++ b/packages/framework/tests/Feature/StaticSiteBuilderPostModuleTest.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Testing\Feature\Commands; +namespace Hyde\Framework\Testing\Feature; use Hyde\Framework\Actions\StaticPageBuilder; use Hyde\Framework\Models\Pages\MarkdownPost; diff --git a/packages/framework/tests/Unit/MarkdownPostParserTest.php b/packages/framework/tests/Unit/MarkdownPostParserTest.php index 0d5f81c6fc1..3864c1988f8 100644 --- a/packages/framework/tests/Unit/MarkdownPostParserTest.php +++ b/packages/framework/tests/Unit/MarkdownPostParserTest.php @@ -11,7 +11,7 @@ use Hyde\Testing\TestCase; /** - * @see \Hyde\Framework\Testing\Feature\Commands\StaticSiteBuilderPostModuleTest for the compiler test. + * @see \Hyde\Framework\Testing\Feature\StaticSiteBuilderPostModuleTest for the compiler test. */ class MarkdownPostParserTest extends TestCase { From e43e631d0cb8fc538d96dfffeb2ea0e190468881 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:29:57 +0200 Subject: [PATCH 031/768] Update test link annotations --- packages/framework/src/Console/Commands/BuildRssFeedCommand.php | 2 +- packages/framework/src/Console/Commands/BuildSearchCommand.php | 2 +- packages/framework/src/Console/Commands/BuildSitemapCommand.php | 2 +- packages/framework/src/Console/Commands/MakePageCommand.php | 2 +- .../framework/src/Console/Commands/PackageDiscoverCommand.php | 2 +- .../framework/src/Console/Commands/PublishHomepageCommand.php | 2 +- .../framework/src/Console/Commands/RebuildStaticSiteCommand.php | 2 +- packages/framework/src/Console/Commands/RouteListCommand.php | 2 +- .../framework/src/Console/Commands/UpdateConfigsCommand.php | 2 +- packages/framework/src/Console/Commands/ValidateCommand.php | 2 +- .../framework/src/Framework/Models/Support/ValidationResult.php | 2 +- packages/framework/src/Framework/Services/ValidationService.php | 2 +- 12 files changed, 12 insertions(+), 12 deletions(-) diff --git a/packages/framework/src/Console/Commands/BuildRssFeedCommand.php b/packages/framework/src/Console/Commands/BuildRssFeedCommand.php index 27ec83910ae..f17cd16dbf4 100644 --- a/packages/framework/src/Console/Commands/BuildRssFeedCommand.php +++ b/packages/framework/src/Console/Commands/BuildRssFeedCommand.php @@ -10,7 +10,7 @@ /** * Hyde command to run the build process for the RSS feed. * - * @see \Hyde\Framework\Testing\Feature\Commands\HydeBuildRssFeedCommandTest + * @see \Hyde\Framework\Testing\Feature\Commands\BuildRssFeedCommandTest */ class BuildRssFeedCommand extends Command { diff --git a/packages/framework/src/Console/Commands/BuildSearchCommand.php b/packages/framework/src/Console/Commands/BuildSearchCommand.php index dda84826691..b15595d4bd3 100644 --- a/packages/framework/src/Console/Commands/BuildSearchCommand.php +++ b/packages/framework/src/Console/Commands/BuildSearchCommand.php @@ -10,7 +10,7 @@ /** * Hyde command to run the build process for the documentation search index. * - * @see \Hyde\Framework\Testing\Feature\Commands\HydeBuildSearchCommandTest + * @see \Hyde\Framework\Testing\Feature\Commands\BuildSearchCommandTest */ class BuildSearchCommand extends Command { diff --git a/packages/framework/src/Console/Commands/BuildSitemapCommand.php b/packages/framework/src/Console/Commands/BuildSitemapCommand.php index e710dd7a2da..9724b11386f 100644 --- a/packages/framework/src/Console/Commands/BuildSitemapCommand.php +++ b/packages/framework/src/Console/Commands/BuildSitemapCommand.php @@ -10,7 +10,7 @@ /** * Hyde command to run the build process for the sitemap. * - * @see \Hyde\Framework\Testing\Feature\Commands\HydeBuildSitemapCommandTest + * @see \Hyde\Framework\Testing\Feature\Commands\BuildSitemapCommandTest */ class BuildSitemapCommand extends Command { diff --git a/packages/framework/src/Console/Commands/MakePageCommand.php b/packages/framework/src/Console/Commands/MakePageCommand.php index 97f8e6638bc..df036b5d957 100644 --- a/packages/framework/src/Console/Commands/MakePageCommand.php +++ b/packages/framework/src/Console/Commands/MakePageCommand.php @@ -14,7 +14,7 @@ /** * Hyde Command to scaffold a new Markdown or Blade page file. * - * @see \Hyde\Framework\Testing\Feature\Commands\HydeMakePageCommandTest + * @see \Hyde\Framework\Testing\Feature\Commands\MakePageCommandTest */ class MakePageCommand extends Command { diff --git a/packages/framework/src/Console/Commands/PackageDiscoverCommand.php b/packages/framework/src/Console/Commands/PackageDiscoverCommand.php index aaec2182792..a996e562066 100644 --- a/packages/framework/src/Console/Commands/PackageDiscoverCommand.php +++ b/packages/framework/src/Console/Commands/PackageDiscoverCommand.php @@ -9,7 +9,7 @@ use Illuminate\Foundation\PackageManifest; /** - * @see \Hyde\Framework\Testing\Feature\Commands\HydePackageDiscoverCommandTest + * @see \Hyde\Framework\Testing\Feature\Commands\PackageDiscoverCommandTest */ class PackageDiscoverCommand extends BaseCommand { diff --git a/packages/framework/src/Console/Commands/PublishHomepageCommand.php b/packages/framework/src/Console/Commands/PublishHomepageCommand.php index 20ba9f725c6..9e3d99abf55 100644 --- a/packages/framework/src/Console/Commands/PublishHomepageCommand.php +++ b/packages/framework/src/Console/Commands/PublishHomepageCommand.php @@ -13,7 +13,7 @@ /** * Publish one of the default homepages. * - * @see \Hyde\Framework\Testing\Feature\Commands\HydePublishHomepageCommandTest + * @see \Hyde\Framework\Testing\Feature\Commands\PublishHomepageCommandTest */ class PublishHomepageCommand extends Command { diff --git a/packages/framework/src/Console/Commands/RebuildStaticSiteCommand.php b/packages/framework/src/Console/Commands/RebuildStaticSiteCommand.php index 25dc5b5f77e..8cf2967eff4 100644 --- a/packages/framework/src/Console/Commands/RebuildStaticSiteCommand.php +++ b/packages/framework/src/Console/Commands/RebuildStaticSiteCommand.php @@ -14,7 +14,7 @@ /** * Hyde Command to build a single static site file. * - * @see \Hyde\Framework\Testing\Feature\Commands\HydeRebuildStaticSiteCommandTest + * @see \Hyde\Framework\Testing\Feature\Commands\RebuildStaticSiteCommandTest */ class RebuildStaticSiteCommand extends Command { diff --git a/packages/framework/src/Console/Commands/RouteListCommand.php b/packages/framework/src/Console/Commands/RouteListCommand.php index 3e244fb9144..a5635dcb815 100644 --- a/packages/framework/src/Console/Commands/RouteListCommand.php +++ b/packages/framework/src/Console/Commands/RouteListCommand.php @@ -11,7 +11,7 @@ /** * Hyde command to display the list of site routes. * - * @see \Hyde\Framework\Testing\Feature\Commands\HydeRouteListCommandTest + * @see \Hyde\Framework\Testing\Feature\Commands\RouteListCommandTest */ class RouteListCommand extends Command { diff --git a/packages/framework/src/Console/Commands/UpdateConfigsCommand.php b/packages/framework/src/Console/Commands/UpdateConfigsCommand.php index e1957125f35..ba5632aa26d 100644 --- a/packages/framework/src/Console/Commands/UpdateConfigsCommand.php +++ b/packages/framework/src/Console/Commands/UpdateConfigsCommand.php @@ -11,7 +11,7 @@ /** * Publish the Hyde Config Files. * - * @see \Hyde\Framework\Testing\Feature\Commands\HydeUpdateConfigsCommandTest + * @see \Hyde\Framework\Testing\Feature\Commands\UpdateConfigsCommandTest */ class UpdateConfigsCommand extends Command { diff --git a/packages/framework/src/Console/Commands/ValidateCommand.php b/packages/framework/src/Console/Commands/ValidateCommand.php index 4ba9168242c..87b1cfaf1e6 100644 --- a/packages/framework/src/Console/Commands/ValidateCommand.php +++ b/packages/framework/src/Console/Commands/ValidateCommand.php @@ -8,7 +8,7 @@ use LaravelZero\Framework\Commands\Command; /** - * @see \Hyde\Framework\Testing\Feature\Commands\HydeValidateCommandTest + * @see \Hyde\Framework\Testing\Feature\Commands\ValidateCommandTest */ class ValidateCommand extends Command { diff --git a/packages/framework/src/Framework/Models/Support/ValidationResult.php b/packages/framework/src/Framework/Models/Support/ValidationResult.php index 4526a9c8caa..2f06e51c753 100644 --- a/packages/framework/src/Framework/Models/Support/ValidationResult.php +++ b/packages/framework/src/Framework/Models/Support/ValidationResult.php @@ -6,7 +6,7 @@ /** * @see \Hyde\Framework\Testing\Feature\Services\ValidationServiceTest - * @see \Hyde\Framework\Testing\Feature\Commands\HydeValidateCommandTest + * @see \Hyde\Framework\Testing\Feature\Commands\ValidateCommandTest */ class ValidationResult { diff --git a/packages/framework/src/Framework/Services/ValidationService.php b/packages/framework/src/Framework/Services/ValidationService.php index ce4f7be07a5..065f7544b16 100644 --- a/packages/framework/src/Framework/Services/ValidationService.php +++ b/packages/framework/src/Framework/Services/ValidationService.php @@ -10,7 +10,7 @@ /** * @see \Hyde\Framework\Testing\Feature\Services\ValidationServiceTest - * @see \Hyde\Framework\Testing\Feature\Commands\HydeValidateCommandTest + * @see \Hyde\Framework\Testing\Feature\Commands\ValidateCommandTest */ class ValidationService { From 9bb708ccfc0bc5c69734a5a5638c3439ac974f10 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:34:38 +0200 Subject: [PATCH 032/768] Add todo --- .../framework/src/Framework/Concerns/AbstractBuildTask.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/framework/src/Framework/Concerns/AbstractBuildTask.php b/packages/framework/src/Framework/Concerns/AbstractBuildTask.php index eb2843aa648..2e6e9889866 100644 --- a/packages/framework/src/Framework/Concerns/AbstractBuildTask.php +++ b/packages/framework/src/Framework/Concerns/AbstractBuildTask.php @@ -20,6 +20,10 @@ abstract class AbstractBuildTask implements BuildTaskContract protected static string $description = 'Generic build task'; protected float $timeStart; + + /** + * @todo Consider setting default value to 0 + */ protected ?int $exitCode = null; public function __construct(?OutputStyle $output = null) From 41c60f5c0bd3c106ee52c738b8edf7b11bb256fd Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:33:10 +0200 Subject: [PATCH 033/768] Add type annotations --- .../framework/src/Console/Commands/BuildRssFeedCommand.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/framework/src/Console/Commands/BuildRssFeedCommand.php b/packages/framework/src/Console/Commands/BuildRssFeedCommand.php index f17cd16dbf4..c7d905dba55 100644 --- a/packages/framework/src/Console/Commands/BuildRssFeedCommand.php +++ b/packages/framework/src/Console/Commands/BuildRssFeedCommand.php @@ -14,7 +14,10 @@ */ class BuildRssFeedCommand extends Command { + /** @var string */ protected $signature = 'build:rss'; + + /** @var string */ protected $description = 'Generate the RSS feed'; public function handle(): int From 2c9894b308fd8c3b479a5ede62749ccfa143efcf Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:35:09 +0200 Subject: [PATCH 034/768] Add type annotations --- packages/framework/src/Console/Commands/BuildSearchCommand.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/framework/src/Console/Commands/BuildSearchCommand.php b/packages/framework/src/Console/Commands/BuildSearchCommand.php index b15595d4bd3..42fcd21344c 100644 --- a/packages/framework/src/Console/Commands/BuildSearchCommand.php +++ b/packages/framework/src/Console/Commands/BuildSearchCommand.php @@ -14,7 +14,10 @@ */ class BuildSearchCommand extends Command { + /** @var string */ protected $signature = 'build:search'; + + /** @var string */ protected $description = 'Generate the docs/search.json'; public function handle(): int From 99d0d6ee20a221aca461d2ca7d063d6e71061131 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:36:30 +0200 Subject: [PATCH 035/768] Replace redundant PHPDoc comments with shorter type annotations --- .../src/Console/Commands/BuildSiteCommand.php | 12 ++---------- .../framework/src/Console/Commands/DebugCommand.php | 12 ++---------- .../src/Console/Commands/MakePostCommand.php | 12 ++---------- .../Console/Commands/RebuildStaticSiteCommand.php | 12 ++---------- .../framework/src/Console/Commands/ServeCommand.php | 12 ++---------- 5 files changed, 10 insertions(+), 50 deletions(-) diff --git a/packages/framework/src/Console/Commands/BuildSiteCommand.php b/packages/framework/src/Console/Commands/BuildSiteCommand.php index 46bddc3c593..84df6c718bb 100644 --- a/packages/framework/src/Console/Commands/BuildSiteCommand.php +++ b/packages/framework/src/Console/Commands/BuildSiteCommand.php @@ -23,11 +23,7 @@ */ class BuildSiteCommand extends Command { - /** - * The signature of the command. - * - * @var string - */ + /** @var string */ protected $signature = 'build {--run-dev : Run the NPM dev script after build} {--run-prod : Run the NPM prod script after build} @@ -35,11 +31,7 @@ class BuildSiteCommand extends Command {--pretty-urls : Should links in output use pretty URLs?} {--no-api : Disable API calls, for example, Torchlight}'; - /** - * The description of the command. - * - * @var string - */ + /** @var string */ protected $description = 'Build the static site'; protected BuildService $service; diff --git a/packages/framework/src/Console/Commands/DebugCommand.php b/packages/framework/src/Console/Commands/DebugCommand.php index 957db4bb736..1b33738df9d 100644 --- a/packages/framework/src/Console/Commands/DebugCommand.php +++ b/packages/framework/src/Console/Commands/DebugCommand.php @@ -13,18 +13,10 @@ */ class DebugCommand extends Command { - /** - * The signature of the command. - * - * @var string - */ + /** @var string */ protected $signature = 'debug'; - /** - * The description of the command. - * - * @var string - */ + /** @var string */ protected $description = 'Print debug info'; public function __construct() diff --git a/packages/framework/src/Console/Commands/MakePostCommand.php b/packages/framework/src/Console/Commands/MakePostCommand.php index 195805af19b..41bfabf74a3 100644 --- a/packages/framework/src/Console/Commands/MakePostCommand.php +++ b/packages/framework/src/Console/Commands/MakePostCommand.php @@ -13,20 +13,12 @@ */ class MakePostCommand extends Command { - /** - * The signature of the command. - * - * @var string - */ + /** @var string */ protected $signature = 'make:post {title? : The title for the Post. Will be used to generate the slug} {--force : Should the generated file overwrite existing posts with the same slug?}'; - /** - * The description of the command. - * - * @var string - */ + /** @var string */ protected $description = 'Scaffold a new Markdown blog post file'; /** diff --git a/packages/framework/src/Console/Commands/RebuildStaticSiteCommand.php b/packages/framework/src/Console/Commands/RebuildStaticSiteCommand.php index 8cf2967eff4..8275fba29d2 100644 --- a/packages/framework/src/Console/Commands/RebuildStaticSiteCommand.php +++ b/packages/framework/src/Console/Commands/RebuildStaticSiteCommand.php @@ -18,19 +18,11 @@ */ class RebuildStaticSiteCommand extends Command { - /** - * The signature of the command. - * - * @var string - */ + /** @var string */ protected $signature = 'rebuild {path : The relative file path (example: _posts/hello-world.md)}'; - /** - * The description of the command. - * - * @var string - */ + /** @var string */ protected $description = 'Run the static site builder for a single file'; /** diff --git a/packages/framework/src/Console/Commands/ServeCommand.php b/packages/framework/src/Console/Commands/ServeCommand.php index 9541bc2793a..92bc72c18e3 100644 --- a/packages/framework/src/Console/Commands/ServeCommand.php +++ b/packages/framework/src/Console/Commands/ServeCommand.php @@ -12,18 +12,10 @@ */ class ServeCommand extends Command { - /** - * The signature of the command. - * - * @var string - */ + /** @var string */ protected $signature = 'serve {--port=8080} {--host=localhost}'; - /** - * The description of the command. - * - * @var string - */ + /** @var string */ protected $description = 'Start the experimental realtime compiler.'; /** From b85f54449454a64c88d615d86d07af48e3359ad2 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:37:22 +0200 Subject: [PATCH 036/768] Remove redundant PHPDoc comments --- .../src/Console/Commands/BuildSiteCommand.php | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/packages/framework/src/Console/Commands/BuildSiteCommand.php b/packages/framework/src/Console/Commands/BuildSiteCommand.php index 84df6c718bb..df34306762d 100644 --- a/packages/framework/src/Console/Commands/BuildSiteCommand.php +++ b/packages/framework/src/Console/Commands/BuildSiteCommand.php @@ -36,13 +36,6 @@ class BuildSiteCommand extends Command protected BuildService $service; - /** - * Execute the console command. - * - * @return int - * - * @throws Exception - */ public function handle(): int { $time_start = microtime(true); @@ -84,11 +77,6 @@ protected function runPreBuildActions(): void } } - /** - * Run any post-build actions. - * - * @return void - */ public function runPostBuildActions(): void { $service = new BuildTaskService($this->output); From 1d0573f12576b97da6a066c10c8b1d4b2b5f19cf Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:37:55 +0200 Subject: [PATCH 037/768] Protected methods are already internal --- packages/framework/src/Console/Commands/BuildSiteCommand.php | 3 --- 1 file changed, 3 deletions(-) diff --git a/packages/framework/src/Console/Commands/BuildSiteCommand.php b/packages/framework/src/Console/Commands/BuildSiteCommand.php index df34306762d..298942bb303 100644 --- a/packages/framework/src/Console/Commands/BuildSiteCommand.php +++ b/packages/framework/src/Console/Commands/BuildSiteCommand.php @@ -59,7 +59,6 @@ public function handle(): int return 0; } - /** @internal */ protected function runPreBuildActions(): void { if ($this->option('no-api')) { @@ -104,7 +103,6 @@ public function runPostBuildActions(): void $service->runPostBuildTasks(); } - /** @internal */ protected function printFinishMessage(float $time_start): void { $execution_time = (microtime(true) - $time_start); @@ -121,7 +119,6 @@ protected function printFinishMessage(float $time_start): void ); } - /* @internal */ protected function runNodeCommand(string $command, string $message, ?string $actionMessage = null): void { $this->info($message.' This may take a second.'); From 3b5c46d85ee65616f5e7adbee69922a3d94ace17 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:38:47 +0200 Subject: [PATCH 038/768] Remove redundant PHPDoc comments --- packages/framework/src/Console/Commands/DebugCommand.php | 5 ----- packages/framework/src/Console/Commands/MakePostCommand.php | 5 ----- .../src/Console/Commands/RebuildStaticSiteCommand.php | 5 ----- packages/framework/src/Console/Commands/ServeCommand.php | 5 ----- 4 files changed, 20 deletions(-) diff --git a/packages/framework/src/Console/Commands/DebugCommand.php b/packages/framework/src/Console/Commands/DebugCommand.php index 1b33738df9d..9e3a1a6aba2 100644 --- a/packages/framework/src/Console/Commands/DebugCommand.php +++ b/packages/framework/src/Console/Commands/DebugCommand.php @@ -28,11 +28,6 @@ public function __construct() } } - /** - * Execute the console command. - * - * @return int - */ public function handle(): int { $this->info('HydePHP Debug Screen'); diff --git a/packages/framework/src/Console/Commands/MakePostCommand.php b/packages/framework/src/Console/Commands/MakePostCommand.php index 41bfabf74a3..06d9089188a 100644 --- a/packages/framework/src/Console/Commands/MakePostCommand.php +++ b/packages/framework/src/Console/Commands/MakePostCommand.php @@ -21,11 +21,6 @@ class MakePostCommand extends Command /** @var string */ protected $description = 'Scaffold a new Markdown blog post file'; - /** - * Execute the console command. - * - * @return int - */ public function handle(): int { $this->title('Creating a new post!'); diff --git a/packages/framework/src/Console/Commands/RebuildStaticSiteCommand.php b/packages/framework/src/Console/Commands/RebuildStaticSiteCommand.php index 8275fba29d2..0c83081893a 100644 --- a/packages/framework/src/Console/Commands/RebuildStaticSiteCommand.php +++ b/packages/framework/src/Console/Commands/RebuildStaticSiteCommand.php @@ -32,11 +32,6 @@ class RebuildStaticSiteCommand extends Command */ public string $path; - /** - * Execute the console command. - * - * @return int - */ public function handle(): int { $time_start = microtime(true); diff --git a/packages/framework/src/Console/Commands/ServeCommand.php b/packages/framework/src/Console/Commands/ServeCommand.php index 92bc72c18e3..03777b7b315 100644 --- a/packages/framework/src/Console/Commands/ServeCommand.php +++ b/packages/framework/src/Console/Commands/ServeCommand.php @@ -18,11 +18,6 @@ class ServeCommand extends Command /** @var string */ protected $description = 'Start the experimental realtime compiler.'; - /** - * Execute the console command. - * - * @return int - */ public function handle(): int { $this->line('Starting the HydeRC server... Press Ctrl+C to stop'); From 09ecd5e2e3e74bf4b9e6b6309dd472e158a1dfb0 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:41:00 +0200 Subject: [PATCH 039/768] Remove unnecessary PHPDoc comments --- .../src/Console/Commands/MakePageCommand.php | 27 ++----------------- 1 file changed, 2 insertions(+), 25 deletions(-) diff --git a/packages/framework/src/Console/Commands/MakePageCommand.php b/packages/framework/src/Console/Commands/MakePageCommand.php index df036b5d957..71b3379da33 100644 --- a/packages/framework/src/Console/Commands/MakePageCommand.php +++ b/packages/framework/src/Console/Commands/MakePageCommand.php @@ -18,11 +18,7 @@ */ class MakePageCommand extends Command { - /** - * The name and signature of the console command. - * - * @var string - */ + /** @var string */ protected $signature = 'make:page {title? : The name of the page file to create. Will be used to generate the slug} {--type=markdown : The type of page to create (markdown, blade, or docs)} @@ -30,11 +26,7 @@ class MakePageCommand extends Command {--docs : Create a Documentation page} {--force : Overwrite any existing files}'; - /** - * The console command description. - * - * @var string - */ + /** @var string */ protected $description = 'Scaffold a new Markdown, Blade, or documentation page file'; /** @@ -57,9 +49,6 @@ class MakePageCommand extends Command */ public bool $force; - /** - * Execute the console command. - */ public function handle(): int { $this->title('Creating a new page!'); @@ -81,13 +70,6 @@ public function handle(): int return 0; } - /** - * Validate the options passed to the command. - * - * @return void - * - * @throws UnsupportedPageTypeException if the page type is invalid. - */ protected function validateOptions(): void { $type = $this->getSelectedType(); @@ -112,11 +94,6 @@ protected function validateOptions(): void throw new UnsupportedPageTypeException("Invalid page type: $type"); } - /** - * Get the selected page type. - * - * @return string - */ protected function getSelectedType(): string { $type = 'markdown'; From cee0692ce5df10d8cad2edc773f3eb1cd7d1ce54 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:41:35 +0200 Subject: [PATCH 040/768] Add 'void' as the function's return type --- .../framework/src/Console/Commands/PackageDiscoverCommand.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/framework/src/Console/Commands/PackageDiscoverCommand.php b/packages/framework/src/Console/Commands/PackageDiscoverCommand.php index a996e562066..800373fb217 100644 --- a/packages/framework/src/Console/Commands/PackageDiscoverCommand.php +++ b/packages/framework/src/Console/Commands/PackageDiscoverCommand.php @@ -16,7 +16,7 @@ class PackageDiscoverCommand extends BaseCommand /** @var true */ protected $hidden = true; - public function handle(PackageManifest $manifest) + public function handle(PackageManifest $manifest): void { $manifest->manifestPath = Hyde::path('storage/framework/cache/packages.php'); parent::handle($manifest); From b72604d42c82a585a8655ba217b1b17acdd35a42 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:42:43 +0200 Subject: [PATCH 041/768] Add type annotations --- packages/framework/src/Console/Commands/RouteListCommand.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/framework/src/Console/Commands/RouteListCommand.php b/packages/framework/src/Console/Commands/RouteListCommand.php index a5635dcb815..d11a02bcd26 100644 --- a/packages/framework/src/Console/Commands/RouteListCommand.php +++ b/packages/framework/src/Console/Commands/RouteListCommand.php @@ -15,7 +15,10 @@ */ class RouteListCommand extends Command { + /** @var string */ protected $signature = 'route:list'; + + /** @var string */ protected $description = 'Display all registered routes.'; public function handle(): int From cfdc1d1d5dceae20cd6583ac6f3698764d61086e Mon Sep 17 00:00:00 2001 From: StyleCI Bot Date: Wed, 26 Oct 2022 18:43:26 +0000 Subject: [PATCH 042/768] Apply fixes from StyleCI --- packages/framework/src/Console/Commands/BuildSiteCommand.php | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/framework/src/Console/Commands/BuildSiteCommand.php b/packages/framework/src/Console/Commands/BuildSiteCommand.php index 298942bb303..ab85fcd7e11 100644 --- a/packages/framework/src/Console/Commands/BuildSiteCommand.php +++ b/packages/framework/src/Console/Commands/BuildSiteCommand.php @@ -4,7 +4,6 @@ namespace Hyde\Console\Commands; -use Exception; use Hyde\Framework\Actions\PostBuildTasks\GenerateRssFeed; use Hyde\Framework\Actions\PostBuildTasks\GenerateSearch; use Hyde\Framework\Actions\PostBuildTasks\GenerateSitemap; From d66a5c6a2b44675861236c54343ecf5e45445282 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:46:03 +0200 Subject: [PATCH 043/768] Remove legacy comment --- packages/framework/src/Framework/HydeServiceProvider.php | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/framework/src/Framework/HydeServiceProvider.php b/packages/framework/src/Framework/HydeServiceProvider.php index 902d378e814..429b7a5a29f 100644 --- a/packages/framework/src/Framework/HydeServiceProvider.php +++ b/packages/framework/src/Framework/HydeServiceProvider.php @@ -121,7 +121,6 @@ protected function registerHydeConsoleCommands(): void \Hyde\Console\Commands\MakePostCommand::class, \Hyde\Console\Commands\MakePageCommand::class, \Hyde\Console\Commands\ValidateCommand::class, - // Commands\HydeInstallCommand::class, \Hyde\Console\Commands\DebugCommand::class, \Hyde\Console\Commands\ServeCommand::class, From cd6da2445787afddb744e34f6899906ac60ade97 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:47:19 +0200 Subject: [PATCH 044/768] Replace qualifier with an import --- packages/framework/src/Framework/HydeServiceProvider.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/framework/src/Framework/HydeServiceProvider.php b/packages/framework/src/Framework/HydeServiceProvider.php index 429b7a5a29f..56b62881977 100644 --- a/packages/framework/src/Framework/HydeServiceProvider.php +++ b/packages/framework/src/Framework/HydeServiceProvider.php @@ -4,6 +4,7 @@ namespace Hyde\Framework; +use Hyde\DataCollections\DataCollectionServiceProvider; use Hyde\Foundation\HydeKernel; use Hyde\Framework\Actions\MarkdownConverter; use Hyde\Framework\Concerns\RegistersFileLocations; @@ -133,6 +134,6 @@ protected function registerHydeConsoleCommands(): void */ protected function registerModuleServiceProviders(): void { - $this->app->register(\Hyde\DataCollections\DataCollectionServiceProvider::class); + $this->app->register(DataCollectionServiceProvider::class); } } From 0ce1a582ba9cfff025a880cafdb11819f529117b Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:47:48 +0200 Subject: [PATCH 045/768] Create HydeConsoleServiceProvider.php --- .../src/Console/HydeConsoleServiceProvider.php | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 packages/framework/src/Console/HydeConsoleServiceProvider.php diff --git a/packages/framework/src/Console/HydeConsoleServiceProvider.php b/packages/framework/src/Console/HydeConsoleServiceProvider.php new file mode 100644 index 00000000000..ee56fff8b29 --- /dev/null +++ b/packages/framework/src/Console/HydeConsoleServiceProvider.php @@ -0,0 +1,10 @@ + Date: Wed, 26 Oct 2022 20:47:56 +0200 Subject: [PATCH 046/768] Declare strict types --- packages/framework/src/Console/HydeConsoleServiceProvider.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/packages/framework/src/Console/HydeConsoleServiceProvider.php b/packages/framework/src/Console/HydeConsoleServiceProvider.php index ee56fff8b29..6875e342e20 100644 --- a/packages/framework/src/Console/HydeConsoleServiceProvider.php +++ b/packages/framework/src/Console/HydeConsoleServiceProvider.php @@ -1,5 +1,7 @@ Date: Wed, 26 Oct 2022 20:49:34 +0200 Subject: [PATCH 047/768] Register the new service provider --- packages/framework/src/Framework/HydeServiceProvider.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/packages/framework/src/Framework/HydeServiceProvider.php b/packages/framework/src/Framework/HydeServiceProvider.php index 56b62881977..f4670784c7c 100644 --- a/packages/framework/src/Framework/HydeServiceProvider.php +++ b/packages/framework/src/Framework/HydeServiceProvider.php @@ -4,6 +4,7 @@ namespace Hyde\Framework; +use Hyde\Console\HydeConsoleServiceProvider; use Hyde\DataCollections\DataCollectionServiceProvider; use Hyde\Foundation\HydeKernel; use Hyde\Framework\Actions\MarkdownConverter; @@ -134,6 +135,7 @@ protected function registerHydeConsoleCommands(): void */ protected function registerModuleServiceProviders(): void { + $this->app->register(HydeConsoleServiceProvider::class); $this->app->register(DataCollectionServiceProvider::class); } } From 4f42e655ce10bda031e1eade5d4a5118663e449a Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:49:53 +0200 Subject: [PATCH 048/768] Move registerHydeConsoleCommands to the new provider --- .../Console/HydeConsoleServiceProvider.php | 36 ++++++++++++++++++- .../src/Framework/HydeServiceProvider.php | 26 -------------- 2 files changed, 35 insertions(+), 27 deletions(-) diff --git a/packages/framework/src/Console/HydeConsoleServiceProvider.php b/packages/framework/src/Console/HydeConsoleServiceProvider.php index 6875e342e20..23eb683f9f4 100644 --- a/packages/framework/src/Console/HydeConsoleServiceProvider.php +++ b/packages/framework/src/Console/HydeConsoleServiceProvider.php @@ -8,5 +8,39 @@ class HydeConsoleServiceProvider extends ServiceProvider { - // + /** + * Register any console services. + * + * @return void + */ + public function register(): void + { + $this->registerHydeConsoleCommands(); + } + + /** + * Register the HydeCLI console commands. + */ + protected function registerHydeConsoleCommands(): void + { + $this->commands([ + \Hyde\Console\Commands\PublishHomepageCommand::class, + \Hyde\Console\Commands\UpdateConfigsCommand::class, + \Hyde\Console\Commands\PublishViewsCommand::class, + \Hyde\Console\Commands\RebuildStaticSiteCommand::class, + \Hyde\Console\Commands\BuildSiteCommand::class, + \Hyde\Console\Commands\BuildSitemapCommand::class, + \Hyde\Console\Commands\BuildRssFeedCommand::class, + \Hyde\Console\Commands\BuildSearchCommand::class, + \Hyde\Console\Commands\RouteListCommand::class, + \Hyde\Console\Commands\MakePostCommand::class, + \Hyde\Console\Commands\MakePageCommand::class, + \Hyde\Console\Commands\ValidateCommand::class, + \Hyde\Console\Commands\DebugCommand::class, + \Hyde\Console\Commands\ServeCommand::class, + + \Hyde\Console\Commands\PackageDiscoverCommand::class, + ]); + } + } diff --git a/packages/framework/src/Framework/HydeServiceProvider.php b/packages/framework/src/Framework/HydeServiceProvider.php index f4670784c7c..bdfa4394be8 100644 --- a/packages/framework/src/Framework/HydeServiceProvider.php +++ b/packages/framework/src/Framework/HydeServiceProvider.php @@ -60,7 +60,6 @@ public function register(): void $this->discoverBladeViewsIn(BladePage::sourceDirectory()); - $this->registerHydeConsoleCommands(); $this->registerModuleServiceProviders(); } @@ -105,31 +104,6 @@ protected function initializeConfiguration() } } - /** - * Register the HydeCLI console commands. - */ - protected function registerHydeConsoleCommands(): void - { - $this->commands([ - \Hyde\Console\Commands\PublishHomepageCommand::class, - \Hyde\Console\Commands\UpdateConfigsCommand::class, - \Hyde\Console\Commands\PublishViewsCommand::class, - \Hyde\Console\Commands\RebuildStaticSiteCommand::class, - \Hyde\Console\Commands\BuildSiteCommand::class, - \Hyde\Console\Commands\BuildSitemapCommand::class, - \Hyde\Console\Commands\BuildRssFeedCommand::class, - \Hyde\Console\Commands\BuildSearchCommand::class, - \Hyde\Console\Commands\RouteListCommand::class, - \Hyde\Console\Commands\MakePostCommand::class, - \Hyde\Console\Commands\MakePageCommand::class, - \Hyde\Console\Commands\ValidateCommand::class, - \Hyde\Console\Commands\DebugCommand::class, - \Hyde\Console\Commands\ServeCommand::class, - - \Hyde\Console\Commands\PackageDiscoverCommand::class, - ]); - } - /** * Register module service providers. */ From da7c6a16d06aea1448f3cf0760a366f12aee091d Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:50:39 +0200 Subject: [PATCH 049/768] Import the namespace group --- .../Console/HydeConsoleServiceProvider.php | 31 ++++++++++--------- 1 file changed, 16 insertions(+), 15 deletions(-) diff --git a/packages/framework/src/Console/HydeConsoleServiceProvider.php b/packages/framework/src/Console/HydeConsoleServiceProvider.php index 23eb683f9f4..b3fc9f6292c 100644 --- a/packages/framework/src/Console/HydeConsoleServiceProvider.php +++ b/packages/framework/src/Console/HydeConsoleServiceProvider.php @@ -5,6 +5,7 @@ namespace Hyde\Console; use Illuminate\Support\ServiceProvider; +use Hyde\Console\Commands; class HydeConsoleServiceProvider extends ServiceProvider { @@ -24,22 +25,22 @@ public function register(): void protected function registerHydeConsoleCommands(): void { $this->commands([ - \Hyde\Console\Commands\PublishHomepageCommand::class, - \Hyde\Console\Commands\UpdateConfigsCommand::class, - \Hyde\Console\Commands\PublishViewsCommand::class, - \Hyde\Console\Commands\RebuildStaticSiteCommand::class, - \Hyde\Console\Commands\BuildSiteCommand::class, - \Hyde\Console\Commands\BuildSitemapCommand::class, - \Hyde\Console\Commands\BuildRssFeedCommand::class, - \Hyde\Console\Commands\BuildSearchCommand::class, - \Hyde\Console\Commands\RouteListCommand::class, - \Hyde\Console\Commands\MakePostCommand::class, - \Hyde\Console\Commands\MakePageCommand::class, - \Hyde\Console\Commands\ValidateCommand::class, - \Hyde\Console\Commands\DebugCommand::class, - \Hyde\Console\Commands\ServeCommand::class, + Commands\PublishHomepageCommand::class, + Commands\UpdateConfigsCommand::class, + Commands\PublishViewsCommand::class, + Commands\RebuildStaticSiteCommand::class, + Commands\BuildSiteCommand::class, + Commands\BuildSitemapCommand::class, + Commands\BuildRssFeedCommand::class, + Commands\BuildSearchCommand::class, + Commands\RouteListCommand::class, + Commands\MakePostCommand::class, + Commands\MakePageCommand::class, + Commands\ValidateCommand::class, + Commands\DebugCommand::class, + Commands\ServeCommand::class, - \Hyde\Console\Commands\PackageDiscoverCommand::class, + Commands\PackageDiscoverCommand::class, ]); } From 3bca1500fa92fb5197da01c808f709d4fccb3efc Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:50:50 +0200 Subject: [PATCH 050/768] Remove unnecessary use statement --- packages/framework/src/Console/HydeConsoleServiceProvider.php | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/framework/src/Console/HydeConsoleServiceProvider.php b/packages/framework/src/Console/HydeConsoleServiceProvider.php index b3fc9f6292c..dde3df53aa2 100644 --- a/packages/framework/src/Console/HydeConsoleServiceProvider.php +++ b/packages/framework/src/Console/HydeConsoleServiceProvider.php @@ -5,7 +5,6 @@ namespace Hyde\Console; use Illuminate\Support\ServiceProvider; -use Hyde\Console\Commands; class HydeConsoleServiceProvider extends ServiceProvider { From cafb8599c7b777a9e6fb2af237aeb4e136bdb7ec Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:51:07 +0200 Subject: [PATCH 051/768] Remove unnecessary PHPDoc --- packages/framework/src/Console/HydeConsoleServiceProvider.php | 2 -- 1 file changed, 2 deletions(-) diff --git a/packages/framework/src/Console/HydeConsoleServiceProvider.php b/packages/framework/src/Console/HydeConsoleServiceProvider.php index dde3df53aa2..f6260bce93b 100644 --- a/packages/framework/src/Console/HydeConsoleServiceProvider.php +++ b/packages/framework/src/Console/HydeConsoleServiceProvider.php @@ -10,8 +10,6 @@ class HydeConsoleServiceProvider extends ServiceProvider { /** * Register any console services. - * - * @return void */ public function register(): void { From 363d9535c94a99373b92c3a8ab26a8b77f180041 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:51:20 +0200 Subject: [PATCH 052/768] Add class PHPDoc --- packages/framework/src/Console/HydeConsoleServiceProvider.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/framework/src/Console/HydeConsoleServiceProvider.php b/packages/framework/src/Console/HydeConsoleServiceProvider.php index f6260bce93b..a688c078534 100644 --- a/packages/framework/src/Console/HydeConsoleServiceProvider.php +++ b/packages/framework/src/Console/HydeConsoleServiceProvider.php @@ -6,6 +6,9 @@ use Illuminate\Support\ServiceProvider; +/** + * Register the HydeCLI console commands. + */ class HydeConsoleServiceProvider extends ServiceProvider { /** From 5e941268a3c0d1ad59b6106fef1977fb44040313 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:51:47 +0200 Subject: [PATCH 053/768] Inline helper method --- .../framework/src/Console/HydeConsoleServiceProvider.php | 8 -------- 1 file changed, 8 deletions(-) diff --git a/packages/framework/src/Console/HydeConsoleServiceProvider.php b/packages/framework/src/Console/HydeConsoleServiceProvider.php index a688c078534..e0775c8d93f 100644 --- a/packages/framework/src/Console/HydeConsoleServiceProvider.php +++ b/packages/framework/src/Console/HydeConsoleServiceProvider.php @@ -15,14 +15,6 @@ class HydeConsoleServiceProvider extends ServiceProvider * Register any console services. */ public function register(): void - { - $this->registerHydeConsoleCommands(); - } - - /** - * Register the HydeCLI console commands. - */ - protected function registerHydeConsoleCommands(): void { $this->commands([ Commands\PublishHomepageCommand::class, From 1362e6f5b33e5c4871fc931710048e86612fba74 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 20:54:19 +0200 Subject: [PATCH 054/768] Attempt some kind of sorting/grouping in register method --- .../Console/HydeConsoleServiceProvider.php | 25 ++++++++++--------- 1 file changed, 13 insertions(+), 12 deletions(-) diff --git a/packages/framework/src/Console/HydeConsoleServiceProvider.php b/packages/framework/src/Console/HydeConsoleServiceProvider.php index e0775c8d93f..8099e7526c7 100644 --- a/packages/framework/src/Console/HydeConsoleServiceProvider.php +++ b/packages/framework/src/Console/HydeConsoleServiceProvider.php @@ -17,23 +17,24 @@ class HydeConsoleServiceProvider extends ServiceProvider public function register(): void { $this->commands([ - Commands\PublishHomepageCommand::class, - Commands\UpdateConfigsCommand::class, - Commands\PublishViewsCommand::class, - Commands\RebuildStaticSiteCommand::class, - Commands\BuildSiteCommand::class, - Commands\BuildSitemapCommand::class, Commands\BuildRssFeedCommand::class, Commands\BuildSearchCommand::class, - Commands\RouteListCommand::class, - Commands\MakePostCommand::class, + Commands\BuildSiteCommand::class, + Commands\BuildSitemapCommand::class, + Commands\RebuildStaticSiteCommand::class, + Commands\MakePageCommand::class, - Commands\ValidateCommand::class, - Commands\DebugCommand::class, - Commands\ServeCommand::class, + Commands\MakePostCommand::class, + Commands\PublishHomepageCommand::class, + Commands\PublishViewsCommand::class, + Commands\UpdateConfigsCommand::class, Commands\PackageDiscoverCommand::class, + + Commands\RouteListCommand::class, + Commands\ValidateCommand::class, + Commands\ServeCommand::class, + Commands\DebugCommand::class, ]); } - } From 0f2763fc522ce2d87a92ed92267e9f27df779b43 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 21:00:09 +0200 Subject: [PATCH 055/768] Replace qualifier with an import --- .../src/DataCollections/DataCollectionServiceProvider.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/framework/src/DataCollections/DataCollectionServiceProvider.php b/packages/framework/src/DataCollections/DataCollectionServiceProvider.php index 1c60c6da21d..025fedf2be1 100644 --- a/packages/framework/src/DataCollections/DataCollectionServiceProvider.php +++ b/packages/framework/src/DataCollections/DataCollectionServiceProvider.php @@ -4,6 +4,7 @@ namespace Hyde\DataCollections; +use Hyde\DataCollections\Facades\MarkdownCollection; use Hyde\Framework\Helpers\Features; use Hyde\Hyde; use Illuminate\Foundation\AliasLoader; @@ -19,7 +20,7 @@ public function register() // Register the class alias AliasLoader::getInstance()->alias( 'MarkdownCollection', - \Hyde\DataCollections\Facades\MarkdownCollection::class + MarkdownCollection::class ); } From a219183b552a6d716877feafcb7b2bf30276f8fe Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 21:56:16 +0200 Subject: [PATCH 056/768] Move Author model to Blogging\Models namespace --- config/hyde.php | 2 +- packages/framework/config/hyde.php | 2 +- .../{Framework/Models/Support => Blogging/Models}/Author.php | 2 +- .../src/Framework/Concerns/Internal/ConstructsPageSchemas.php | 2 +- .../framework/src/Framework/Models/Pages/MarkdownPost.php | 2 +- .../framework/tests/Feature/AuthorPostsIntegrationTest.php | 2 +- packages/framework/tests/Feature/AuthorTest.php | 4 ++-- packages/framework/tests/Feature/MarkdownPostTest.php | 2 +- 8 files changed, 9 insertions(+), 9 deletions(-) rename packages/framework/src/{Framework/Models/Support => Blogging/Models}/Author.php (98%) diff --git a/config/hyde.php b/config/hyde.php index 2bcf6cd9fff..8336a1cdfb4 100644 --- a/config/hyde.php +++ b/config/hyde.php @@ -11,9 +11,9 @@ | */ +use Hyde\Blogging\Models\Author; use Hyde\Framework\Helpers\Features; use Hyde\Framework\Helpers\Meta; -use Hyde\Framework\Models\Support\Author; return [ /* diff --git a/packages/framework/config/hyde.php b/packages/framework/config/hyde.php index 2bcf6cd9fff..8336a1cdfb4 100644 --- a/packages/framework/config/hyde.php +++ b/packages/framework/config/hyde.php @@ -11,9 +11,9 @@ | */ +use Hyde\Blogging\Models\Author; use Hyde\Framework\Helpers\Features; use Hyde\Framework\Helpers\Meta; -use Hyde\Framework\Models\Support\Author; return [ /* diff --git a/packages/framework/src/Framework/Models/Support/Author.php b/packages/framework/src/Blogging/Models/Author.php similarity index 98% rename from packages/framework/src/Framework/Models/Support/Author.php rename to packages/framework/src/Blogging/Models/Author.php index 1ebd3bb9b17..7d241848d46 100644 --- a/packages/framework/src/Framework/Models/Support/Author.php +++ b/packages/framework/src/Blogging/Models/Author.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Models\Support; +namespace Hyde\Blogging\Models; use Illuminate\Support\Collection; use Stringable; diff --git a/packages/framework/src/Framework/Concerns/Internal/ConstructsPageSchemas.php b/packages/framework/src/Framework/Concerns/Internal/ConstructsPageSchemas.php index e948d04fad0..76e6ac2954d 100644 --- a/packages/framework/src/Framework/Concerns/Internal/ConstructsPageSchemas.php +++ b/packages/framework/src/Framework/Concerns/Internal/ConstructsPageSchemas.php @@ -4,11 +4,11 @@ namespace Hyde\Framework\Concerns\Internal; +use Hyde\Blogging\Models\Author; use Hyde\Framework\Actions\Constructors\FindsNavigationDataForPage; use Hyde\Framework\Actions\Constructors\FindsTitleForPage; use Hyde\Framework\Contracts\FrontMatter\BlogPostSchema; use Hyde\Framework\Models\Pages\MarkdownPost; -use Hyde\Framework\Models\Support\Author; use Hyde\Framework\Models\Support\DateString; use Hyde\Framework\Models\Support\Image; use Hyde\Hyde; diff --git a/packages/framework/src/Framework/Models/Pages/MarkdownPost.php b/packages/framework/src/Framework/Models/Pages/MarkdownPost.php index 50262032ec3..313451d1cfc 100644 --- a/packages/framework/src/Framework/Models/Pages/MarkdownPost.php +++ b/packages/framework/src/Framework/Models/Pages/MarkdownPost.php @@ -4,10 +4,10 @@ namespace Hyde\Framework\Models\Pages; +use Hyde\Blogging\Models\Author; use Hyde\Foundation\PageCollection; use Hyde\Framework\Concerns\BaseMarkdownPage; use Hyde\Framework\Contracts\FrontMatter\BlogPostSchema; -use Hyde\Framework\Models\Support\Author; use Hyde\Framework\Models\Support\DateString; use Hyde\Framework\Models\Support\Image; diff --git a/packages/framework/tests/Feature/AuthorPostsIntegrationTest.php b/packages/framework/tests/Feature/AuthorPostsIntegrationTest.php index 2bc63aa2146..2dd16814546 100644 --- a/packages/framework/tests/Feature/AuthorPostsIntegrationTest.php +++ b/packages/framework/tests/Feature/AuthorPostsIntegrationTest.php @@ -4,8 +4,8 @@ namespace Hyde\Framework\Testing\Feature; +use Hyde\Blogging\Models\Author; use Hyde\Framework\Actions\CreatesNewMarkdownPostFile; -use Hyde\Framework\Models\Support\Author; use Hyde\Hyde; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\Config; diff --git a/packages/framework/tests/Feature/AuthorTest.php b/packages/framework/tests/Feature/AuthorTest.php index 76aca6e9361..411b93623cb 100644 --- a/packages/framework/tests/Feature/AuthorTest.php +++ b/packages/framework/tests/Feature/AuthorTest.php @@ -4,13 +4,13 @@ namespace Hyde\Framework\Testing\Feature; -use Hyde\Framework\Models\Support\Author; +use Hyde\Blogging\Models\Author; use Hyde\Testing\TestCase; use Illuminate\Support\Collection; use Illuminate\Support\Facades\Config; /** - * @covers \Hyde\Framework\Models\Support\Author + * @covers \Hyde\Blogging\Models\Author */ class AuthorTest extends TestCase { diff --git a/packages/framework/tests/Feature/MarkdownPostTest.php b/packages/framework/tests/Feature/MarkdownPostTest.php index 14e030e8e2e..cc208c23f21 100644 --- a/packages/framework/tests/Feature/MarkdownPostTest.php +++ b/packages/framework/tests/Feature/MarkdownPostTest.php @@ -4,9 +4,9 @@ namespace Hyde\Framework\Testing\Feature; +use Hyde\Blogging\Models\Author; use Hyde\Framework\Models\Markdown\FrontMatter; use Hyde\Framework\Models\Pages\MarkdownPost; -use Hyde\Framework\Models\Support\Author; use Hyde\Framework\Models\Support\DateString; use Hyde\Framework\Models\Support\Image; use Hyde\Testing\TestCase; From 4e1bcc4750a0ec0a65c7ad6774c38b607acc0c80 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 21:56:58 +0200 Subject: [PATCH 057/768] Move Image model to Blogging\Models namespace --- .../{Framework/Models/Support => Blogging/Models}/Image.php | 2 +- .../Actions/Constructors/FindsContentLengthForImageObject.php | 2 +- .../src/Framework/Concerns/Internal/ConstructsPageSchemas.php | 2 +- .../Contracts/FrontMatter/Support/FeaturedImageSchema.php | 2 +- .../framework/src/Framework/Models/Pages/MarkdownPost.php | 2 +- .../tests/Feature/FindsContentLengthForImageObjectTest.php | 4 ++-- packages/framework/tests/Feature/ImageModelTest.php | 4 ++-- packages/framework/tests/Feature/MarkdownPostTest.php | 2 +- 8 files changed, 10 insertions(+), 10 deletions(-) rename packages/framework/src/{Framework/Models/Support => Blogging/Models}/Image.php (99%) diff --git a/packages/framework/src/Framework/Models/Support/Image.php b/packages/framework/src/Blogging/Models/Image.php similarity index 99% rename from packages/framework/src/Framework/Models/Support/Image.php rename to packages/framework/src/Blogging/Models/Image.php index e0aff73cfc8..b9135d19cdd 100644 --- a/packages/framework/src/Framework/Models/Support/Image.php +++ b/packages/framework/src/Blogging/Models/Image.php @@ -2,7 +2,7 @@ declare(strict_types=1); -namespace Hyde\Framework\Models\Support; +namespace Hyde\Blogging\Models; use Exception; use Hyde\Framework\Actions\Constructors\FindsContentLengthForImageObject; diff --git a/packages/framework/src/Framework/Actions/Constructors/FindsContentLengthForImageObject.php b/packages/framework/src/Framework/Actions/Constructors/FindsContentLengthForImageObject.php index 218121bbca7..a2dbcbd40af 100644 --- a/packages/framework/src/Framework/Actions/Constructors/FindsContentLengthForImageObject.php +++ b/packages/framework/src/Framework/Actions/Constructors/FindsContentLengthForImageObject.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Actions\Constructors; -use Hyde\Framework\Models\Support\Image; +use Hyde\Blogging\Models\Image; use Hyde\Hyde; use Illuminate\Support\Facades\Http; use Symfony\Component\Console\Output\ConsoleOutput; diff --git a/packages/framework/src/Framework/Concerns/Internal/ConstructsPageSchemas.php b/packages/framework/src/Framework/Concerns/Internal/ConstructsPageSchemas.php index 76e6ac2954d..e78a74398e0 100644 --- a/packages/framework/src/Framework/Concerns/Internal/ConstructsPageSchemas.php +++ b/packages/framework/src/Framework/Concerns/Internal/ConstructsPageSchemas.php @@ -5,12 +5,12 @@ namespace Hyde\Framework\Concerns\Internal; use Hyde\Blogging\Models\Author; +use Hyde\Blogging\Models\Image; use Hyde\Framework\Actions\Constructors\FindsNavigationDataForPage; use Hyde\Framework\Actions\Constructors\FindsTitleForPage; use Hyde\Framework\Contracts\FrontMatter\BlogPostSchema; use Hyde\Framework\Models\Pages\MarkdownPost; use Hyde\Framework\Models\Support\DateString; -use Hyde\Framework\Models\Support\Image; use Hyde\Hyde; trait ConstructsPageSchemas diff --git a/packages/framework/src/Framework/Contracts/FrontMatter/Support/FeaturedImageSchema.php b/packages/framework/src/Framework/Contracts/FrontMatter/Support/FeaturedImageSchema.php index a3bbfb61edd..74383567db5 100644 --- a/packages/framework/src/Framework/Contracts/FrontMatter/Support/FeaturedImageSchema.php +++ b/packages/framework/src/Framework/Contracts/FrontMatter/Support/FeaturedImageSchema.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Contracts\FrontMatter\Support; /** - * @see \Hyde\Framework\Models\Support\Image + * @see \Hyde\Blogging\Models\Image * @see \Hyde\Framework\Models\Pages\MarkdownPost */ interface FeaturedImageSchema diff --git a/packages/framework/src/Framework/Models/Pages/MarkdownPost.php b/packages/framework/src/Framework/Models/Pages/MarkdownPost.php index 313451d1cfc..195b07f95d1 100644 --- a/packages/framework/src/Framework/Models/Pages/MarkdownPost.php +++ b/packages/framework/src/Framework/Models/Pages/MarkdownPost.php @@ -5,11 +5,11 @@ namespace Hyde\Framework\Models\Pages; use Hyde\Blogging\Models\Author; +use Hyde\Blogging\Models\Image; use Hyde\Foundation\PageCollection; use Hyde\Framework\Concerns\BaseMarkdownPage; use Hyde\Framework\Contracts\FrontMatter\BlogPostSchema; use Hyde\Framework\Models\Support\DateString; -use Hyde\Framework\Models\Support\Image; /** * Page class for Markdown posts. diff --git a/packages/framework/tests/Feature/FindsContentLengthForImageObjectTest.php b/packages/framework/tests/Feature/FindsContentLengthForImageObjectTest.php index 533dbcf4069..8afd87eb488 100644 --- a/packages/framework/tests/Feature/FindsContentLengthForImageObjectTest.php +++ b/packages/framework/tests/Feature/FindsContentLengthForImageObjectTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Feature; -use Hyde\Framework\Models\Support\Image; +use Hyde\Blogging\Models\Image; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\Http; @@ -16,7 +16,7 @@ class FindsContentLengthForImageObjectTest extends TestCase /** * Unit test for the shorthand. Logic is tested in the rest of the case. * - * @covers \Hyde\Framework\Models\Support\Image::getContentLength + * @covers \Hyde\Blogging\Models\Image::getContentLength */ public function test_image_helper_shorthand_returns_content_length() { diff --git a/packages/framework/tests/Feature/ImageModelTest.php b/packages/framework/tests/Feature/ImageModelTest.php index 0b030e700ba..87c92d9e273 100644 --- a/packages/framework/tests/Feature/ImageModelTest.php +++ b/packages/framework/tests/Feature/ImageModelTest.php @@ -4,11 +4,11 @@ namespace Hyde\Framework\Testing\Feature; -use Hyde\Framework\Models\Support\Image; +use Hyde\Blogging\Models\Image; use Hyde\Testing\TestCase; /** - * @covers \Hyde\Framework\Models\Support\Image + * @covers \Hyde\Blogging\Models\Image */ class ImageModelTest extends TestCase { diff --git a/packages/framework/tests/Feature/MarkdownPostTest.php b/packages/framework/tests/Feature/MarkdownPostTest.php index cc208c23f21..a5fbdb3160d 100644 --- a/packages/framework/tests/Feature/MarkdownPostTest.php +++ b/packages/framework/tests/Feature/MarkdownPostTest.php @@ -5,10 +5,10 @@ namespace Hyde\Framework\Testing\Feature; use Hyde\Blogging\Models\Author; +use Hyde\Blogging\Models\Image; use Hyde\Framework\Models\Markdown\FrontMatter; use Hyde\Framework\Models\Pages\MarkdownPost; use Hyde\Framework\Models\Support\DateString; -use Hyde\Framework\Models\Support\Image; use Hyde\Testing\TestCase; /** From 369b2491fb8d177930a4ce5f2c078b07e81a1579 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 21:59:27 +0200 Subject: [PATCH 058/768] Rename Image to FeaturedImage since that's all it's used for --- .../Models/{Image.php => FeaturedImage.php} | 2 +- .../FindsContentLengthForImageObject.php | 6 +- .../Internal/ConstructsPageSchemas.php | 6 +- .../Support/FeaturedImageSchema.php | 2 +- .../Framework/Models/Pages/MarkdownPost.php | 4 +- .../FindsContentLengthForImageObjectTest.php | 14 +-- .../tests/Feature/ImageModelTest.php | 94 +++++++++---------- .../tests/Feature/MarkdownPostTest.php | 12 +-- 8 files changed, 70 insertions(+), 70 deletions(-) rename packages/framework/src/Blogging/Models/{Image.php => FeaturedImage.php} (99%) diff --git a/packages/framework/src/Blogging/Models/Image.php b/packages/framework/src/Blogging/Models/FeaturedImage.php similarity index 99% rename from packages/framework/src/Blogging/Models/Image.php rename to packages/framework/src/Blogging/Models/FeaturedImage.php index b9135d19cdd..41ff94bc017 100644 --- a/packages/framework/src/Blogging/Models/Image.php +++ b/packages/framework/src/Blogging/Models/FeaturedImage.php @@ -28,7 +28,7 @@ * @see \Hyde\Framework\Testing\Feature\ImageModelTest * @phpstan-consistent-constructor */ -class Image implements FeaturedImageSchema, Stringable +class FeaturedImage implements FeaturedImageSchema, Stringable { /** * The image's path (if it is stored locally (in the _media directory)). diff --git a/packages/framework/src/Framework/Actions/Constructors/FindsContentLengthForImageObject.php b/packages/framework/src/Framework/Actions/Constructors/FindsContentLengthForImageObject.php index a2dbcbd40af..5315b555b98 100644 --- a/packages/framework/src/Framework/Actions/Constructors/FindsContentLengthForImageObject.php +++ b/packages/framework/src/Framework/Actions/Constructors/FindsContentLengthForImageObject.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Actions\Constructors; -use Hyde\Blogging\Models\Image; +use Hyde\Blogging\Models\FeaturedImage; use Hyde\Hyde; use Illuminate\Support\Facades\Http; use Symfony\Component\Console\Output\ConsoleOutput; @@ -15,14 +15,14 @@ */ class FindsContentLengthForImageObject { - protected Image $image; + protected FeaturedImage $image; /** * Testing adding console debug output. */ protected OutputInterface $output; - public function __construct(Image $image) + public function __construct(FeaturedImage $image) { $this->image = $image; diff --git a/packages/framework/src/Framework/Concerns/Internal/ConstructsPageSchemas.php b/packages/framework/src/Framework/Concerns/Internal/ConstructsPageSchemas.php index e78a74398e0..534451d564b 100644 --- a/packages/framework/src/Framework/Concerns/Internal/ConstructsPageSchemas.php +++ b/packages/framework/src/Framework/Concerns/Internal/ConstructsPageSchemas.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Concerns\Internal; use Hyde\Blogging\Models\Author; -use Hyde\Blogging\Models\Image; +use Hyde\Blogging\Models\FeaturedImage; use Hyde\Framework\Actions\Constructors\FindsNavigationDataForPage; use Hyde\Framework\Actions\Constructors\FindsTitleForPage; use Hyde\Framework\Contracts\FrontMatter\BlogPostSchema; @@ -73,10 +73,10 @@ protected function getAuthor(): ?Author return null; } - protected function getImage(): ?Image + protected function getImage(): ?FeaturedImage { if ($this->matter('image')) { - return Image::make($this->matter('image')); + return FeaturedImage::make($this->matter('image')); } return null; diff --git a/packages/framework/src/Framework/Contracts/FrontMatter/Support/FeaturedImageSchema.php b/packages/framework/src/Framework/Contracts/FrontMatter/Support/FeaturedImageSchema.php index 74383567db5..28ac94ff3d4 100644 --- a/packages/framework/src/Framework/Contracts/FrontMatter/Support/FeaturedImageSchema.php +++ b/packages/framework/src/Framework/Contracts/FrontMatter/Support/FeaturedImageSchema.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Contracts\FrontMatter\Support; /** - * @see \Hyde\Blogging\Models\Image + * @see \Hyde\Blogging\Models\FeaturedImage * @see \Hyde\Framework\Models\Pages\MarkdownPost */ interface FeaturedImageSchema diff --git a/packages/framework/src/Framework/Models/Pages/MarkdownPost.php b/packages/framework/src/Framework/Models/Pages/MarkdownPost.php index 195b07f95d1..dc44b00948c 100644 --- a/packages/framework/src/Framework/Models/Pages/MarkdownPost.php +++ b/packages/framework/src/Framework/Models/Pages/MarkdownPost.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Models\Pages; use Hyde\Blogging\Models\Author; -use Hyde\Blogging\Models\Image; +use Hyde\Blogging\Models\FeaturedImage; use Hyde\Foundation\PageCollection; use Hyde\Framework\Concerns\BaseMarkdownPage; use Hyde\Framework\Contracts\FrontMatter\BlogPostSchema; @@ -30,7 +30,7 @@ class MarkdownPost extends BaseMarkdownPage implements BlogPostSchema public ?string $category = null; public ?DateString $date = null; public ?Author $author = null; - public ?Image $image = null; + public ?FeaturedImage $image = null; /** @return \Hyde\Foundation\PageCollection<\Hyde\Framework\Models\Pages\MarkdownPost> */ public static function getLatestPosts(): PageCollection diff --git a/packages/framework/tests/Feature/FindsContentLengthForImageObjectTest.php b/packages/framework/tests/Feature/FindsContentLengthForImageObjectTest.php index 8afd87eb488..713e010fc77 100644 --- a/packages/framework/tests/Feature/FindsContentLengthForImageObjectTest.php +++ b/packages/framework/tests/Feature/FindsContentLengthForImageObjectTest.php @@ -4,7 +4,7 @@ namespace Hyde\Framework\Testing\Feature; -use Hyde\Blogging\Models\Image; +use Hyde\Blogging\Models\FeaturedImage; use Hyde\Testing\TestCase; use Illuminate\Support\Facades\Http; @@ -16,18 +16,18 @@ class FindsContentLengthForImageObjectTest extends TestCase /** * Unit test for the shorthand. Logic is tested in the rest of the case. * - * @covers \Hyde\Blogging\Models\Image::getContentLength + * @covers \Hyde\Blogging\Models\FeaturedImage::getContentLength */ public function test_image_helper_shorthand_returns_content_length() { $this->assertIsInt( - (new Image(['path' => 'foo']))->getContentLength() + (new FeaturedImage(['path' => 'foo']))->getContentLength() ); } public function test_it_can_find_the_content_length_for_a_local_image_stored_in_the_media_directory() { - $image = new Image(); + $image = new FeaturedImage(); $image->path = '_media/image.jpg'; file_put_contents($image->path, '16bytelongstring'); @@ -46,7 +46,7 @@ public function test_it_can_find_the_content_length_for_a_remote_image() ]); }); - $image = new Image(); + $image = new FeaturedImage(); $image->url = 'https://hyde.test/static/image.png'; $this->assertEquals( @@ -56,7 +56,7 @@ public function test_it_can_find_the_content_length_for_a_remote_image() public function test_it_returns_0_if_local_image_is_missing() { - $image = new Image(); + $image = new FeaturedImage(); $image->path = '_media/image.jpg'; $this->assertEquals( @@ -70,7 +70,7 @@ public function test_it_returns_0_if_remote_image_is_missing() return Http::response(null, 404); }); - $image = new Image(); + $image = new FeaturedImage(); $image->url = 'https://hyde.test/static/image.png'; $this->assertEquals( diff --git a/packages/framework/tests/Feature/ImageModelTest.php b/packages/framework/tests/Feature/ImageModelTest.php index 87c92d9e273..d38c59f0dc0 100644 --- a/packages/framework/tests/Feature/ImageModelTest.php +++ b/packages/framework/tests/Feature/ImageModelTest.php @@ -4,46 +4,46 @@ namespace Hyde\Framework\Testing\Feature; -use Hyde\Blogging\Models\Image; +use Hyde\Blogging\Models\FeaturedImage; use Hyde\Testing\TestCase; /** - * @covers \Hyde\Blogging\Models\Image + * @covers \Hyde\Blogging\Models\FeaturedImage */ class ImageModelTest extends TestCase { public function test_can_construct_new_image() { - $image = new Image(); - $this->assertInstanceOf(Image::class, $image); + $image = new FeaturedImage(); + $this->assertInstanceOf(FeaturedImage::class, $image); } public function test_make_can_create_an_image_based_on_string() { - $image = Image::make('foo'); - $this->assertInstanceOf(Image::class, $image); + $image = FeaturedImage::make('foo'); + $this->assertInstanceOf(FeaturedImage::class, $image); $this->assertEquals('foo', $image->path); } public function test_make_can_create_an_image_based_on_array() { - $image = Image::make([ + $image = FeaturedImage::make([ 'path' => 'foo', 'title' => 'bar', ]); - $this->assertInstanceOf(Image::class, $image); + $this->assertInstanceOf(FeaturedImage::class, $image); $this->assertEquals('foo', $image->path); $this->assertEquals('bar', $image->title); } public function test_from_source_automatically_assigns_proper_property_depending_on_if_the_string_is_remote() { - $image = Image::fromSource('https://example.com/image.jpg'); - $this->assertInstanceOf(Image::class, $image); + $image = FeaturedImage::fromSource('https://example.com/image.jpg'); + $this->assertInstanceOf(FeaturedImage::class, $image); $this->assertEquals('https://example.com/image.jpg', $image->url); - $image = Image::fromSource('image.jpg'); - $this->assertInstanceOf(Image::class, $image); + $image = FeaturedImage::fromSource('image.jpg'); + $this->assertInstanceOf(FeaturedImage::class, $image); $this->assertEquals('image.jpg', $image->path); } @@ -53,10 +53,10 @@ public function test_array_data_can_be_used_to_initialize_properties_in_construc 'path' => 'image.jpg', 'url' => 'https://example.com/image.jpg', 'description' => 'This is an image', - 'title' => 'Image Title', + 'title' => 'FeaturedImage Title', ]; - $image = new Image($data); + $image = new FeaturedImage($data); $this->assertEquals($data['path'], $image->path); $this->assertEquals($data['url'], $image->url); @@ -66,7 +66,7 @@ public function test_array_data_can_be_used_to_initialize_properties_in_construc public function test_get_source_method_returns_url_when_both_url_and_path_is_set() { - $image = new Image(); + $image = new FeaturedImage(); $image->url = 'https://example.com/image.jpg'; $image->path = 'image.jpg'; @@ -75,7 +75,7 @@ public function test_get_source_method_returns_url_when_both_url_and_path_is_set public function test_get_source_method_returns_path_when_only_path_is_set() { - $image = new Image(); + $image = new FeaturedImage(); $image->path = 'image.jpg'; $this->assertEquals('image.jpg', $image->getSource()); @@ -83,29 +83,29 @@ public function test_get_source_method_returns_path_when_only_path_is_set() public function test_get_source_method_throws_exception_when_no_source_is_set() { - $image = new Image(); + $image = new FeaturedImage(); - $this->expectExceptionMessage('Attempting to get source from Image that has no source.'); + $this->expectExceptionMessage('Attempting to get source from FeaturedImage that has no source.'); $image->getSource(); } public function test_get_source_method_does_not_throw_exception_when_path_is_set() { - $image = new Image(); + $image = new FeaturedImage(); $image->path = 'image.jpg'; $this->assertEquals('image.jpg', $image->getSource()); } public function test_get_source_method_does_not_throw_exception_when_url_is_set() { - $image = new Image(); + $image = new FeaturedImage(); $image->url = 'https://example.com/image.jpg'; $this->assertEquals('https://example.com/image.jpg', $image->getSource()); } public function test_get_image_author_attribution_string_method() { - $image = new Image([ + $image = new FeaturedImage([ 'author' => 'John Doe', 'credit' => 'https://example.com/', ]); @@ -116,68 +116,68 @@ public function test_get_image_author_attribution_string_method() $this->assertStringContainsString('John Doe', $string); $this->assertStringContainsString(' 'John Doe']); + $image = new FeaturedImage(['author' => 'John Doe']); $string = $image->getImageAuthorAttributionString(); $this->assertStringContainsString('itemprop="creator"', $string); $this->assertStringContainsString('itemtype="http://schema.org/Person"', $string); $this->assertStringContainsString('John Doe', $string); - $image = new Image(); + $image = new FeaturedImage(); $this->assertNull($image->getImageAuthorAttributionString()); } public function test_get_copyright_string() { - $image = new Image(['copyright' => 'foo']); + $image = new FeaturedImage(['copyright' => 'foo']); $this->assertEquals('foo', $image->getCopyrightString()); - $image = new Image(); + $image = new FeaturedImage(); $this->assertNull($image->getCopyrightString()); } public function test_get_license_string() { - $image = new Image([ + $image = new FeaturedImage([ 'license' => 'foo', 'licenseUrl' => 'https://example.com/bar.html', ]); $this->assertEquals('foo', $image->getLicenseString()); - $image = new Image(['license' => 'foo']); + $image = new FeaturedImage(['license' => 'foo']); $this->assertEquals('foo', $image->getLicenseString()); - $image = new Image(['licenseUrl' => 'https://example.com/bar.html']); + $image = new FeaturedImage(['licenseUrl' => 'https://example.com/bar.html']); $this->assertNull($image->getLicenseString()); - $image = new Image(); + $image = new FeaturedImage(); $this->assertNull($image->getLicenseString()); } public function test_get_fluent_attribution_method() { - $image = new Image(['author' => 'John Doe']); + $image = new FeaturedImage(['author' => 'John Doe']); $string = $image->getFluentAttribution(); - $this->assertStringContainsString('Image by ', $string); + $this->assertStringContainsString('FeaturedImage by ', $string); - $image = new Image(['copyright' => 'foo']); + $image = new FeaturedImage(['copyright' => 'foo']); $string = $image->getFluentAttribution(); $this->assertStringContainsString('foo', $string); - $image = new Image(['license' => 'foo']); + $image = new FeaturedImage(['license' => 'foo']); $string = $image->getFluentAttribution(); $this->assertStringContainsString('License foo', $string); - $image = new Image(); + $image = new FeaturedImage(); $this->assertEquals('', $image->getFluentAttribution()); } public function test_get_metadata_array() { - $image = new Image([ + $image = new FeaturedImage([ 'description' => 'foo', 'title' => 'bar', 'path' => 'image.jpg', @@ -193,7 +193,7 @@ public function test_get_metadata_array() public function test_get_metadata_array_with_remote_url() { - $image = new Image([ + $image = new FeaturedImage([ 'url' => 'https://foo/bar', ]); @@ -205,7 +205,7 @@ public function test_get_metadata_array_with_remote_url() public function test_get_metadata_array_with_local_path() { - $image = new Image([ + $image = new FeaturedImage([ 'path' => 'foo.png', ]); @@ -218,7 +218,7 @@ public function test_get_metadata_array_with_local_path() public function test_get_metadata_array_with_local_path_when_on_nested_page() { $this->mockCurrentPage('foo/bar'); - $image = new Image([ + $image = new FeaturedImage([ 'path' => 'foo.png', ]); @@ -230,7 +230,7 @@ public function test_get_metadata_array_with_local_path_when_on_nested_page() public function test_get_link_resolves_remote_paths() { - $image = new Image([ + $image = new FeaturedImage([ 'url' => 'https://example.com/image.jpg', ]); @@ -239,7 +239,7 @@ public function test_get_link_resolves_remote_paths() public function test_get_link_resolves_local_paths() { - $image = new Image([ + $image = new FeaturedImage([ 'path' => 'image.jpg', ]); @@ -248,7 +248,7 @@ public function test_get_link_resolves_local_paths() public function test_get_link_resolves_local_paths_when_on_nested_page() { - $image = new Image([ + $image = new FeaturedImage([ 'path' => 'image.jpg', ]); @@ -258,26 +258,26 @@ public function test_get_link_resolves_local_paths_when_on_nested_page() public function test_local_path_is_normalized_to_the_media_directory() { - $this->assertEquals('image.jpg', (new Image([ + $this->assertEquals('image.jpg', (new FeaturedImage([ 'path' => 'image.jpg', ]))->path); - $this->assertEquals('image.jpg', (new Image([ + $this->assertEquals('image.jpg', (new FeaturedImage([ 'path' => '_media/image.jpg', ]))->path); - $this->assertEquals('image.jpg', (new Image([ + $this->assertEquals('image.jpg', (new FeaturedImage([ 'path' => 'media/image.jpg', ]))->path); } public function test_to_string_returns_the_image_source() { - $this->assertEquals('https://example.com/image.jpg', (string) (new Image([ + $this->assertEquals('https://example.com/image.jpg', (string) (new FeaturedImage([ 'url' => 'https://example.com/image.jpg', ]))); - $this->assertEquals('media/image.jpg', (string) (new Image([ + $this->assertEquals('media/image.jpg', (string) (new FeaturedImage([ 'path' => 'image.jpg', ]))); } @@ -285,7 +285,7 @@ public function test_to_string_returns_the_image_source() public function test_to_string_returns_the_image_source_for_nested_pages() { $this->mockCurrentPage('foo/bar'); - $this->assertEquals('../media/image.jpg', (string) (new Image([ + $this->assertEquals('../media/image.jpg', (string) (new FeaturedImage([ 'path' => 'image.jpg', ]))); } diff --git a/packages/framework/tests/Feature/MarkdownPostTest.php b/packages/framework/tests/Feature/MarkdownPostTest.php index a5fbdb3160d..18324092eeb 100644 --- a/packages/framework/tests/Feature/MarkdownPostTest.php +++ b/packages/framework/tests/Feature/MarkdownPostTest.php @@ -5,7 +5,7 @@ namespace Hyde\Framework\Testing\Feature; use Hyde\Blogging\Models\Author; -use Hyde\Blogging\Models\Image; +use Hyde\Blogging\Models\FeaturedImage; use Hyde\Framework\Models\Markdown\FrontMatter; use Hyde\Framework\Models\Pages\MarkdownPost; use Hyde\Framework\Models\Support\DateString; @@ -51,7 +51,7 @@ public function test_constructor_can_create_a_new_image_instance_from_a_string() 'image' => 'https://example.com/image.jpg', ])); - $this->assertInstanceOf(Image::class, $post->image); + $this->assertInstanceOf(FeaturedImage::class, $post->image); $this->assertEquals('https://example.com/image.jpg', $post->image->url); } @@ -63,7 +63,7 @@ public function test_constructor_can_create_a_new_image_instance_from_an_array() ], ])); - $this->assertInstanceOf(Image::class, $post->image); + $this->assertInstanceOf(FeaturedImage::class, $post->image); $this->assertEquals('https://example.com/image.jpg', $post->image->url); } @@ -87,7 +87,7 @@ public function test_featured_image_can_be_constructed_returns_image_object_with { $page = MarkdownPost::make(matter: ['image' => 'foo.png']); $image = $page->image; - $this->assertInstanceOf(Image::class, $image); + $this->assertInstanceOf(FeaturedImage::class, $image); $this->assertEquals('foo.png', $image->path); } @@ -95,7 +95,7 @@ public function test_featured_image_can_be_constructed_returns_image_object_with { $page = MarkdownPost::make(matter: ['image' => 'https://example.com/foo.png']); $image = $page->image; - $this->assertInstanceOf(Image::class, $image); + $this->assertInstanceOf(FeaturedImage::class, $image); $this->assertEquals('https://example.com/foo.png', $image->url); } @@ -103,7 +103,7 @@ public function test_featured_image_can_be_constructed_returns_image_object_with { $page = MarkdownPost::make(matter: ['image' => ['path' => 'foo.png', 'title' => 'bar']]); $image = $page->image; - $this->assertInstanceOf(Image::class, $image); + $this->assertInstanceOf(FeaturedImage::class, $image); $this->assertEquals('foo.png', $image->path); $this->assertEquals('bar', $image->title); } From 069404fd39a6df3e59602464feec160308d44a4c Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 22:01:54 +0200 Subject: [PATCH 059/768] Update ImageModelTest.php --- packages/framework/tests/Feature/ImageModelTest.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/framework/tests/Feature/ImageModelTest.php b/packages/framework/tests/Feature/ImageModelTest.php index d38c59f0dc0..adf0b08d114 100644 --- a/packages/framework/tests/Feature/ImageModelTest.php +++ b/packages/framework/tests/Feature/ImageModelTest.php @@ -85,7 +85,7 @@ public function test_get_source_method_throws_exception_when_no_source_is_set() { $image = new FeaturedImage(); - $this->expectExceptionMessage('Attempting to get source from FeaturedImage that has no source.'); + $this->expectExceptionMessage('Attempting to get source from Image that has no source.'); $image->getSource(); } @@ -159,7 +159,7 @@ public function test_get_fluent_attribution_method() $image = new FeaturedImage(['author' => 'John Doe']); $string = $image->getFluentAttribution(); - $this->assertStringContainsString('FeaturedImage by ', $string); + $this->assertStringContainsString('Image by ', $string); $image = new FeaturedImage(['copyright' => 'foo']); $string = $image->getFluentAttribution(); From a443eb61c76953eb6b51d8e73e504a6cc56ab64b Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 26 Oct 2022 22:06:58 +0200 Subject: [PATCH 060/768] Move navigation models to new Navigation namespace --- .../resources/views/components/docs/sidebar.blade.php | 2 +- .../framework/resources/views/layouts/navigation.blade.php | 2 +- .../Actions/Constructors/FindsNavigationDataForPage.php | 2 +- packages/framework/src/Framework/Concerns/HydePage.php | 2 +- .../Contracts/FrontMatter/Support/NavigationSchema.php | 2 +- .../Models => }/Navigation/DocumentationSidebar.php | 2 +- .../src/{Framework/Models => }/Navigation/NavItem.php | 2 +- .../{Framework/Models => }/Navigation/NavigationData.php | 2 +- .../{Framework/Models => }/Navigation/NavigationMenu.php | 2 +- packages/framework/tests/Feature/NavigationDataTest.php | 4 ++-- packages/framework/tests/Feature/NavigationMenuTest.php | 6 +++--- .../tests/Feature/Services/DocumentationSidebarTest.php | 6 +++--- packages/framework/tests/Unit/NavItemTest.php | 4 ++-- .../framework/tests/Unit/Views/NavigationBrandViewTest.php | 2 +- .../framework/tests/Unit/Views/NavigationLinkViewTest.php | 2 +- 15 files changed, 21 insertions(+), 21 deletions(-) rename packages/framework/src/{Framework/Models => }/Navigation/DocumentationSidebar.php (97%) rename packages/framework/src/{Framework/Models => }/Navigation/NavItem.php (98%) rename packages/framework/src/{Framework/Models => }/Navigation/NavigationData.php (97%) rename packages/framework/src/{Framework/Models => }/Navigation/NavigationMenu.php (97%) diff --git a/packages/framework/resources/views/components/docs/sidebar.blade.php b/packages/framework/resources/views/components/docs/sidebar.blade.php index 3ce61288b01..76cc33e872e 100644 --- a/packages/framework/resources/views/components/docs/sidebar.blade.php +++ b/packages/framework/resources/views/components/docs/sidebar.blade.php @@ -6,7 +6,7 @@ class="bg-gray-100 dark:bg-gray-800 dark:text-gray-200 h-screen w-64 fixed z-30