Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 142508
Collapse All | Expand All

(-)bin/dispatch-conf (+14 lines)
Lines 213-218 Link Here
213
            show_new_diff = 0
213
            show_new_diff = 0
214
214
215
            while 1:
215
            while 1:
216
                clear_screen()
216
                if show_new_diff:
217
                if show_new_diff:
217
                    os.system((self.options['diff']) % (conf['new'], mrgconf))
218
                    os.system((self.options['diff']) % (conf['new'], mrgconf))
218
                    show_new_diff = 0
219
                    show_new_diff = 0
Lines 366-371 Link Here
366
        termios.tcsetattr(fd, termios.TCSADRAIN, old_settings)
367
        termios.tcsetattr(fd, termios.TCSADRAIN, old_settings)
367
    return ch
368
    return ch
368
369
370
def clear_screen():
371
    try:
372
        import curses
373
        try:
374
            curses.setupterm()
375
            sys.stdout.write(curses.tigetstr("clear"))
376
            sys.stdout.flush()
377
            return
378
        except curses.error:
379
            pass
380
    except ImportError:
381
        pass
382
    os.system("clear 2>/dev/null")
369
383
370
# run
384
# run
371
d = dispatch ()
385
d = dispatch ()

Return to bug 142508