mirror of
https://github.com/harvard-edge/cs249r_book.git
synced 2026-03-11 17:49:25 -05:00
⚡ Add defaults to all interactive prompts for better UX
This commit is contained in:
12
binder
12
binder
@@ -1091,8 +1091,10 @@ class BookBinder:
|
||||
if current_branch == "dev":
|
||||
console.print("[yellow]⚠️ You're on dev branch[/yellow]")
|
||||
console.print("[blue]Should I merge dev into main?[/blue]")
|
||||
console.print("[bold]Merge dev to main? (y/n): [/bold]", end="")
|
||||
console.print("[bold]Merge dev to main? (y/n) [y]: [/bold]", end="")
|
||||
choice = input().strip().lower()
|
||||
if not choice:
|
||||
choice = 'y'
|
||||
|
||||
if choice in ['y', 'yes']:
|
||||
console.print("[blue]🔄 Merging dev to main...[/blue]")
|
||||
@@ -1148,8 +1150,10 @@ class BookBinder:
|
||||
|
||||
# Ask about release creation
|
||||
console.print("\n[blue]📦 Create GitHub release?[/blue]")
|
||||
console.print("[bold]Create release? (y/n): [/bold]", end="")
|
||||
console.print("[bold]Create release? (y/n) [y]: [/bold]", end="")
|
||||
release_choice = input().strip().lower()
|
||||
if not release_choice:
|
||||
release_choice = 'y'
|
||||
create_release = release_choice in ['y', 'yes']
|
||||
|
||||
# Ask about AI release notes (only for publishing)
|
||||
@@ -2043,8 +2047,10 @@ Format as markdown with clear sections."""
|
||||
console.print(f" Email: {current_email}")
|
||||
|
||||
console.print("\n[blue]Would you like to update your Git configuration?[/blue]")
|
||||
console.print("[bold]Update Git config? (y/n): [/bold]", end="")
|
||||
console.print("[bold]Update Git config? (y/n) [n]: [/bold]", end="")
|
||||
update_choice = input().strip().lower()
|
||||
if not update_choice:
|
||||
update_choice = 'n'
|
||||
|
||||
if update_choice not in ['y', 'yes']:
|
||||
console.print("[green]✅ Keeping current Git configuration[/green]")
|
||||
|
||||
Reference in New Issue
Block a user