docs: add nightly release redirect

This commit is contained in:
Clement Tsang
2025-12-25 17:55:15 -05:00
parent 84f42712ef
commit c75dfed850
7 changed files with 53 additions and 17 deletions
+1
View File
@@ -1,3 +1,4 @@
site/
venv/
.cache/
hooks/__pycache__/
+1
View File
@@ -0,0 +1 @@
<!-- Intentionally empty file, used for redirects -->
+11 -10
View File
@@ -80,36 +80,37 @@ Let's say you're installing [Iosevka](https://github.com/be5invis/Iosevka). The
## Why can't I see all my temperature sensors on Windows?
This is a [known limitation](./support/official.md#windows), some sensors may require admin privileges to get sensor data.
This is a known issue, some sensors may require admin privileges to get sensor data.
## Why don't I see dual batteries on Windows reported separately? (e.g. Thinkpads)
This is a [known limitation](./support/official.md#windows) which seems to be with how batteries are being detected on Windows.
This is a known issue which seems to be with how batteries are being detected on Windows.
## Why can't I see all my temperature sensors on WSL?
This is a [known limitation](./support/official.md#windows) with WSL. Due to how it works, hosts may not expose their
This is a known limitation with WSL. Due to how it works, hosts may not expose their
temperature sensors and therefore, temperature sensors might be missing.
## Why does WSL2 not match Task Manager?
This is a [known limitation](./support/official.md#windows) with WSL2. Due to how WSL2 works, the two might not match
This is a known limitation with WSL2. Due to how WSL2 works, the two might not match
up in terms of reported data.
## Why can't I see all my processes/process data on macOS?
This is a [known limitation](./support/official.md#macos), and you may have to run the program with elevated
privileges to work around it - for example:
You may have to run the program with elevated privileges to work around it - for example:
```bash
sudo btm
```
**Please note that you should be certain that you trust any software you grant root privileges.**
!!! Warning
There are measures taken to try to maximize the amount of information obtained without elevated privileges. For example,
one can modify the instructions found on the [htop wiki](https://github.com/hishamhm/htop/wiki/macOS:-run-without-sudo)
on how to run htop without sudo for bottom. However, **please** understand the potential security risks before doing so!
Please note that you should be certain that you trust any software you grant root privileges.
There are measures taken to try to maximize the amount of information obtained without elevated privileges. For example,
one can modify the instructions found on the [htop wiki](https://github.com/hishamhm/htop/wiki/macOS:-run-without-sudo)
on how to run htop without sudo for bottom. However, **please** understand the potential security risks before doing so!
## My configuration file isn't working
+27
View File
@@ -0,0 +1,27 @@
import mkdocs.plugins
import urllib.request
import json
# Based on https://github.com/squidfunk/mkdocs-material/discussions/3758#discussioncomment-4397373
@mkdocs.plugins.event_priority(-50)
def on_config(config):
print("Running nightly release redirect hook...")
try:
with urllib.request.urlopen("https://api.github.com/repos/ClementTsang/bottom/releases") as response:
raw_data = response.read()
data = json.loads(raw_data.decode('utf-8'))
first_nightly = next(release for release in data if "nightly-" in release["tag_name"])
nightly_tag_name = first_nightly["tag_name"]
redirect_plugin = config.get('plugins', {}).get('redirects')
redirects = redirect_plugin.config.get('redirect_maps', {})
nightly_release_url = f"https://github.com/ClementTsang/bottom/releases/tag/{nightly_tag_name}"
print(f"Updated nightly release redirect to point to {nightly_release_url}")
redirects["nightly-release.md"] = nightly_release_url
except Exception as e:
print(f"error adjusting redirect, falling back to general releases page: {e}")
+6
View File
@@ -137,6 +137,9 @@ plugins:
- git-revision-date-localized:
type: date
- privacy
- redirects:
redirect_maps:
nightly-release.md: "https://github.com/ClementTsang/bottom/releases"
extra:
# Versioning
@@ -185,3 +188,6 @@ nav:
- "Build Process": contribution/development/build_process.md
- "Deploy Process": contribution/development/deploy_process.md
- "Troubleshooting": troubleshooting.md
hooks:
- ./hooks/nightly_redirect.py
+1 -1
View File
@@ -3,4 +3,4 @@ mkdocs-material == 9.7.1
mdx_truly_sane_lists == 1.3
mike == 2.1.3
mkdocs-git-revision-date-localized-plugin == 1.4.5
mkdocs-redirects == 1.2.2
+6 -6
View File
@@ -2,21 +2,21 @@
set -e
VENV_PATH="./venv/"
VENV_PATH="./.venv/"
PYTHON_CMD=${1:-python}
if [ ! -d $VENV_PATH ]; then
echo "venv not found, creating one using the command '${PYTHON_CMD}'...";
$PYTHON_CMD -m venv venv;
source ./venv/bin/activate;
$PYTHON_CMD -m venv .venv;
source $VENV_PATH/bin/activate;
pip install --upgrade pip;
pip install -r requirements.txt;
./venv/bin/mkdocs serve;
$VENV_PATH/bin/mkdocs serve;
else
echo "venv already found.";
source ./venv/bin/activate;
source $VENV_PATH/bin/activate;
pip install --upgrade pip;
pip install -r requirements.txt;
./venv/bin/mkdocs serve;
$VENV_PATH/bin/mkdocs serve;
fi;