Message ID | 1431726052-6519-7-git-send-email-joe.hershberger@ni.com |
---|---|
State | Superseded |
Delegated to: | Masahiro Yamada |
Headers | show |
2015-05-16 6:40 GMT+09:00 Joe Hershberger <joe.hershberger@ni.com>: > If boards fail, output that list to a file so that it can easily be > passed back into moveconfig.py using the -d option. > > Signed-off-by: Joe Hershberger <joe.hershberger@ni.com> > --- > > Changes in v4: None > Changes in v3: None > Changes in v2: None > > tools/moveconfig.py | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/tools/moveconfig.py b/tools/moveconfig.py > index 15b0f2b..9e923da 100755 > --- a/tools/moveconfig.py > +++ b/tools/moveconfig.py > @@ -728,6 +728,10 @@ class Slots: > for line in msg: > print >> sys.stderr, color_text(self.options.color, > COLOR_LIGHT_RED, line) > + ffail = open('moveconfig.failed', 'w') > + for failed_board in failed_boards: > + ffail.write("%s\n" % failed_board) > + ffail.close() > > def move_config(config_attrs, options): > """Move config options to defconfig files. If you use with ... as ..., it will automatically close the file on exit. with open('moveconfig.failed', 'w') as f: for board in failed_boards: f.write(board + '\n')
Hi Masahiro-san, On Mon, May 18, 2015 at 10:12 PM, Masahiro Yamada <yamada.masahiro@socionext.com> wrote: > 2015-05-16 6:40 GMT+09:00 Joe Hershberger <joe.hershberger@ni.com>: >> If boards fail, output that list to a file so that it can easily be >> passed back into moveconfig.py using the -d option. >> >> Signed-off-by: Joe Hershberger <joe.hershberger@ni.com> >> --- >> >> Changes in v4: None >> Changes in v3: None >> Changes in v2: None >> >> tools/moveconfig.py | 4 ++++ >> 1 file changed, 4 insertions(+) >> >> diff --git a/tools/moveconfig.py b/tools/moveconfig.py >> index 15b0f2b..9e923da 100755 >> --- a/tools/moveconfig.py >> +++ b/tools/moveconfig.py >> @@ -728,6 +728,10 @@ class Slots: >> for line in msg: >> print >> sys.stderr, color_text(self.options.color, >> COLOR_LIGHT_RED, line) >> + ffail = open('moveconfig.failed', 'w') >> + for failed_board in failed_boards: >> + ffail.write("%s\n" % failed_board) >> + ffail.close() >> >> def move_config(config_attrs, options): >> """Move config options to defconfig files. > > > If you use with ... as ..., it will automatically close > the file on exit. > > with open('moveconfig.failed', 'w') as f: > for board in failed_boards: > f.write(board + '\n') OK. -Joe
diff --git a/tools/moveconfig.py b/tools/moveconfig.py index 15b0f2b..9e923da 100755 --- a/tools/moveconfig.py +++ b/tools/moveconfig.py @@ -728,6 +728,10 @@ class Slots: for line in msg: print >> sys.stderr, color_text(self.options.color, COLOR_LIGHT_RED, line) + ffail = open('moveconfig.failed', 'w') + for failed_board in failed_boards: + ffail.write("%s\n" % failed_board) + ffail.close() def move_config(config_attrs, options): """Move config options to defconfig files.
If boards fail, output that list to a file so that it can easily be passed back into moveconfig.py using the -d option. Signed-off-by: Joe Hershberger <joe.hershberger@ni.com> --- Changes in v4: None Changes in v3: None Changes in v2: None tools/moveconfig.py | 4 ++++ 1 file changed, 4 insertions(+)