xaizek / pipedial (License: GPLv3 only) (since 2019-01-08)
One more tool for selecting something in console.
Commit 244fc0749516e4944bf8db6034de070a2ec3d879

Save prompt's input in history
Author: xaizek
Author date (UTC): 2019-03-23 11:54
Committer name: xaizek
Committer date (UTC): 2019-03-23 11:54
Parent(s): 0f1eed443064c7f79d6e8df7f776ca35a91345f3
Signing key: 99DC5E4DB05F6BE2
Tree: 3275b6b710426986a4bfb5391139bd43e1f6b956
File Lines added Lines deleted
src/PromptRequest.cpp 3 0
File src/PromptRequest.cpp changed (mode: 100644) (index 03e1606..f64c351)
29 29 #include <string> #include <string>
30 30 #include <utility> #include <utility>
31 31
32 #include <readline/history.h>
32 33 #include <readline/readline.h> #include <readline/readline.h>
33 34
34 35 #include "cursed/Input.hpp" #include "cursed/Input.hpp"
 
... ... PromptRequest::prompt(const std::wstring &invitation,
137 138
138 139 if (line == nullptr) { if (line == nullptr) {
139 140 cancelled = true; cancelled = true;
141 } else if (*line != '\0') {
142 add_history(line.get());
140 143 } }
141 144
142 145 return (cancelled ? std::wstring() : cursed::toWide(line.get())); return (cancelled ? std::wstring() : cursed::toWide(line.get()));
Hints

Before first commit, do not forget to setup your git environment:
git config --global user.name "your_name_here"
git config --global user.email "your@email_here"

Clone this repository using HTTP(S):
git clone https://code.reversed.top/user/xaizek/pipedial

Clone this repository using ssh (do not forget to upload a key first):
git clone ssh://rocketgit@code.reversed.top/user/xaizek/pipedial

You are allowed to anonymously push to this repository.
This means that your pushed commits will automatically be transformed into a pull request:
... clone the repository ...
... make some changes and some commits ...
git push origin master