apt-get: How to bypass pressing ENTER
This message stems from a call to add-apt-repository
.
You can circumvent it with the -y
/--yes
flag. See the manpage
for example like this:
sudo add-apt-repository --yes ppa:example/repository
Perhaps you can consider the --force-yes
flag. From the manpage:
--force-yes Force yes; this is a dangerous option that will cause apt to continue without prompting if it is doing something potentially harmful. It should not be used except in very special situations. Using force-yes can potentially destroy your system! Configuration Item: APT::Get::force-yes.
So... caveat emptor
You can make these flags permanent as well. Create a file in /etc/apt/apt.conf.d/, like /etc/apt/apt.conf.d/90_no_prompt with the following:
APT::Get::Assume-Yes "true";APT::Get::force-yes "true";