manually merge request #1

This commit is contained in:
guinux 2014-03-05 15:16:51 +01:00
parent f888761d8a
commit 7b04b92144
2 changed files with 4 additions and 1 deletions

View File

@ -18,7 +18,7 @@
# along with this program; if not, write to the Free Software # along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
version = '0.9.7' version = '0.9.8'
from gi.repository import Gtk, Gdk from gi.repository import Gtk, Gdk
import pyalpm import pyalpm

View File

@ -30,6 +30,7 @@ import fnmatch
import dbus import dbus
from dbus.mainloop.glib import DBusGMainLoop from dbus.mainloop.glib import DBusGMainLoop
import signal import signal
import re
from pamac import config, common, aur from pamac import config, common, aur
@ -51,6 +52,7 @@ build_depends = set()
handle = None handle = None
syncdbs = None syncdbs = None
localdb = None localdb = None
colors_regexp = re.compile('\\033\[(\d;)?\d*m')
# i18n # i18n
import gettext import gettext
@ -492,6 +494,7 @@ def check_finished_build(data):
signal.setitimer(signal.ITIMER_REAL, 0.05) # 50 ms timeout signal.setitimer(signal.ITIMER_REAL, 0.05) # 50 ms timeout
try: try:
line = build_proc.stdout.readline().decode(encoding='UTF-8') line = build_proc.stdout.readline().decode(encoding='UTF-8')
line = re.sub(colors_regexp, '', line)
#print(line.rstrip('\n')) #print(line.rstrip('\n'))
progress_buffer.insert_at_cursor(line) progress_buffer.insert_at_cursor(line)
except Exception: except Exception: