Unify [y/N] prompts (#2212)

This commit is contained in:
CatsDeservePets authored and GitHub committed 2025-10-19 05:51:56 +02:00
1 parent 8a8f8180af
commit a949d4a5d1
3 files changed
+5 -4

No files matched your search

+3 -3
View File
@@ -1335,7 +1335,7 @@ func (e *callExpr) eval(app *app, args []string) {
}
normal(app)
if len(list) == 1 {
app.ui.cmdPrefix = "delete '" + list[0] + "' ? [y/N] "
app.ui.cmdPrefix = "delete '" + list[0] + "'? [y/N] "
} else {
app.ui.cmdPrefix = "delete " + strconv.Itoa(len(list)) + " items? [y/N] "
}
@@ -1980,7 +1980,7 @@ func (e *callExpr) eval(app *app, args []string) {
newDir := filepath.Dir(newPath)
if _, err := os.Stat(newDir); os.IsNotExist(err) {
app.ui.cmdPrefix = "create '" + newDir + "' ? [y/N] "
app.ui.cmdPrefix = "create '" + newDir + "'? [y/N] "
return
}
@@ -1990,7 +1990,7 @@ func (e *callExpr) eval(app *app, args []string) {
return
}
if newStat, err := os.Lstat(newPath); !os.IsNotExist(err) && !os.SameFile(oldStat, newStat) {
app.ui.cmdPrefix = "replace '" + newPath + "' ? [y/N] "
app.ui.cmdPrefix = "replace '" + newPath + "'? [y/N] "
return
}