This commit is contained in:
parent
409cd102f9
commit
5792ba3dd6
@ -85,6 +85,7 @@ nav:
|
|||||||
# - VM Passthrough Harddrives: proxmox/vm-passthrough-harddrives.md
|
# - VM Passthrough Harddrives: proxmox/vm-passthrough-harddrives.md
|
||||||
- Portainer Stacks:
|
- Portainer Stacks:
|
||||||
- Airsonic: portainer-stacks/Airsonic.md
|
- Airsonic: portainer-stacks/Airsonic.md
|
||||||
|
- authelia: portainer-stacks/authelia.md
|
||||||
- Authentik: portainer-stacks/Authentik.md
|
- Authentik: portainer-stacks/Authentik.md
|
||||||
- bazarr: portainer-stacks/bazarr.md
|
- bazarr: portainer-stacks/bazarr.md
|
||||||
- Bitwarden: portainer-stacks/Bitwarden.md
|
- Bitwarden: portainer-stacks/Bitwarden.md
|
||||||
@ -119,6 +120,7 @@ nav:
|
|||||||
- rustdesk: portainer-stacks/rustdesk.md
|
- rustdesk: portainer-stacks/rustdesk.md
|
||||||
- samba: portainer-stacks/samba.md
|
- samba: portainer-stacks/samba.md
|
||||||
- shlink: portainer-stacks/shlink.md
|
- shlink: portainer-stacks/shlink.md
|
||||||
|
- Swag: portainer-stacks/Swag.md
|
||||||
- tailscale: portainer-stacks/tailscale.md
|
- tailscale: portainer-stacks/tailscale.md
|
||||||
- TasmoBackup: portainer-stacks/TasmoBackup.md
|
- TasmoBackup: portainer-stacks/TasmoBackup.md
|
||||||
- Tasmota-Device-Manager: portainer-stacks/Tasmota-Device-Manager.md
|
- Tasmota-Device-Manager: portainer-stacks/Tasmota-Device-Manager.md
|
||||||
@ -130,9 +132,9 @@ nav:
|
|||||||
- WireGuard: portainer-stacks/WireGuard.md
|
- WireGuard: portainer-stacks/WireGuard.md
|
||||||
- Zigbee2MQTT: portainer-stacks/Zigbee2MQTT.md
|
- Zigbee2MQTT: portainer-stacks/Zigbee2MQTT.md
|
||||||
- Swag:
|
- Swag:
|
||||||
- Swag: portainer-stacks/Swag/Swag.md
|
- Swag: portainer-stacks/Swag.md
|
||||||
- Swag MODs: portainer-stacks/Swag/Swag-MODS.md
|
- Swag MODs: portainer-stacks/Swag/Swag-MODS.md
|
||||||
- Authelia: portainer-stacks/Swag/authelia.md
|
- Authelia: portainer-stacks/authelia.md
|
||||||
- Theme-Park: portainer-stacks/Swag/adding-theme-park.md
|
- Theme-Park: portainer-stacks/Swag/adding-theme-park.md
|
||||||
- cmnds:
|
- cmnds:
|
||||||
- 101: cmnds/101.md
|
- 101: cmnds/101.md
|
||||||
|
28
scripts/1.py
Normal file
28
scripts/1.py
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
import os
|
||||||
|
|
||||||
|
# Define the directory containing Portainer Stack Markdown files
|
||||||
|
markdown_dir = "./docs/proxmox"
|
||||||
|
|
||||||
|
# Define the relative path prefix used in mkdocs.yml
|
||||||
|
relative_path_prefix = "proxmox/"
|
||||||
|
|
||||||
|
# Generate navigation entries
|
||||||
|
nav_entries = []
|
||||||
|
for filename in os.listdir(markdown_dir):
|
||||||
|
if filename.endswith(".md"):
|
||||||
|
title = filename[:-3] # Remove ".md" extension
|
||||||
|
relative_path = f"{relative_path_prefix}{filename}" # Generate relative path
|
||||||
|
nav_entries.append(f" - {title}: {relative_path}") # Add 4 spaces
|
||||||
|
|
||||||
|
# List of names to ignore
|
||||||
|
names_to_ignore = ["template"] # Add names you want to ignore here
|
||||||
|
|
||||||
|
# Filter out entries to ignore
|
||||||
|
filtered_nav_entries = [entry for entry in nav_entries if not any(name in entry for name in names_to_ignore)]
|
||||||
|
|
||||||
|
# Sort the navigation entries alphabetically (case-insensitive)
|
||||||
|
sorted_nav_entries = sorted(filtered_nav_entries, key=lambda entry: entry.lower())
|
||||||
|
|
||||||
|
# Print the sorted navigation entries with 4 spaces
|
||||||
|
for entry in sorted_nav_entries:
|
||||||
|
print(entry)
|
25
scripts/git.py
Normal file
25
scripts/git.py
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
import os
|
||||||
|
import subprocess
|
||||||
|
import argparse
|
||||||
|
|
||||||
|
# Define and parse command-line arguments
|
||||||
|
parser = argparse.ArgumentParser(description="Automate Git add, commit, and push operations.")
|
||||||
|
parser.add_argument("--COMMIT-MSG", help="Commit message for the changes.")
|
||||||
|
args = parser.parse_args()
|
||||||
|
|
||||||
|
# Get the commit message from command-line argument or prompt user
|
||||||
|
if args.COMMIT_MSG:
|
||||||
|
commit_msg = args.COMMIT_MSG
|
||||||
|
else:
|
||||||
|
commit_msg = input("Enter commit message: ")
|
||||||
|
|
||||||
|
# Add changes to the staging area
|
||||||
|
subprocess.run(["git", "add", "."], check=True)
|
||||||
|
|
||||||
|
# Commit changes
|
||||||
|
subprocess.run(["git", "commit", "-m", commit_msg], check=True)
|
||||||
|
|
||||||
|
# Push changes
|
||||||
|
subprocess.run(["git", "push"], check=True)
|
||||||
|
|
||||||
|
print("Changes have been added, committed, and pushed.")
|
Loading…
x
Reference in New Issue
Block a user