Skip to content

Commit 080b643

Browse files
committed
test alternate krank import method
1 parent b56540e commit 080b643

File tree

3 files changed

+27
-13
lines changed

3 files changed

+27
-13
lines changed

.github/workflows/docs.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -27,15 +27,15 @@ jobs:
2727
url: ${{ steps.deployment.outputs.page_url }}
2828
runs-on: ubuntu-latest
2929
steps:
30-
- name: Checkout
31-
uses: actions/checkout@v4
30+
# - name: Checkout
31+
# uses: actions/checkout@v4
3232
# - name: Setup Pages
3333
# - name: Upload artifact
3434
# uses: actions/upload-pages-artifact@v3
3535
# with:
3636
# path: "./docs" # Upload entire repository
37-
- name: Install package
38-
run: python -m pip install .
37+
# - name: Install package
38+
# run: python -m pip install .
3939
- name: Deploy to GitHub Pages
4040
id: deployment
4141
uses: sphinx-notes/pages@v3

docs/conf.py

+22-9
Original file line numberDiff line numberDiff line change
@@ -6,19 +6,23 @@
66

77
# -- Project information -----------------------------------------------------
88
# https://www.sphinx-doc.org/en/master/usage/configuration.html#project-information
9-
10-
import os
9+
from pathlib import Path
1110
import time
1211
import sys
1312

1413
from importlib.metadata import metadata
1514

15+
# Need to make sure that krank can be imported, and also that
16+
# it is importing the local one (as opposed to a previously pip installed one).
17+
# So this can be from the krank/src/krank directory or through a locally
18+
# built or locally pip installed version.
19+
#
1620
# autodoc needs to import your modules in order to extract the docstrings.
1721
# Therefore, you must add the appropriate path to sys.path in your conf.py.
18-
# sys.path.insert(0, os.path.abspath("../krank/src"))
19-
22+
sys.path.insert(0, str(Path(__file__).parents[1].joinpath("src")))
2023
import krank
2124

25+
2226
project = krank.__name__
2327
release = krank.__version__ # Full project version
2428
version = krank.__version__[:3] # Major project version
@@ -106,14 +110,23 @@
106110
{"name": "Contributing", "url": "https://github.com/remrama/krank#contributing"},
107111
],
108112
"header_links_before_dropdown": 4,
113+
"navbar_start": ["navbar-icon-links", "navbar-logo", "version-switcher"],
114+
"navbar_center": ["navbar-nav"],
115+
"navbar_end": [], # equivalent to just icon-links?
116+
# "navbar_persistent": [], # Default is a nice search bubble that I otherwise don't get
117+
"search_bar_text": "Search...",
118+
# "article_header_start": ["breadcrumbs"],
119+
# "article_header_end": [],
120+
# "article_footer_items": [],
121+
"footer_start": ["last-updated"], # "search-field" "search-button"
122+
"footer_center": [],
123+
"footer_end": [], # "theme-switcher"
124+
"content_footer_items": [],
125+
"show_prev_next": False,
109126
# "sidebarwidth": 230,
110127
# "navbar_start": ["navbar-logo", "version-switcher"],
111128
"show_version_warning_banner": True,
112129
"announcement": "BEWARE! This project is in the <a href='https://github.com/remrama/krank'>planning stage</a>.",
113-
# "navbar_end": ["theme-switcher", "navbar-icon-links"],
114-
"navbar_end": ["navbar-icon-links"],
115-
# "navbar_end": ["theme-switcher", "navbar-icon-links", "search-field"],
116-
# "search_bar_text": "Search for something...",
117130
"navbar_align": "left", # [left, content, right] For testing that the navbar items align properly
118131
"show_nav_level": 3,
119132
"show_toc_level": 3,
@@ -126,7 +139,7 @@
126139
# "icon_links_label": "Quick Links",
127140
"icon_links": [
128141
{
129-
"name": "GitHub",
142+
"name": "Krank on GitHub",
130143
"url": "https://github.com/remrama/krank",
131144
"icon": "fa-brands fa-square-github",
132145
"type": "fontawesome",

docs/index.rst

+1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
.. image:: https://badge.fury.io/py/krank.svg
33
:target: https://badge.fury.io/py/krank
44

5+
----
56

67
Krank
78
=====

0 commit comments

Comments
 (0)