diff options
-rw-r--r-- | src/static/logo.svg | 62 | ||||
-rw-r--r-- | src/static/styles.css | 133 | ||||
-rw-r--r-- | src/templates/files.html | 311 | ||||
-rw-r--r-- | src/templates/log.html | 83 | ||||
-rw-r--r-- | src/templates/refs.html | 213 |
5 files changed, 802 insertions, 0 deletions
diff --git a/src/static/logo.svg b/src/static/logo.svg new file mode 100644 index 0000000..ce566b2 --- /dev/null +++ b/src/static/logo.svg @@ -0,0 +1,62 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" width="16" height="16"> + <path d="M 0 8 L 1 8 L 1 9 L 0 9 L 0 8 Z" /> + <path d="M 0 13 L 1 13 L 1 14 L 0 14 L 0 13 Z" /> + <path d="M 1 8 L 2 8 L 2 9 L 1 9 L 1 8 Z" /> + <path d="M 1 13 L 2 13 L 2 14 L 1 14 L 1 13 Z" /> + <path d="M 2 8 L 3 8 L 3 9 L 2 9 L 2 8 Z" /> + <path d="M 2 13 L 3 13 L 3 14 L 2 14 L 2 13 Z" /> + <path d="M 3 8 L 4 8 L 4 9 L 3 9 L 3 8 Z" /> + <path d="M 3 13 L 4 13 L 4 14 L 3 14 L 3 13 Z" /> + <path d="M 4 7 L 5 7 L 5 8 L 4 8 L 4 7 Z" /> + <path d="M 4 8 L 5 8 L 5 9 L 4 9 L 4 8 Z" /> + <path d="M 4 13 L 5 13 L 5 14 L 4 14 L 4 13 Z" /> + <path d="M 5 6 L 6 6 L 6 7 L 5 7 L 5 6 Z" /> + <path d="M 5 7 L 6 7 L 6 8 L 5 8 L 5 7 Z" /> + <path d="M 5 13 L 6 13 L 6 14 L 5 14 L 5 13 Z" /> + <path d="M 6 5 L 7 5 L 7 6 L 6 6 L 6 5 Z" /> + <path d="M 6 6 L 7 6 L 7 7 L 6 7 L 6 6 Z" /> + <path d="M 6 14 L 7 14 L 7 15 L 6 15 L 6 14 Z" /> + <path d="M 7 1 L 8 1 L 8 2 L 7 2 L 7 1 Z" /> + <path d="M 7 14 L 8 14 L 8 15 L 7 15 L 7 14 Z" /> + <path d="M 7 15 L 8 15 L 8 16 L 7 16 L 7 15 Z" /> + <path d="M 7 2 L 8 2 L 8 3 L 7 3 L 7 2 Z" /> + <path d="M 7 3 L 8 3 L 8 4 L 7 4 L 7 3 Z" /> + <path d="M 7 4 L 8 4 L 8 5 L 7 5 L 7 4 Z" /> + <path d="M 7 5 L 8 5 L 8 6 L 7 6 L 7 5 Z" /> + <path d="M 8 1 L 9 1 L 9 2 L 8 2 L 8 1 Z" /> + <path d="M 8 15 L 9 15 L 9 16 L 8 16 L 8 15 Z" /> + <path d="M 9 1 L 10 1 L 10 2 L 9 2 L 9 1 Z" /> + <path d="M 9 2 L 10 2 L 10 3 L 9 3 L 9 2 Z" /> + <path d="M 9 6 L 10 6 L 10 7 L 9 7 L 9 6 Z" /> + <path d="M 9 15 L 10 15 L 10 16 L 9 16 L 9 15 Z" /> + <path d="M 10 2 L 11 2 L 11 3 L 10 3 L 10 2 Z" /> + <path d="M 10 3 L 11 3 L 11 4 L 10 4 L 10 3 Z" /> + <path d="M 10 4 L 11 4 L 11 5 L 10 5 L 10 4 Z" /> + <path d="M 10 5 L 11 5 L 11 6 L 10 6 L 10 5 Z" /> + <path d="M 10 6 L 11 6 L 11 7 L 10 7 L 10 6 Z" /> + <path d="M 11 6 L 12 6 L 12 7 L 11 7 L 11 6 Z" /> + <path d="M 11 8 L 12 8 L 12 9 L 11 9 L 11 8 Z" /> + <path d="M 10 15 L 11 15 L 11 16 L 10 16 L 10 15 Z" /> + <path d="M 11 10 L 12 10 L 12 11 L 11 11 L 11 10 Z" /> + <path d="M 11 12 L 12 12 L 12 13 L 11 13 L 11 12 Z" /> + <path d="M 11 14 L 12 14 L 12 15 L 11 15 L 11 14 Z" /> + <path d="M 11 15 L 12 15 L 12 16 L 11 16 L 11 15 Z" /> + <path d="M 12 6 L 13 6 L 13 7 L 12 7 L 12 6 Z" /> + <path d="M 12 8 L 13 8 L 13 9 L 12 9 L 12 8 Z" /> + <path d="M 12 10 L 13 10 L 13 11 L 12 11 L 12 10 Z" /> + <path d="M 12 12 L 13 12 L 13 13 L 12 13 L 12 12 Z" /> + <path d="M 12 14 L 13 14 L 13 15 L 12 15 L 12 14 Z" /> + <path d="M 13 6 L 14 6 L 14 7 L 13 7 L 13 6 Z" /> + <path d="M 13 8 L 14 8 L 14 9 L 13 9 L 13 8 Z" /> + <path d="M 13 10 L 14 10 L 14 11 L 13 11 L 13 10 Z" /> + <path d="M 13 12 L 14 12 L 14 13 L 13 13 L 13 12 Z" /> + <path d="M 13 13 L 14 13 L 14 14 L 13 14 L 13 13 Z" /> + <path d="M 13 14 L 14 14 L 14 15 L 13 15 L 13 14 Z" /> + <path d="M 14 7 L 15 7 L 15 8 L 14 8 L 14 7 Z" /> + <path d="M 14 8 L 15 8 L 15 9 L 14 9 L 14 8 Z" /> + <path d="M 14 9 L 15 9 L 15 10 L 14 10 L 14 9 Z" /> + <path d="M 14 10 L 15 10 L 15 11 L 14 11 L 14 10 Z" /> + <path d="M 14 11 L 15 11 L 15 12 L 14 12 L 14 11 Z" /> + <path d="M 14 12 L 15 12 L 15 13 L 14 13 L 14 12 Z" /> +</svg> diff --git a/src/static/styles.css b/src/static/styles.css new file mode 100644 index 0000000..a1ed48d --- /dev/null +++ b/src/static/styles.css @@ -0,0 +1,133 @@ +:root { + --row-light-gray: #eee; + --row-background-light-gray: #ccc; + --background-light-gray: #999; + font-family: sans-serif; +} + +a { + color: black; + text-decoration: none; +} + +a:hover { + text-decoration: underline; +} + +#horizontal-aligner-of-logo-and-header-items { + display: flex; +} + +#vertical-aligner-of-header-items { + display: flex; + flex-direction: row; +} + +div#vertical-aligner-of-header-items > h2 { + font-weigth: normal; + color: red; +} + +#repository-logo { + width: 5em; + margin: 2em; +} + +hr { + border: none; + height: 5px; + background-color: var(--background-light-gray); +} + +nav ul { + display: flex; + list-style-type: none; + border-bottom: 5px solid var(--background-light-gray); +} + +nav li { + margin-left: 10px; +} + +nav a { + padding-top: 2px; + padding-left: 8px; + padding-right: 8px; +} + +nav .selected-nav-item a { + background-color: var(--background-light-gray); +} + +main { + padding: 2em; +} + +table { + text-align: left; + border: none; + border-collapse: collapse; + width: 100%; +} + +table tr.table-no-highlight-row { + background-color: white; +} + +table tr.table-no-highlight-row:hover { + background-color: white; +} + +table tr:hover { + background-color: var(--row-background-light-gray); +} + +tr:nth-child(odd) { + background-color: white; +} + +tr:nth-child(even) { + background-color: var(--row-light-gray); +} + +footer { + text-align: center; +} + +/* Page log.html */ + +.log-commit-box { + padding: 1em; + background-color: var(--row-light-gray); +} + +.log-head-highlight { + padding: 2px; + background-color: #ff8888; + border: 1px solid; +} + +.log-branch-highlight { + padding: 2px; + background-color: #88ff88; + border: 1px solid; +} + +.log-tag-highlight { + padding: 2px; + background-color: #ffff88; + border: 1px solid; +} + + +/* Page tree.html */ + +table#files-table td:nth-child(1) { + width: 10%; + padding-right: 2em; +} + +.files-row-item-directory { + color: blue; + font-weight: bold; +} diff --git a/src/templates/files.html b/src/templates/files.html new file mode 100644 index 0000000..cba4c0b --- /dev/null +++ b/src/templates/files.html @@ -0,0 +1,311 @@ +<!DOCTYPE html> +<html lang="en"> + <head> + <meta charset="UTF-8" /> + <meta name="viewport" content="width=device-width, initial-scale=1" /> + + <link rel="icon" type="image/svg+xml" href="$PREFIX/static/logo.svg" /> + <link rel="stylesheet" type="text/css" href="$PREFIX/static/styles.css" /> + <link rel="alternate" type="application/atom+xml" href="$PREFIX/commits.xml" title="$PROJECT_NAME - commit feed" hreflang="en" /> + <link rel="alternate" type="application/atom+xml" href="$PREFIX/tags.xml" title="$PROJECT_NAME - tags feed" hreflang="en" /> + + <title>$PROJECT_NAME - $PROJECT_DESCRIPTION</title> + + <meta property="og:site_name" content="Repository for $PROJECT_NAME" /> + <meta property="og:locale" content="en" /> + <meta property="og:title" content="$PROJECT_NAME" /> + <meta property="og:description" content="$PROJECT_DESCRIPTION" /> + <meta name="description" content="$PROJECT_DESCRIPTION" /> + </head> + <body> + <header> + <div id="horizontal-aligner-of-logo-and-header-items"> + <img id="repository-logo" src="$PREFIX/static/logo.svg" alt="Logo image of the repository" /> + <div id="vertical-aligner-of-project-name-and-description"> + <h1> + $PROJECT_NAME + </h1> + <h2> + $PROJECT_DESCRIPTION + </h2> + <code> + git clone $PROJECT_CLONE_URL + </code> + </div> + </div> + <nav> + <ul> + <li class="selected-nav-item"> + <a href="$PREFIX/files.html"> + files + </a> + </li> + <li> + <a href="$PREFIX/files.html"> + log + </a> + </li> + <li> + <a href="$PREFIX/files.html"> + refs + </a> + </li> + </ul> + </nav> + </header> + <main> + <table id="files-table"> + <tr class="table-no-highlight-row"> + <th> + Mode + </th> + <th> + Name + </th> + <th> + Size + </th> + </tr> + <tr> + <td> + <code> + -rw-r--r-- + </code> + </td> + <td> + <a href="$PREFIX/tree/main/$FILE.html"> + <code> + .gitignore + </code> + </a> + </td> + <td> + <code> + 123B + </code> + </td> + </tr> + <tr> + <td> + <code> + -rw-r--r-- + </code> + </td> + <td> + <a href="$PREFIX/tree/main/$FILE.html"> + <code> + CHAGELOG.md + </code> + </a> + </td> + <td> + <code> + 123B + </code> + </td> + </tr> + <tr> + <td> + <code> + -rw-r--r-- + </code> + </td> + <td> + <a href="$PREFIX/tree/main/$FILE.html"> + <code> + COPYING + </code> + </a> + </td> + <td> + <code> + 123B + </code> + </td> + </tr> + <tr> + <td> + <code> + -rw-r--r-- + </code> + </td> + <td> + <a href="$PREFIX/tree/main/$FILE.html"> + <code> + Makefile + </code> + </a> + </td> + <td> + <code> + 123B + </code> + </td> + </tr> + <tr> + <td> + <code> + -rw-r--r-- + </code> + </td> + <td> + <a href="$PREFIX/tree/main/$FILE.html"> + <code> + README.md + </code> + </a> + </td> + <td> + <code> + 123B + </code> + </td> + </tr> + <tr> + <td> + <code> + -rw-r--r-- + </code> + </td> + <td> + <a href="$PREFIX/tree/main/$FILE.html"> + <code> + TODOs.md + </code> + </a> + </td> + <td> + <code> + 123B + </code> + </td> + </tr> + <tr> + <td> + <code> + d--------- + </code> + </td> + <td> + <a href="$PREFIX/tree/main/$FILE.html" class="files-row-item-directory"> + <code> + aux/ + </code> + </a> + </td> + <td> + <code> + 123B + </code> + </td> + </tr> + <tr> + <td> + <code> + -rw-r--r-- + </code> + </td> + <td> + <a href="$PREFIX/tree/main/$FILE.html"> + <code> + description + </code> + </a> + </td> + <td> + <code> + 123B + </code> + </td> + </tr> + <tr> + <td> + <code> + d--------- + </code> + </td> + <td> + <a href="$PREFIX/tree/main/$FILE.html" class="files-row-item-directory"> + <code> + doc/ + </code> + </a> + </td> + <td> + <code> + 123B + </code> + </td> + </tr> + <tr> + <td> + <code> + -rw-r--r-- + </code> + </td> + <td> + <a href="$PREFIX/tree/main/$FILE.html"> + <code> + long-description + </code> + </a> + </td> + <td> + <code> + 123B + </code> + </td> + </tr> + <tr> + <td> + <code> + d--------- + </code> + </td> + <td> + <a href="$PREFIX/tree/main/$FILE.html" class="files-row-item-directory"> + <code> + src/ + </code> + </a> + </td> + <td> + <code> + 123B + </code> + </td> + </tr> + <tr> + <td> + <code> + d--------- + </code> + </td> + <td> + <a href="$PREFIX/tree/main/$FILE.html" class="files-row-item-directory"> + <code> + tests/ + </code> + </a> + </td> + <td> + <code> + 123B + </code> + </td> + </tr> + </table> + <hr /> + <section> + <h1>README</h1> + <p>This does something.</p> + </section> + </main> + <footer> + <hr /> + <p> + Generated by gistatic $VERSION at $NOW + </p> + </footer> + </body> +</html> diff --git a/src/templates/log.html b/src/templates/log.html new file mode 100644 index 0000000..decd2f9 --- /dev/null +++ b/src/templates/log.html @@ -0,0 +1,83 @@ +<!DOCTYPE html> +<html lang="en"> + <head> + <meta charset="UTF-8" /> + <meta name="viewport" content="width=device-width, initial-scale=1" /> + + <link rel="icon" type="image/svg+xml" href="$PREFIX/static/logo.svg" /> + <link rel="stylesheet" type="text/css" href="$PREFIX/static/styles.css" /> + <link rel="alternate" type="application/atom+xml" href="$PREFIX/commits.xml" title="$PROJECT_NAME - commit feed" hreflang="en" /> + <link rel="alternate" type="application/atom+xml" href="$PREFIX/tags.xml" title="$PROJECT_NAME - tags feed" hreflang="en" /> + + <title>$PROJECT_NAME - $PROJECT_DESCRIPTION</title> + + <meta property="og:site_name" content="Repository for $PROJECT_NAME" /> + <meta property="og:locale" content="en" /> + <meta property="og:title" content="$PROJECT_NAME" /> + <meta property="og:description" content="$PROJECT_DESCRIPTION" /> + <meta name="description" content="$PROJECT_DESCRIPTION" /> + </head> + <body> + <header> + <div id="horizontal-aligner-of-logo-and-header-items"> + <img id="repository-logo" src="$PREFIX/static/logo.svg" alt="Logo image of the repository" /> + <div id="vertical-aligner-of-project-name-and-description"> + <h1> + $PROJECT_NAME + </h1> + <h2> + $PROJECT_DESCRIPTION + </h2> + <code> + git clone $PROJECT_CLONE_URL + </code> + </div> + </div> + <nav> + <ul> + <li> + <a href="$PREFIX/"> + files + </a> + </li> + <li class="selected-nav-item"> + <a href="$PREFIX/log"> + log + </a> + </li> + <li> + <a href="$PREFIX/refs/"> + refs + </a> + </li> + </ul> + </nav> + </header> + <main> + <div class="log-commit-box"> + <p> + <a href="$PREFIX/commits/$SHA.html">739a235c</a> + | + EuAndreh + <a href="$PREFIX/commits/SHA.html" class="log-head-highlight">HEAD</a> + <a href="$PREFIX/tree/main.html" class="log-branch-highlight">main</a> + <a href="$PREFIX/tags/v0.2.1.html" class="log-tag-highlight">v0.2.1</a> + </p> + <pre>Only display filename if it's set + +This prevents None from showing up in different places when pastes are +submitted through the API.</pre> + <pre>Notes: + See CI logs with: + git notes --ref=refs/notes/ci-logs show 92bfa3c5f06558cebcfa06bf78159e76254e07fd + git notes --ref=refs/notes/ci-data show 92bfa3c5f06558cebcfa06bf78159e76254e07fd</pre> + </div> + </main> + <footer> + <hr /> + <p> + Generated by gistatic $VERSION at $NOW + </p> + </footer> + </body> +</html> diff --git a/src/templates/refs.html b/src/templates/refs.html new file mode 100644 index 0000000..2257f70 --- /dev/null +++ b/src/templates/refs.html @@ -0,0 +1,213 @@ +<!DOCTYPE html> +<html lang="en"> + <head> + <meta charset="UTF-8" /> + <meta name="viewport" content="width=device-width, initial-scale=1" /> + + <link rel="icon" type="image/svg+xml" href="$PREFIX/static/logo.svg" /> + <link rel="stylesheet" type="text/css" href="$PREFIX/static/styles.css" /> + <link rel="alternate" type="application/atom+xml" href="$PREFIX/commits.xml" title="$PROJECT_NAME - commit feed" hreflang="en" /> + <link rel="alternate" type="application/atom+xml" href="$PREFIX/tags.xml" title="$PROJECT_NAME - tags feed" hreflang="en" /> + + <title>$PROJECT_NAME - $PROJECT_DESCRIPTION</title> + + <meta property="og:site_name" content="Repository for $PROJECT_NAME" /> + <meta property="og:locale" content="en" /> + <meta property="og:title" content="$PROJECT_NAME" /> + <meta property="og:description" content="$PROJECT_DESCRIPTION" /> + <meta name="description" content="$PROJECT_DESCRIPTION" /> + </head> + <body> + <header> + <div id="horizontal-aligner-of-logo-and-header-items"> + <img id="repository-logo" src="$PREFIX/static/logo.svg" alt="Logo image of the repository" /> + <div id="vertical-aligner-of-project-name-and-description"> + <h1> + $PROJECT_NAME + </h1> + <h2> + $PROJECT_DESCRIPTION + </h2> + <code> + git clone $PROJECT_CLONE_URL + </code> + </div> + </div> + <nav> + <ul> + <li> + <a href="$PREFIX/"> + files + </a> + </li> + <li> + <a href="$PREFIX/log/"> + log + </a> + </li> + <li class="selected-nav-item"> + <a href="$PREFIX/refs/"> + refs + </a> + </li> + </ul> + </nav> + </header> + <main> + <table> + <tr class="table-no-highlight-row"> + <th> + Branch + </th> + <th> + Commit message + </th> + <th> + Author + </th> + <th> + Date + </th> + </tr> + <tr> + <td> + <a href="$PREFIX/log/main.html"> + <code> + main + </code> + </a> + </td> + <td> + <a href="$PREFIX/commits/$SHA.html"> + aux/workflow/public.sh: Mark as executable + </a> + </td> + <td> + EuAndreh + </td> + <td> + 2021-01-02 15:26 -3 + </td> + </tr> + <tr class="table-no-highlight-row"> + <td colspan="4"> </td> + </tr> + <tr class="table-no-highlight-row"> + <th> + Tag + </th> + <th> + Download + </th> + <th> + Author + </th> + <th> + Date + </th> + </tr> + <tr> + <td> + <a href="$PREFIX/tags/v0.2.1.html"> + v0.2.1 + </a> + </td> + <td> + <a href="$PREFIX/snapshots/remembering-0.2.1.tar.xz"> + remembering-0.2.1.tar.xz + </a> + (<a href="$PREFIX/snapshots/remembering-0.2.1.tar.xz.asc">sig</a>) + </td> + <td> + EuAndreh + </td> + <td> + 2021-01-05 15:26 -3 + </td> + </tr> + <tr> + <td> + <a href="$PREFIX/tags/v0.2.0.html"> + v0.2.0 + </a> + </td> + <td> + <a href="$PREFIX/snapshots/remembering-0.2.0.tar.xz"> + remembering-0.2.0.tar.xz + </a> + (<a href="$PREFIX/snapshots/remembering-0.2.0.tar.xz.asc">sig</a>) + </td> + <td> + EuAndreh + </td> + <td> + 2021-01-04 15:26 -3 + </td> + </tr> + <tr> + <td> + <a href="$PREFIX/tags/v0.1.2.html"> + v0.1.2 + </a> + </td> + <td> + <a href="$PREFIX/snapshots/remembering-0.1.2.tar.xz"> + remembering-0.2.1.tar.xz + </a> + (<a href="$PREFIX/snapshots/remembering-0.1.2.tar.xz.asc">sig</a>) + </td> + <td> + EuAndreh + </td> + <td> + 2021-01-03 15:26 -3 + </td> + </tr> + <tr> + <td> + <a href="$PREFIX/tags/v0.1.1.html"> + v0.1.1 + </a> + </td> + <td> + <a href="$PREFIX/snapshots/remembering-0.1.1.tar.xz"> + remembering-0.2.1.tar.xz + </a> + (<a href="$PREFIX/snapshots/remembering-0.1.1.tar.xz.asc">sig</a>) + </td> + <td> + EuAndreh + </td> + <td> + 2021-01-02 15:26 -3 + </td> + </tr> + <tr> + <td> + <a href="$PREFIX/tags/v0.1.0.html"> + v0.1.0 + </a> + </td> + <td> + <a href="$PREFIX/snapshots/remembering-0.1.0.tar.xz"> + remembering-0.2.1.tar.xz + </a> + (<a href="$PREFIX/snapshots/remembering-0.1.0.tar.xz.asc">sig</a>) + </td> + <td> + EuAndreh + </td> + <td> + 2021-01-01 15:26 -3 + </td> + </tr> + </table> + </main> + <footer> + <hr /> + <p> + Generated by gistatic $VERSION at $NOW + </p> + </footer> + </body> +</html> |