Skip to content

Commit

Permalink
Merge pull request #1393 from jediwhale/master
Browse files Browse the repository at this point in the history
Documentation for publishing HTML #1387
  • Loading branch information
Mike Stockdale authored Sep 27, 2022
2 parents 6ae38b8 + 9bd9ad6 commit 3890e2f
Show file tree
Hide file tree
Showing 3 changed files with 76 additions and 3 deletions.
9 changes: 6 additions & 3 deletions FitNesseRoot/FitNesse/ReleaseNotes/content.txt
Original file line number Diff line number Diff line change
@@ -1,15 +1,18 @@
!2 Latest Release ${FITNESSE_VERSION}
!2 Pending Changes
* Ability to create plugins for new markup syntax. ([[1382][https://github.com/unclebob/fitnesse/pull/1382]])
* Bugfix: Unescaping HTML is done in the correct order. ([[1384][https://github.com/unclebob/fitnesse/issues/1384]])
* Bugfix: Slim decision table shows input cells correctly in test results ([[1388][https://github.com/unclebob/fitnesse/issues/1388]])
* Add new responder to publish a site as static HTML pages ([[1387][https://github.com/unclebob/fitnesse/issues/1387]])

!2 20220815
* Add support for inline [[''!-!img-!''][UserGuide.FitNesseWiki.MarkupLanguageReference.MarkupPicture]] using base64 data url ([[1367][https://github.com/unclebob/fitnesse/pull/1367]])
* Bugfix: render [[''!-!anchor-!''][UserGuide.FitNesseWiki.MarkupLanguageReference.LinksWithinPages]] as valid (non empty) element ([[1366][https://github.com/unclebob/fitnesse/pull/1366]])
* Bugfix: Handle instructions with embedded newlines ([[1363][https://github.com/unclebob/fitnesse/pull/1363]])
* Add new responder to list the variables available on a page ([[1355][https://github.com/unclebob/fitnesse/pull/1355]])
* Bugfix: Search string is not escaped in search page title ([[1360][https://github.com/unclebob/fitnesse/pull/1360]])
* Bugfix: issues with !include and variables in page name ([[1359][https://github.com/unclebob/fitnesse/pull/1359]])
* Performance: improve parser performance for some incomplete wiki syntax ([[1371][https://github.com/unclebob/fitnesse/pull/1371]])
* Ability to create plugins for new markup syntax. ([[1382][https://github.com/unclebob/fitnesse/pull/1382]])
* Bugfix: Unescaping HTML is done in the correct order. ([[1384][https://github.com/unclebob/fitnesse/issues/1384]])
* Bugfix: Slim decision table shows input cells correctly in test results ([[1388][https://github.com/unclebob/fitnesse/issues/1388]])

!2 20220319
* Add new responder to list the Slim instructions suite to aid analysis/debugging ([[1356][https://github.com/unclebob/fitnesse/pull/1356]])
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
To publish a site, use the URL: ''!-http://MySite:MyPort?publish&destination=my/path-!''

The entire site will be written as static HTML files, in a directory structure the same as the page structure.

Two files must be supplied in the ''!-FitNesseRoot/files/fitnesse-!'' directory:

''publishResources.txt'' provides a list of resources to be extracted into ''my/path/files/fitnesse''.

Sample:
{{{css/fitnesse_wiki.css
css/fitnesse_pages.css
bootstrap/css/fitnesse-bootstrap.css
javascript/jquery-3.5.1.min.js
javascript/fitnesse.js
bootstrap/js/bootstrap.js
bootstrap/js/respond.js
images/fitnesse-logo-large.png
images/fitnesse-logo.png
images/fitnesse_architecture.jpg
images/keyboard_shortcuts.png
images/symlinkDiagram.gif
}}}

''publishTemplate.html'' provides a template for the HTML files. This can contain the following tokens that will be replaced with content from each page:
* $title$
* $breadcrumbs$
* $body$
* $footer$
Sample:
{{{<!DOCTYPE html>
<html>
<head>
<title>$title$</title>
<link rel="stylesheet" type="text/css" href="files/fitnesse/css/fitnesse_wiki.css">
<link rel="stylesheet" type="text/css" href="files/fitnesse/css/fitnesse_pages.css">
<link rel="stylesheet" type="text/css" href="files/fitnesse/bootstrap/css/fitnesse-bootstrap.css">
<script src="files/fitnesse/javascript/jquery-3.5.1.min.js" type="text/javascript"></script>
<script src="files/fitnesse/javascript/fitnesse.js" type="text/javascript"></script>
<script src="files/fitnesse/bootstrap/js/bootstrap.js" type="text/javascript"></script>
<script src="files/fitnesse/bootstrap/js/respond.js" type="text/javascript"></script>
</head>
<body class="wikiPage">
<nav class="navbar-fixed-top " role="navigation">
<div class="navbar navbar-default">
<div class="navbar-header">
<a href="FrontPage" class="navbar-brand" ><span>FitNesse</span></a>
</div>
<ul class="nav navbar-nav">
<li><a href="FitNesseFeatures">Features</a></li>
<li><a href="FitNesseDownload">Download</a></li>
<li><a href="PlugIns">Plug-ins</a></li>
<li><a href="FitNesse.UserGuide">User Guide</a></li>
</ul>
</div>
<ol class="breadcrumb">
$breadcrumbs$
</ol>
</nav>
<article>
$body$
</article>
<footer>
$footer$
</footer>
</body>
</html>}}}

Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,8 @@
| | format=xml | Returns an XML report. See: >PageHistoryXml and [[!-RestfulTests-!][<UserGuide.WritingAcceptanceTests.RestfulTests]] |
| properties | | Displays the properties form for the selected page. |
| | format=json | shows the properties in JSON format See >JsonProperties |
| publish | | Publishes the site as a set of static HTML files. See [[!-PublishingHtml-!][>PublishingHtml]]. |
| | destination | The root path where the HTML files will be written. |
| purgeHistory | | Purges old test history files |
| | days | The number of days of history to preserve |
| raw | | returns the raw wiki-text of the selected page |
Expand Down

0 comments on commit 3890e2f

Please sign in to comment.