{"id":13619753,"url":"https://github.com/LeeReid1/MarkdownToSiteGenerator","last_synced_at":"2025-04-14T16:32:41.749Z","repository":{"id":182987101,"uuid":"574426321","full_name":"LeeReid1/MarkdownToSiteGenerator","owner":"LeeReid1","description":"An example of my code style, for C# 11 and .NET Core 7.0. Written from scratch using test-driven-development. The solution builds a static multiple-HTML-page site from a directory of markdown files, hostable without an application layer. The builder produces pages based on a standard Bootstrap HTML5 style, including a drop-down navigation menu.","archived":false,"fork":false,"pushed_at":"2022-12-29T20:59:34.000Z","size":240,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-08-01T21:41:55.671Z","etag":null,"topics":["csharp","dotnetcore","example-app","example-code","html5","portfolio","test-driven-development"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/LeeReid1.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2022-12-05T09:35:42.000Z","updated_at":"2023-03-19T03:09:07.000Z","dependencies_parsed_at":"2023-07-22T09:42:35.205Z","dependency_job_id":null,"html_url":"https://github.com/LeeReid1/MarkdownToSiteGenerator","commit_stats":null,"previous_names":["leereid1/markdowntositegenerator"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LeeReid1%2FMarkdownToSiteGenerator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LeeReid1%2FMarkdownToSiteGenerator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LeeReid1%2FMarkdownToSiteGenerator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LeeReid1%2FMarkdownToSiteGenerator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/LeeReid1","download_url":"https://codeload.github.com/LeeReid1/MarkdownToSiteGenerator/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":223638215,"owners_count":17177760,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["csharp","dotnetcore","example-app","example-code","html5","portfolio","test-driven-development"],"created_at":"2024-08-01T21:00:48.228Z","updated_at":"2024-11-08T05:32:00.649Z","avatar_url":"https://github.com/LeeReid1.png","language":"C#","funding_links":[],"categories":["C# #"],"sub_categories":[],"readme":"# Markdown-To-Site Generator\r\n\r\n![Build And Test](https://github.com/LeeReid1/MarkdownToSiteGenerator/actions/workflows/dotnet.yml/badge.svg)\r\n\r\nThis solution builds a static multiple-HTML-page site from a directory of markdown files that can be hosted without an application layer. The builder produces pages based on a standard Bootstrap HTML5 style, including a drop-down menu to navigate. Images, JS, and style sheets are placed in separate directories.\r\n\r\nThis solution is largely public as example of my personal code and development style. It is written from scratch in a test-driven-development oriented style, in C# 11 and .NET Core 7.0. \r\n\r\nThe solution is designed to be extensible - parsing documents other than markdown, for example, or producing documents other than HTML. \r\n\r\n## How to Use\r\n\r\nBuild to solution in Visual Studio 17.4.2 or with the .NET Core command line tools. This will provide and executable. You can also build the unit tests.\r\n\r\nCall the executable without arguments to see help documentation. Typically, you would simply call it like so:\r\n\r\n```\r\nMarkDownToSiteGenerator C:\\my\\directory\\with\\markdown_files\\ C:\\my\\html\\output\\directory\\\r\n```\r\n\r\n## Examples\r\n\r\nYou can see an example website in the Example_Input and Example_Output folders.\r\n\r\n## Input Directory Structure\r\n\r\nDirectories can be nested as deep as you would like and will reflect the final site structure. Spaces in paths are converted to hyphens in the HTML site. The output directory must not be within the input directory, and vice versa.\r\n\r\n### Settings\r\n\r\nYou can optionally include a config.ini file in the top directory of your input to change how the site is generated. See the examples folder for relevant settings.\r\n\r\n## Links\r\n\r\n\r\n### Linking between pages\r\n\r\nTo link between pages, link to the title of that file, not its path or destination\r\n```\r\n[the content of the link](title_of_the_that_file)\r\n```\r\n\r\nIf your page title contains spaces, replace them with underscores in the link. For more information on titles, see Metadata in this document.\r\n\r\nLinks written in this way are checked for correctness. An exception is thrown if the page is not found.\r\n\r\nThe html sitemap can be linked to with the reserved title `sitemap` so long as the site map generation is turned on in config.\r\n\r\n### Linking to URLs\r\n\r\nYou can also link directly to urls, which will not be altered, in the normal way. These must begin with `http://`, `https://` or `www.`:\r\n\r\n```\r\n[the content of the link](https://example.com)\r\n```\r\n\r\n\r\n### Home in the Navigation Bar\r\n\r\nThe navigation bar will link to your home page if you include the following in your config.ini file:\r\n\r\n```\r\nsite_name=\u003cthe name of the link text you would like in the navigation bar\u003e\r\nhome_page=\u003ctitle of your home page\u003e (not the path)\r\n```\r\n\r\nSee Metadata in this document to understand the title. If you do not provide the `home_page` but do provide the `site_name` the link will be to `/`.\r\n\r\n\r\n## Metadata\r\n\r\nAdd metadata to MD documents like so (including the blank line):\r\n```\r\ntitle: My page\r\nauthor: Mike Dent\r\n\r\n```\r\n\r\nThese, if any, must appear at the start of the document. All except `title:` will be placed in the HTML head as meta tags. Stick to letters (a-Z) for the keys.\r\n\r\n### Title Tag\r\n\r\nThe title metadata tag is special and used for:\r\n\r\n1. Building link text to that page\r\n1. Linking internally to that page (see Linking Between Pages)\r\n1. Setting `\u003ctitle\u003e` in the html head\r\n\r\nIf you do not provide a title tag, the first H1 is used in its place.\r\n\r\nIt's ok to use spaces in page titles. Take note that to link to pages which has spaces in the name, you should replace the spaces with underscores (see Linking Between Pages).\r\n\r\nDon't use existing filenames such as my-image.jpg or `sitemap` as a title.\r\n\r\n#### Avoid Duplicates\r\nIt is critical that your pages never have identical titles as it makes linking impossible. Duplicate titles will result in an exception.\r\n\r\nPage titles are not case-sensitive. They are also considered duplicates if matching when spaces are replaced with underscores. For example:\r\n\r\n```\r\nmy title == my_title\r\nMyTiTlE == mytitle\r\nMy_TiTlE == my_title\r\n```\r\n\r\n## Style\r\n\r\nBootstrap is automatically included, unless turned off in the config file. Additional CSS files should be placed in the root directory. Any that are found are linked to in all generated html files.\r\n\r\n## Limitations\r\n\r\n* This is not intended to be a complete solution for all use cases and only covers a subset of Markdown syntax. It is readily extensible, though.\r\n* Solution does not support old MacOS line endings (`\\r`)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FLeeReid1%2FMarkdownToSiteGenerator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FLeeReid1%2FMarkdownToSiteGenerator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FLeeReid1%2FMarkdownToSiteGenerator/lists"}