[1.11.5] - fix helps and updated doc websites

This commit is contained in:
Cyrille L 2024-01-20 17:15:34 +01:00
parent f235cd7598
commit 3718193600
6 changed files with 63 additions and 34 deletions

View File

@ -8,6 +8,11 @@ Tyto - Littérateur
# CURRENTLY IN DEV (in devel branch) !
## [1.11.5]
- fix show helps in some cases
- updated documentation website in usr/share/docs/www/
- some minor more things from last
## [1.11.4]
- small changes when writing domain config in [WEBSITE_FOOTER]
- check: added marker check (default "=", "+")

2
debian/control vendored
View File

@ -1,5 +1,5 @@
Package: tyto
Version: 1.11.4
Version: 1.11.5
Section: custom
Priority: optional
Architecture: all

View File

@ -1,6 +1,6 @@
#!/usr/bin/env python3
# version: 1.11.4
# date: 2024-01-15 1705339348
# version: 1.11.5
# date: 2024-01-20 17057667032024-01-15 1705339348
# Tyto - Littérateur
# Copyright (C) 2023 Cyrille Louarn <echolib+tyto@a-lec.org>
@ -97,24 +97,41 @@ if not __name__ == "__main__":
# Check installed files
check_install()
# Load some Tyto libs
import langs, debug, args, domain
#==========#
# Language #
#==========#
# Load some Tyto libs
# -------------------
import langs, debug, args, domain, help
# Languages
# ---------
langs.load_logs() # Load logs language
#========#
# Domain #
#========#
# Just help me !
# --------------
exit_sys = False
if len(sys.argv) == 1:
help.manage()
exit_sys = True
try:
if sys.argv[1] in ("--help", "help", "-h"):
help.manage()
exit_sys = True
except:
pass
exit_sys and sys.exit(0)
# Domain
# ------
domain.check_home() # Mainly check current directory
#===========#
# Arguments #
#===========#
# Arguments
# ---------
args.get_arguments() # Get arguments from command line
# First starting logs
@ -127,10 +144,9 @@ if args.err_action: # [action] error (only)
debug.out(2, "[action]", args.err_action, False, 2, False)
#===============#
# Start process #
#===============#
import check, help, new, wip, publish, show
# Start process
# -------------
import check, new, wip, publish, show
# From command line [ACTION], do
do = {
@ -145,7 +161,6 @@ do = {
}
# Test for errors in python module file (without try)
#do[args.action]()
# do[args.action]()
try: do[args.action]()
except KeyError: debug.out(90, args.action, "", True, 2, True)

View File

@ -26,6 +26,7 @@
import sys
import args, langs, show
#
#
#
@ -55,27 +56,33 @@ def manage():
"file",
)
show_main = True
try:
sys.argv[2]
if not sys.argv[2] in helps: show_main = True
else: show_main = False
if sys.argv[2] in helps:
show_main = False
except:
show_main = True
pass
if show_main:
print(langs.logs.help_man)
if args.commands["targets"]["all"]:
for h in helps:
if not h in norepeat:
print(helps[h])
return
try:
if args.commands["targets"]["all"]:
for h in helps:
if not h in norepeat:
print(helps[h])
return
except:
pass
for arg in range(2, len(sys.argv)):
if sys.argv[arg] in helps:
print(helps[sys.argv[arg]])
# CSS references
if args.commands["targets"]["css"]:
show.contents_file("/var/lib/tyto/tpl_files/styles.css", True)
try:
if args.commands["targets"]["css"]:
show.contents_file("/var/lib/tyto/tpl_files/styles.css", True)
except:
return

View File

@ -215,7 +215,8 @@ tyto [ACTION] [ARGUMENTS]
start > activate current domain
stop > deactivate current domain
check ? + [domain] : check current domain
show > show files contents [domain], [MODULES], [css]...
show > show files contents
[domain], [MODULES], [css], [article].html/.tyto
wip ? create HTML in "wip/" server
publish ? publish in "www/" server

View File

@ -215,7 +215,8 @@ tyto [ACTION] [ARGUMENTS]
start > activer le domain actuel
stop > désactiver le domaine actuel
check ? + [domain] : vérifier le domaine actuel
show > montre le contenu des fichiers [domain], [MODULES], [css]...
show > montre le contenu des fichiers
[domain], [MODULES], [css], [name].html/.tyto
wip ? créer de l'HTML dans le serveur "wip/"
publish ? publier dans le serveur "www/"