Update to version v0.1.2.a.7 and implement auto-update feature in install.sh

- Updated index.html and version.txt to reflect the new release version v0.1.2.a.7.
- Added an auto-update option in install.sh to streamline the update process without user prompts.
- Modified terminal.py to support the new auto-update flag during updates.
This commit is contained in:
2025-11-15 19:42:02 -05:00
parent 16970b0866
commit 4d53a201b4
4 changed files with 23 additions and 6 deletions

View File

@@ -46,7 +46,7 @@
<div class="hero__metrics">
<div class="metric">
<p class="metric__label">Current release</p>
<p class="metric__value">v0.1.2.a.6</p>
<p class="metric__value">v0.1.2.a.7</p>
</div>
<div class="metric">
<p class="metric__label">Supported families</p>

View File

@@ -335,6 +335,12 @@ case "$1" in
python3 "$ZDTT_DIR/terminal.py"
;;
update)
# Check for auto-update flag
AUTO_UPDATE=false
if [[ "$2" == "--auto" ]] || [[ "$2" == "--yes" ]]; then
AUTO_UPDATE=true
fi
echo "Checking for updates..."
echo ""
@@ -369,8 +375,16 @@ case "$1" in
else
echo "🔔 Update available!"
echo ""
read -p "Do you want to update now? (yes/no): " -r
echo ""
# Auto-update if flag is set, otherwise prompt
if [ "$AUTO_UPDATE" = true ]; then
REPLY="yes"
echo "Auto-updating..."
echo ""
else
read -p "Do you want to update now? (yes/no): " -r
echo ""
fi
if [[ $REPLY =~ ^[Yy][Ee][Ss]$ ]]; then
echo "Updating ZDTT Terminal..."

View File

@@ -1877,12 +1877,15 @@ ZDTT Terminal v{self.version}
'install.sh'
)
# Add --auto flag to enable auto-update (skip prompt)
update_args = ['update', '--auto'] + args
if zdtt_wrapper:
subprocess.run([zdtt_wrapper, 'update'] + args)
subprocess.run([zdtt_wrapper] + update_args)
return
if os.path.isfile(installer_script):
subprocess.run(['bash', installer_script, 'update'] + args)
subprocess.run(['bash', installer_script] + update_args)
return
print("Unable to locate the ZDTT updater.")

View File

@@ -1 +1 @@
0.1.2.a.6
0.1.2.a.7