diff --git a/docs/conf.py b/docs/conf.py
index 041ed4c2..482b6166 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -57,8 +57,10 @@
html_theme_options = {
"path_to_docs": "docs",
"repository_url": "https://github.com/executablebooks/sphinx-book-theme",
+ # "repository_branch": "gh-pages", # For testing
"launch_buttons": {
"binderhub_url": "https://mybinder.org",
+ # "jupyterhub_url": "https://datahub.berkeley.edu", # For testing
"colab_url": "https://colab.research.google.com/",
"notebook_interface": "jupyterlab",
"thebe": True,
diff --git a/sphinx_book_theme/launch.py b/sphinx_book_theme/launch.py
index e14f1866..d9bd0e1b 100644
--- a/sphinx_book_theme/launch.py
+++ b/sphinx_book_theme/launch.py
@@ -81,7 +81,7 @@ def add_hub_urls(app, pagename, templatename, context, doctree):
if jupyterhub_url:
url = (
f"{jupyterhub_url}/hub/user-redirect/git-pull?"
- f"repo={repo_url}&urlpath={ui_pre}/{repo}/{path_rel_repo}"
+ f"repo={repo_url}&urlpath={ui_pre}/{repo}/{path_rel_repo}&branch={branch}"
)
context["jupyterhub_url"] = url
diff --git a/tests/test_build/test_repo_custombranch.html b/tests/test_build/test_repo_custombranch.html
index 59e61904..fe63e0a1 100644
--- a/tests/test_build/test_repo_custombranch.html
+++ b/tests/test_build/test_repo_custombranch.html
@@ -5,7 +5,7 @@
Binder
-
+
-
+