The same way it is possible to delete duplicates in minibuffer history, I think it is also very useful to have the possibility to ignore entries starting with space(s). The new variable `history-ignore-space' would take
care of this, being `nil' its defaut value.
+ /* Make sure the string must be strored. */
+ if (history_ignore_space + && !NILP (histstring) + && SREF (histstring,0) == ' ') + histstring = Qnil; + /* Add the value to the appropriate history list, if any. */
if (!NILP (Vhistory_add_new_input) && SYMBOLP (Vminibuffer_history_variable) @@ -2156,6 +2166,12 @@ elements are deleted from the history list. */); history_delete_duplicates = 0;
+ DEFVAR_BOOL ("history-ignore-space", &history_ignore_space, + doc: /* *Non-nil means to ignore entries starting with space. +If set to t, elements starting with space are not stored into the
+history list. */); + history_ignore_space = 0; + DEFVAR_LISP ("history-add-new-input", &Vhistory_add_new_input, doc: /* *Non-nil means to add new elements in history. If set to nil, minibuffer reading functions don't add new elements to the
If you like the idea I can install them in the trunk for release 23.2.