|
| 1 | +# CYBERTEC Geekdoc |
| 2 | + |
| 3 | +A CYBERTEC themed fork of [geekdoc](https://github.com/thegeeklab/hugo-geekdoc), a Hugo theme made for documentation. |
| 4 | + |
| 5 | +--- |
| 6 | + |
| 7 | +## Requirements |
| 8 | + |
| 9 | +- [`go`](https://go.dev/doc/install) |
| 10 | +- [`hugo`](https://gohugo.io/installation/) |
| 11 | + |
| 12 | +## Usage |
| 13 | + |
| 14 | +Initialize a new hugo site: |
| 15 | + |
| 16 | +```shell |
| 17 | +hugo new site <site-name> |
| 18 | +cd <site-name> |
| 19 | +``` |
| 20 | + |
| 21 | +Initialize the site as a go module: |
| 22 | + |
| 23 | +```shell |
| 24 | +hugo mod init github.com/cybertec-postgresql/<repository-name> |
| 25 | +``` |
| 26 | + |
| 27 | +Add the following to your `hugo.toml` to use this theme, including functional code-highlighting: |
| 28 | + |
| 29 | +```toml |
| 30 | +# hugo.toml |
| 31 | +pygmentsCodeFences = true |
| 32 | +pygmentsUseClasses = true |
| 33 | + |
| 34 | +[module] |
| 35 | +[[module.imports]] |
| 36 | +path = 'github.com/cybertec-postgresql/hugo-geekdoc' |
| 37 | +``` |
| 38 | + |
| 39 | +Fetch the module |
| 40 | + |
| 41 | +```shell |
| 42 | +hugo mod get -u |
| 43 | +``` |
| 44 | + |
| 45 | +Build your page |
| 46 | +```shell |
| 47 | +hugo --minify |
| 48 | +# You may optionally overwrite the `baseURL` |
| 49 | +hugo --minify -b "/docs/" |
| 50 | +``` |
| 51 | + |
| 52 | +## Update |
| 53 | + |
| 54 | +To retrieve the latest version of this theme, simply run |
| 55 | + |
| 56 | +```shell |
| 57 | +hugo mod get -u |
| 58 | +hugo mod tidy |
| 59 | +``` |
| 60 | + |
| 61 | +## Development |
| 62 | + |
| 63 | +The fork and source code is located inside the `dev` branch. On push, a GitHub Actions workflow will build and push the release to the `main` branch. |
| 64 | + |
| 65 | +### Sync fork |
| 66 | + |
| 67 | +``` |
| 68 | +git checkout dev |
| 69 | +git remote add upstream https://github.com/thegeeklab/hugo-geekdoc |
| 70 | +git fetch upstream |
| 71 | +git rebase upstream/main |
| 72 | +git push --force |
| 73 | +``` |
| 74 | + |
| 75 | +--- |
| 76 | + |
| 77 | +The contents below are from the original Geekdoc README. |
| 78 | + |
| 79 | +--- |
| 80 | + |
| 81 | +[](https://ci.thegeeklab.de/repos/thegeeklab/hugo-geekdoc) |
| 82 | +[](https://gohugo.io) |
| 83 | +[](https://github.com/thegeeklab/hugo-geekdoc/releases/latest) |
| 84 | +[](https://github.com/thegeeklab/hugo-geekdoc/graphs/contributors) |
| 85 | +[](https://github.com/thegeeklab/hugo-geekdoc/blob/main/LICENSE) |
| 86 | + |
| 87 | +Geekdoc is a simple Hugo theme for documentations. It is intentionally designed as a fast and lean theme and may not fit the requirements of complex projects. If a more feature-complete theme is required there are a lot of good alternatives out there. You can find a demo and the full documentation at [https://geekdocs.de](https://geekdocs.de). |
| 88 | + |
| 89 | + |
| 90 | + |
| 91 | +## Build and release process |
| 92 | + |
| 93 | +This theme is subject to a CI driven build and release process common for software development. During the release build, all necessary assets are automatically built by [webpack](https://webpack.js.org/) and bundled in a release tarball. You can download the latest release from the GitHub [release page](https://github.com/thegeeklab/hugo-geekdoc/releases). |
| 94 | + |
| 95 | +Due to the fact that `webpack` and `npm scripts` are used as pre-processors, the theme cannot be used from the main branch by default. If you want to use the theme from a cloned branch instead of a release tarball you'll need to install `webpack` locally and run the build script once to create all required assets. |
| 96 | + |
| 97 | +```shell |
| 98 | +# install required packages from package.json |
| 99 | +npm install |
| 100 | + |
| 101 | +# run the build script to build required assets |
| 102 | +npm run build |
| 103 | + |
| 104 | +# build release tarball |
| 105 | +npm run pack |
| 106 | +``` |
| 107 | + |
| 108 | +See the [Getting Started Guide](https://geekdocs.de/usage/getting-started/) for details about the different setup options. |
| 109 | + |
| 110 | +## Contributors |
| 111 | + |
| 112 | +Special thanks to all [contributors](https://github.com/thegeeklab/hugo-geekdoc/graphs/contributors). If you would like to contribute, please see the [instructions](https://github.com/thegeeklab/hugo-geekdoc/blob/main/CONTRIBUTING.md). |
| 113 | + |
| 114 | +Geekdoc is inspired and partially based on the [hugo-book](https://github.com/alex-shpak/hugo-book) theme, thanks [Alex Shpak](https://github.com/alex-shpak/) for your work. |
| 115 | + |
| 116 | +## License |
| 117 | + |
| 118 | +This project is licensed under the MIT License - see the [LICENSE](https://github.com/thegeeklab/hugo-geekdoc/blob/main/LICENSE) file for details. |
| 119 | + |
| 120 | +The used SVG icons and generated icon fonts are licensed under the license of the respective icon pack: |
| 121 | + |
| 122 | +- Font Awesome: [CC BY 4.0 License](https://github.com/FortAwesome/Font-Awesome#license) |
| 123 | +- IcoMoon Free Pack: [GPL/CC BY 4.0](https://icomoon.io/#icons-icomoon) |
| 124 | +- Material Icons: [Apache License 2.0](https://github.com/google/material-design-icons/blob/main/LICENSE) |
0 commit comments