diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index e145c51..72fee3f 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -1,22 +1,75 @@ ---- -name: Docs - -permissions: - contents: write - actions: write +name: Deploy Hugo site to Pages on: push: branches: - main +permissions: + contents: read + pages: write + id-token: write + +concurrency: + group: "pages" + cancel-in-progress: false + +defaults: + run: + shell: bash + jobs: - deploy: + build: runs-on: ubuntu-latest + env: + HUGO_VERSION: 0.137.1 steps: - - uses: actions/checkout@v4 - - uses: actions/setup-python@v5 + - name: Install Hugo CLI + run: | + wget -O ${{ runner.temp }}/hugo.deb https://github.com/gohugoio/hugo/releases/download/v${HUGO_VERSION}/hugo_extended_${HUGO_VERSION}_linux-amd64.deb \ + && sudo dpkg -i ${{ runner.temp }}/hugo.deb + - name: Install Dart Sass + run: sudo snap install dart-sass + - name: Checkout + uses: actions/checkout@v4 + with: + submodules: recursive + fetch-depth: 0 + - name: Setup Pages + id: pages + uses: actions/configure-pages@v5 + - name: Install Node.js dependencies + run: | + [[ -f package-lock.json || -f npm-shrinkwrap.json ]] && npm ci || true + npm install -D autoprefixer + npm install -D postcss-cli + npm install -D postcss + - name: Build with Hugo + env: + HUGO_CACHEDIR: ${{ runner.temp }}/hugo_cache + HUGO_ENVIRONMENT: production + TZ: America/Los_Angeles + run: | + git clone --depth 1 --branch v0.11.0 https://github.com/google/docsy.git themes/docsy + git clone --depth 1 --branch 6.7.0 https://github.com/FortAwesome/Font-Awesome.git themes/github.com/FortAwesome/Font-Awesome + git clone --depth 1 --branch v5.3.3 https://github.com/twbs/bootstrap.git themes/github.com/twbs/bootstrap + hugo \ + --gc \ + --theme docsy \ + --minify \ + --baseURL "${{ steps.pages.outputs.base_url }}/" + - name: Upload artifact + uses: actions/upload-pages-artifact@v3 with: - python-version: 3.11 - - run: pip install mkdocs-material - - run: mkdocs gh-deploy --force + path: ./public + + deploy: + environment: + name: github-pages + url: ${{ steps.deployment.outputs.page_url }} + runs-on: ubuntu-latest + needs: build + steps: + - name: Deploy to GitHub Pages + id: deployment + uses: actions/deploy-pages@v4 diff --git a/docs/index.md b/docs/_index.md similarity index 94% rename from docs/index.md rename to docs/_index.md index a0774e4..927bee3 100644 --- a/docs/index.md +++ b/docs/_index.md @@ -1,3 +1,13 @@ ++++ +title = 'kci-dev' +date = 2024-01-14T07:07:07+01:00 ++++ + +
+
+
+
+ # kci-dev kci-dev is a cmdline tool for interact with a enabled KernelCI server @@ -78,12 +88,12 @@ kci-dev --settings /path/to/.kci-dev.toml ### checkout -- [checkout](checkout.md) +- [checkout](checkout) ### testretry -- [testretry](testretry.md) +- [testretry](testretry) ### results -- [results](results.md) +- [results](results) diff --git a/docs/checkout.md b/docs/checkout.md index c874f2e..5ab78b6 100644 --- a/docs/checkout.md +++ b/docs/checkout.md @@ -1,3 +1,13 @@ ++++ +title = 'checkout' +date = 2024-01-14T07:07:07+01:00 ++++ + +
+
+
+
+ ## checkout This command allow to test arbitary commit on the KernelCI Pipeline instance. This might be useful in several cases: diff --git a/docs/results.md b/docs/results.md index 89d49bd..a8c2c69 100644 --- a/docs/results.md +++ b/docs/results.md @@ -1,3 +1,13 @@ ++++ +title = 'results' +date = 2024-01-14T07:07:07+01:00 ++++ + +
+
+
+
+ ### results This command will show the test result by node id. diff --git a/docs/testretry.md b/docs/testretry.md index 5bbe518..d0ebf1d 100644 --- a/docs/testretry.md +++ b/docs/testretry.md @@ -1,3 +1,13 @@ ++++ +title = 'testretry' +date = 2024-01-14T07:07:07+01:00 ++++ + +
+
+
+
+ ### testretry This command will retry the failed tests. In some cases tests may fail due to network issues, hardware problems, diff --git a/hugo.toml b/hugo.toml new file mode 100644 index 0000000..96cc507 --- /dev/null +++ b/hugo.toml @@ -0,0 +1,18 @@ +baseURL = 'https://aliceinwire.github.io/kci-dev/' +languageCode = 'en-us' +title = 'kci-dev' +description = 'kci-dev is a cmdline tool for interact with a enabled KernelCI server.' +contentDir = "docs/" + +[markup] + [markup.goldmark] + [markup.goldmark.renderer] + unsafe = true + +[params.ui] +sidebar_menu_compact = false +breadcrumb_disable = false +sidebar_search_disable = false +navbar_logo = true +footer_about_enable = true +navbar_translucent_over_cover_disable = true diff --git a/mkdocs.yml b/mkdocs.yml deleted file mode 100644 index 9d534a3..0000000 --- a/mkdocs.yml +++ /dev/null @@ -1,34 +0,0 @@ ---- -# Project Information -site_name: kci-dev -site_author: Arisu Tachibana -site_description: >- - kci-dev is a cmdline tool for interact with a - enabled KernelCI server. - -# Repository information -repo_name: kernelci/kci-dev -repo_url: https://github.com/kernelci/kci-dev -edit_uri: "" - -# Configuration -theme: - name: material - icon: - repo: fontawesome/brands/github - features: - - navigation.instant - - navigation.tabs - language: en - -# Footer -extra: - social: - - icon: fontawesome/brands/github - link: https://github.com/kernelci - name: kernelci on GitHub - -# Page tree -nav: - - Home: - - Introduction: index.md