summaryrefslogtreecommitdiff
path: root/src/apk.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/apk.c')
-rw-r--r--src/apk.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/apk.c b/src/apk.c
index 4fce15b..8fb0924 100644
--- a/src/apk.c
+++ b/src/apk.c
@@ -255,8 +255,11 @@ static void on_sigwinch(int s)
static void setup_terminal(void)
{
setvbuf(stderr, NULL, _IOLBF, BUFSIZ);
- if (isatty(STDOUT_FILENO) && isatty(STDERR_FILENO) && isatty(STDIN_FILENO))
+ if (isatty(STDOUT_FILENO) && isatty(STDERR_FILENO) && isatty(STDIN_FILENO)) {
apk_flags |= APK_PROGRESS;
+ if (access("/etc/apk/interactive", F_OK) == 0)
+ apk_flags |= APK_INTERACTIVE;
+ }
signal(SIGWINCH, on_sigwinch);
}