commit 44fec0b055a59cc88d7cfe19a7eee39ef57803e3 Author: Robert Kaussow Date: Sat Jun 27 23:07:52 2020 +0200 initial commit diff --git a/.drone.yml b/.drone.yml new file mode 100644 index 0000000..5269445 --- /dev/null +++ b/.drone.yml @@ -0,0 +1,217 @@ +--- +kind: pipeline +name: test + +platform: + os: linux + arch: amd64 + +steps: +- name: assets + image: node:lts + commands: + - npm install -g gulp + - npm install + - gulp default + environment: + FORCE_COLOR: true + NPM_CONFIG_LOGLEVEL: error + +- name: testbuild + image: klakegg/hugo:0.72.0-ext-alpine + commands: + - mkdir exampleSite/themes/ && ln -s $(pwd)/ exampleSite/themes/hugo-geekblog + - hugo-official -s exampleSite/ -b http://localhost/ + +- name: html-validation + image: validator/validator + commands: + - vnu --skip-non-html --also-check-css --errors-only exampleSite/public + +- name: link-validation + image: xoxys/link-validator + commands: + - link-validator -ro + environment: + LINK_VALIDATOR_BASE_DIR: exampleSite/public + +- name: page-validation + image: patrickhulce/lhci-client + user: root + commands: + - lhci autorun + +trigger: + ref: + - refs/heads/master + - refs/tags/** + - refs/pull/** + +--- +kind: pipeline +name: build + +platform: + os: linux + arch: amd64 + +steps: +- name: assets + image: node:lts + commands: + - npm install -g gulp + - npm install + - gulp default + environment: + FORCE_COLOR: true + NPM_CONFIG_LOGLEVEL: error + +- name: package + image: alpine + commands: + - mkdir dist/ + - echo "${DRONE_TAG:-latest}" > VERSION + - tar -zcvf dist/hugo-geekblog.tar.gz -X .tarignore . + +- name: checksum + image: alpine + commands: + - cd dist/ && sha256sum * > ../sha256sum.txt + +- name: release + image: plugins/github-release + settings: + api_key: + from_secret: github_token + files: + - dist/* + - sha256sum.txt + note: CHANGELOG.md + overwrite: true + title: ${DRONE_TAG} + +trigger: + ref: + - refs/tags/** + +depends_on: +- test + +--- +kind: pipeline +name: docs + +platform: + os: linux + arch: amd64 + +concurrency: + limit: 1 + +steps: +- name: markdownlint + image: node:lts-alpine + commands: + - npm install -g markdownlint-cli + - markdownlint 'exampleSite/content/**/*.md' 'README.md' + environment: + FORCE_COLOR: true + NPM_CONFIG_LOGLEVEL: error + +- name: spellcheck + image: node:lts-alpine + commands: + - npm install -g spellchecker-cli + - spellchecker --files 'exampleSite/content/**/*.md' 'README.md' -d .dictionary -p spell indefinite-article syntax-urls --no-suggestions + environment: + FORCE_COLOR: true + NPM_CONFIG_LOGLEVEL: error + +- name: assets + image: byrnedo/alpine-curl + commands: + - mkdir -p exampleSite/themes/hugo-geekblog/ + - curl -sSL https://github.com/xoxys/hugo-geekblog/releases/latest/download/hugo-geekblog.tar.gz | tar -xz -C exampleSite/themes/hugo-geekblog/ --strip-components=1 + +- name: build + image: klakegg/hugo:0.72.0-ext-alpine + commands: + - hugo-official -s exampleSite/ + +- name: beautify + image: node:lts-alpine + commands: + - npm install -g js-beautify + - html-beautify -r -f 'exampleSite/public/**/*.html' + environment: + FORCE_COLOR: true + NPM_CONFIG_LOGLEVEL: error + +- name: publish + image: plugins/s3-sync + settings: + access_key: + from_secret: s3_access_key + bucket: geekblogs + delete: true + endpoint: https://sp.rknet.org + path_style: true + secret_key: + from_secret: s3_secret_access_key + source: exampleSite/public/ + strip_prefix: exampleSite/public/ + target: /${DRONE_REPO_NAME} + when: + ref: + - refs/heads/master + - refs/tags/** + +trigger: + ref: + - refs/heads/master + - refs/tags/** + - refs/pull/** + +depends_on: +- build + +--- +kind: pipeline +name: notifications + +platform: + os: linux + arch: amd64 + +steps: +- name: matrix + image: plugins/matrix + settings: + homeserver: + from_secret: matrix_homeserver + password: + from_secret: matrix_password + roomid: + from_secret: matrix_roomid + template: "Status: **{{ build.status }}**
Build: [{{ repo.Owner }}/{{ repo.Name }}]({{ build.link }}) ({{ build.branch }}) by {{ build.author }}
Message: {{ build.message }}" + username: + from_secret: matrix_username + when: + status: + - success + - failure + +trigger: + ref: + - refs/heads/master + - refs/tags/** + status: + - success + - failure + +depends_on: +- test +- build +- docs + +... diff --git a/.github/settings.yml b/.github/settings.yml new file mode 100644 index 0000000..2e99f1e --- /dev/null +++ b/.github/settings.yml @@ -0,0 +1,61 @@ +--- +repository: + name: hugo-geekblog + description: Hugo theme made for blogs + homepage: https://geekblog.geekdocs.de + topics: hugo, theme, hugo-theme, blog + + private: false + has_issues: true + has_projects: false + has_wiki: false + has_downloads: false + + default_branch: master + + allow_squash_merge: true + allow_merge_commit: true + allow_rebase_merge: true + +labels: + - name: bug + color: d73a4a + description: Something isn't working + - name: documentation + color: 0075ca + description: Improvements or additions to documentation + - name: duplicate + color: cfd3d7 + description: This issue or pull request already exists + - name: enhancement + color: a2eeef + description: New feature or request + - name: good first issue + color: 7057ff + description: Good for newcomers + - name: help wanted + color: 008672 + description: Extra attention is needed + - name: invalid + color: e4e669 + description: This doesn't seem right + - name: question + color: d876e3 + description: Further information is requested + - name: wontfix + color: ffffff + description: This will not be worked on + +branches: + - name: master + protection: + required_status_checks: + strict: true + contexts: + - continuous-integration/drone/pr + enforce_admins: false + restrictions: + users: [] + teams: [] + +... diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..bbfc527 --- /dev/null +++ b/.gitignore @@ -0,0 +1,16 @@ +# local environments +.swp +.env* +dist/ +node_modules/ +exampleSite/themes/ +exampleSite/public/ + +# auto-generated files +layouts/partials/icons-svg-symbols.html +static/main.* +static/favicon/ +resources/_gen/ + +# testing +.lighthouseci/ diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..4675d23 --- /dev/null +++ b/LICENSE @@ -0,0 +1,20 @@ +The MIT License (MIT) + +Copyright (c) 2020 Robert Kaussow + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..af1866f --- /dev/null +++ b/README.md @@ -0,0 +1,18 @@ +# Hugo Geekblog Theme + +[![Build Status](https://img.shields.io/drone/build/xoxys/hugo-geekblog?logo=drone)](https://cloud.drone.io/xoxys/hugo-geekblog) +[![Hugo Version](https://img.shields.io/badge/hugo-0.65-blue.svg)](https://gohugo.io) +[![GitHub release](https://img.shields.io/github/v/release/xoxys/hugo-geekblog)](https://github.com/xoxys/hugo-geekblog/releases/latest) +[![License: MIT](https://img.shields.io/github/license/xoxys/hugo-geekblog)](LICENSE) + +geekblog is a simple Hugo theme for personal blogs. This work is inspired and partially based on the [hugo-book](https://github.com/alex-shpak/hugo-book) theme. You can find a demo and the full documentation at [https://geekblog.geekdocs.de](geekblog.geekdocs.de). + +![Screenshot Desktop](local_media/desktop.png) + +## License + +This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details. + +## Maintainers and Contributors + +[Robert Kaussow](https://github.com/xoxys)