diff --git a/cmd/pm/tasks/base.go b/cmd/pm/tasks/base.go index 057ea88..d634629 100644 --- a/cmd/pm/tasks/base.go +++ b/cmd/pm/tasks/base.go @@ -61,18 +61,26 @@ func BaseDetails(interfaceType InterfaceType) TaskDetails { - REPL stands for Read-Eval-Print Loop. It is an interactive programming environment that takes single user inputs (reads), executes them (eval), and returns the result to the user (print), then waits for the next input (loop). - In this task, you will interact with the task through a REPL interface, which allows you to execute commands and receive immediate feedback in a command-line environment. - You can type commands to perform actions related to the task, and the REPL will process those commands and provide responses based on your input. -- The REPL interface is designed to facilitate a more dynamic and interactive way of completing the task, allowing you to experiment and receive real-time feedback as you work through the task requirements.` +- The REPL interface is designed to facilitate a more dynamic and interactive way of completing the task, allowing you to experiment and receive real-time feedback as you work through the task requirements. +- Write "exit" to skip task during the survey.` case InterfaceTypeTUI: interfaceDesc = `What is a TUI Interface? - TUI stands for Text User Interface. It is a user interface that uses text-based elements to allow users to interact with the application. - The main way to interact with a TUI is through keyboard inputs, where you can navigate through menus, select options, and input data using the keyboard. - In this task, you will interact with the task through a TUI interface, which provides a more structured and visually organized way to complete the task using text-based menus, forms, and other interactive elements. -- The TUI interface is designed to enhance usability and provide a more engaging experience while working through the task requirements, allowing you to navigate through options and input information in a more intuitive way.` +- The TUI interface is designed to enhance usability and provide a more engaging experience while working through the task requirements, allowing you to navigate through options and input information in a more intuitive way. +- Press "q" to quit task during the survey.` case InterfaceTypeWeb: interfaceDesc = `What is a Web Interface? - A Web Interface is a user interface that is accessed through a web browser. It allows users to interact with the application using graphical elements such as buttons, forms, and menus. - In this task, you will interact with the task through a Web interface, which provides a more visually rich and user-friendly way to complete the task using a web-based platform. -- The Web interface is designed to enhance usability and provide a more engaging experience while working through the task requirements, allowing you to navigate through options and input information in a more intuitive way using a graphical interface.` +- The Web interface is designed to enhance usability and provide a more engaging experience while working through the task requirements, allowing you to navigate through options and input information in a more intuitive way using a graphical interface. +- Press esc/q in the terminal to skip the task.` + case InterfaceTypeCLI: + interfaceDesc = `What is a CLI Interface? +- CLI stands for Command-Line Interface. It is a text-based interface where you interact with the application by typing commands. +- In this task, you will interact with the task through a CLI interface and execute commands directly in the terminal. +- Write "exit" to skip task during the survey.` default: interfaceDesc = "Unknown Interface" } diff --git a/internal/commands/issues/root.go b/internal/commands/issues/root.go index 3c1e5d3..d86646e 100644 --- a/internal/commands/issues/root.go +++ b/internal/commands/issues/root.go @@ -35,7 +35,9 @@ type Flags struct { var RootCmd = &cobra.Command{ Use: "pm", Short: "Project Management User Interface Comparison CLI", - Long: `Project Management User Interface Comparison CLI is a tool designed to evaluate and compare different project management interfaces through a series of tasks and surveys.`, + Long: `Project Management User Interface Comparison CLI is a tool designed to evaluate and compare different project management interfaces through a series of tasks and surveys. + +Write 'exit' to skip this task.`, PersistentPreRun: func(cmd *cobra.Command, args []string) { // Inject app into context for all commands if app != nil { diff --git a/pkg/task/taskui.go b/pkg/task/taskui.go index d5fb921..5f1426d 100644 --- a/pkg/task/taskui.go +++ b/pkg/task/taskui.go @@ -109,7 +109,7 @@ func (m TaskModel) View() tea.View { b.WriteString("\n") - helpText := "Press " + m.keys.Start.Help().Key + " to start • " + m.keys.Quit.Help().Key + " to quit • " + m.keys.About.Help().Key + " " + m.keys.About.Help().Desc + helpText := "Press " + m.keys.Start.Help().Key + " to start • " + m.getQuitHelpText() + " • " + m.keys.About.Help().Key + " " + m.keys.About.Help().Desc b.WriteString(style.HelpStyle.Render(helpText)) final := lipgloss.Place(m.width, m.height, lipgloss.Center, lipgloss.Center, b.String()) @@ -119,6 +119,19 @@ func (m TaskModel) View() tea.View { return v } +func (m TaskModel) getQuitHelpText() string { + switch m.InterfaceType { + case models.InterfaceTypeWeb: + return "Press esc/q in the terminal to skip the task" + case models.InterfaceTypeTUI: + return "Press 'q' to skip task during the survey" + case models.InterfaceTypeCLI, models.InterfaceTypeREPL: + return "Write 'exit' to skip task during the survey" + default: + return m.keys.Quit.Help().Key + " to quit" + } +} + func (m *TaskModel) SetSize(width, height int) { m.width, m.height = width, height }