Skip to content

Commit

Permalink
improve HTML
Browse files Browse the repository at this point in the history
  • Loading branch information
zapashcanon committed Oct 30, 2020
1 parent cac711d commit 2693dc7
Show file tree
Hide file tree
Showing 10 changed files with 82 additions and 56 deletions.
13 changes: 9 additions & 4 deletions .drom
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

# hash of toml configuration files
# used for generation of all files
87605b027fd49a603c180278d2a3f137:.
8a49b26972b07a5b0d2d8961a4787779:.
# end context for .

# begin context for .github/workflows/doc-deploy.yml
Expand Down Expand Up @@ -55,14 +55,19 @@ dd70c20d38acc09bf50f4d4050ce3ca2:Makefile
b091dd96e8b553dd7a7df285279d7d9e:README.md
# end context for README.md

# begin context for docs/favicon.png
# file docs/favicon.png
7ea9be52d489cbe8c03b43ecf6b2650f:docs/favicon.png
# end context for docs/favicon.png

# begin context for docs/index.html
# file docs/index.html
c352caa74812a7a09cdd3e52031d6033:docs/index.html
48c65576fa1eeec6f13a8342053b06dc:docs/index.html
# end context for docs/index.html

# begin context for docs/style.css
# file docs/style.css
42e9a35df53b46338c20e484a27eab26:docs/style.css
0085152add896d7bab7b1a744d2a9af7:docs/style.css
# end context for docs/style.css

# begin context for drom-opam.deps
Expand Down Expand Up @@ -147,7 +152,7 @@ c46773d55a9a80e19cd0e807cb36262e:src/drom/main.ml

# begin context for src/drom_lib/dune
# file src/drom_lib/dune
6b6b07c42052f0074a1cf279b8e0773e:src/drom_lib/dune
3be3987b8c16fe3e90df7ffb5a20e96e:src/drom_lib/dune
# end context for src/drom_lib/dune

# begin context for src/drom_lib/index.mld
Expand Down
Binary file added docs/favicon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
49 changes: 24 additions & 25 deletions docs/index.html
Original file line number Diff line number Diff line change
@@ -1,37 +1,36 @@

<html lang="en-US">
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta charset="utf-8">
<title>drom</title>
<link rel="stylesheet" href="style.css?v=5d7320a9a8657af61f899c84ec3bdcb7"/>
<link rel="icon" type="image/png" sizes="804x804" href="favicon.png" />
</head>
<body>
<div class="content">
<div class="header">
<h1>drom</h1>
<p>The drom tool is a wrapper over opam/dune in an attempt to provide a cargo-like&#10;user experience. It can be used to create full OCaml projects with&#10;sphinx and odoc documentation. It has specific knowledge of Github and&#10;will generate files for Github Actions CI and Github pages.&#10;</p>
</div>



<div class="section">
<ul>

<div class="content">
<div class="header">
<h1>drom</h1>
<p>The drom tool is a wrapper over opam/dune in an attempt to provide a cargo-like&#10;user experience. It can be used to create full OCaml projects with&#10;sphinx and odoc documentation. It has specific knowledge of Github and&#10;will generate files for Github Actions CI and Github pages.&#10;</p>
</div>
<div class="section">
<ul>

<li><a href="https://github.com/ocamlpro/drom">Project on Github</a></li>

<li><a href="https://ocamlpro.github.io/drom/sphinx">General Documentation</a></li>

<li><a href="https://ocamlpro.github.io/drom/doc">API Documentation</a></li>

<li><a href="https://github.com/ocamlpro/drom/issues">Bug reports</a></li>
</ul>
<p>Authors:</p>
<ul> <li><p>Fabrice Le Fessant <fabrice.le_fessant@origin-labs.com></p></li></ul>
</div>
<div class="trailer">
<hr/>
<p>Copyright (c) OCamlPro SAS & Origin Labs SAS</p>
</div>
</div>
</ul>
<p>Authors:</p>
<ul> <li><p>Fabrice Le Fessant &lt;fabrice.le_fessant&commat;origin-labs.com&gt;</p></li></ul>
</div>
<div class="trailer">
<hr/>
<p>Copyright © OCamlPro SAS & Origin Labs SAS</p>
</div>
</div>
</body>
</html>
9 changes: 8 additions & 1 deletion docs/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,12 @@ body {
margin-left: 100px;
margin-top: 100px;
font-family: sans-serif;
}
}
a:link{
color:#5bf
}
a:visited{
color:#55f
}


1 change: 1 addition & 0 deletions src/drom_lib/dune
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ skeletons/projects/virtual/test/inline-tests/dune
skeletons/projects/virtual/test/inline-tests/test.ml
skeletons/projects/virtual/docs/index.html
skeletons/projects/virtual/docs/style.css
skeletons/projects/virtual/docs/favicon.png
skeletons/projects/virtual/dot_github/workflows/workflow.yml
skeletons/projects/virtual/dot_github/workflows/doc-deploy.yml
)
Expand Down
7 changes: 7 additions & 0 deletions src/drom_lib/ezHtml.ml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,15 @@
(**************************************************************************)

let buffer b s =
let add = Printf.bprintf b in
for i = 0 to String.length s - 1 do
match s.[i] with
| '&' -> add "&amp;"
| '<' -> add "&lt;"
| '>' -> add "&gt;"
| '\'' -> add "&apos;"
| '\"' -> add "&quot;"
| '@' -> add "&commat;"
| c
when c >= ' ' && c <= '~' && c <> '\\' && c <> '"' && c <> '\n'
&& c <> '\r' && c <> '\t' ->
Expand Down
1 change: 1 addition & 0 deletions src/drom_lib/package.toml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ skeletons/projects/virtual/test/inline-tests/dune
skeletons/projects/virtual/test/inline-tests/test.ml
skeletons/projects/virtual/docs/index.html
skeletons/projects/virtual/docs/style.css
skeletons/projects/virtual/docs/favicon.png
skeletons/projects/virtual/dot_github/workflows/workflow.yml
skeletons/projects/virtual/dot_github/workflows/doc-deploy.yml
)
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
49 changes: 24 additions & 25 deletions src/drom_lib/skeletons/projects/virtual/docs/index.html
Original file line number Diff line number Diff line change
@@ -1,33 +1,32 @@
![skip:docs]
<html lang="en-US">
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta charset="utf-8">
<title>!{name:html}</title>
<link rel="stylesheet" href="style.css?v=!{random}"/>
<link rel="icon" type="image/png" sizes="804x804" href="favicon.png" />
</head>
<body>
<div class="content">
<div class="header">
<h1>!{name:html}</h1>
<p>!{description:html}</p>
</div>



<div class="section">
<ul>
!{li-github}
!{li-doc-gen}
!{li-doc-api}
!{li-bug-reports}
</ul>
<p>Authors:</p>
<ul>!{li-authors}</ul>
</div>
<div class="trailer">
<hr/>
<p>Copyright (c) !{copyright}</p>
</div>
</div>
<div class="content">
<div class="header">
<h1>!{name:html}</h1>
<p>!{description:html}</p>
</div>
<div class="section">
<ul>
!{li-github}
!{li-doc-gen}
!{li-doc-api}
!{li-bug-reports}
</ul>
<p>Authors:</p>
<ul>!{li-authors}</ul>
</div>
<div class="trailer">
<hr/>
<p>Copyright © !{copyright}</p>
</div>
</div>
</body>
</html>
9 changes: 8 additions & 1 deletion src/drom_lib/skeletons/projects/virtual/docs/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,12 @@ body {
margin-left: 100px;
margin-top: 100px;
font-family: sans-serif;
}
}
a:link{
color:#5bf
}
a:visited{
color:#55f
}


0 comments on commit 2693dc7

Please sign in to comment.