Open Slaviusz opened 1 year ago
This happens if I type anything besides a Y
at any point between the "Continue ?" prompt and the previous one, i.e. right before the kernel starts building. Sometimes I accidentally hit a key on the keyboard while the kernel is building, and then, no matter what I do, this prompt results in triggering the default selection of n
.
Yes, I suffer from this too.
I'll see what I can do, for sure there must be a way to discard any earlier input before prompting
I have seen this being solved in some scripts before but I can't recall where.
I tried this and it worked on GNU bash, version 5.2.9(1)-release (x86_64-apple-darwin22.1.0)
:
clear_stdin()
(
old_tty_settings=`stty -g`
stty -icanon min 0 time 0
while read none; do :; done
stty $old_tty_settings
)
Thank you!
Now I collected on behalf of the user, and I did not have this problem.
The problem with flushing stdin is that approaches like yes "" | ./install.sh install
wouldn't work any longer, and it's used by some people and our pipeline here :thinking:
Yes I have just found this and I have this issue too
@AdelKS Regarding scripted pipeline I beleive one could use expect
or libexpect
for that matter.
OS: Gentoo amd64
Using the
./install.sh install
command randomly results in not isntalling the kernel after compilation. To me it happens roughly 1/8 times. No error is written to the console. Repeated run with no change results in kernel being installed correctly.I'll try to investigate further.