6 Commits
Author SHA1 Message Date
William Douglas 04eee0d0bb Mass lint cleanups
Two left over that are logic changes to be addressed in the next
commit.

Signed-off-by: William Douglas <william.douglas@intel.com>
2024-01-30 11:42:32 -08:00
Ashlesha Atrey f6dcd44f21 Implement logging for mixer
Implement the logging package for mixer.

A common log file can be set for all the mixer commands in the
builder.conf. E.g. `mixer config set Mixer.LOG <filepath>`

The log file and level can also be set for individual mixer
commands using the `--log` and `--log-level` flags respectively.

The various log levels are:
ERROR (1), WARNING (2), INFO (3), DEBUG (4) and VERBOSE (5).
Default log level is 4.

Fixes #666

Signed-off-by: Ashlesha Atrey ashlesha.atrey@intel.com
2020-04-30 13:57:58 -07:00
Caio Marcelo de Oliveira Filho fb2e3f5dd2 builder: don't use logger date/time
Logger default date/time are prefixes and don't play well when
printing multiple lines.  What usually matters is the amount of time
elapsed since the start, so print that instead (when each new entry
that is not the first is starting).
2019-03-04 15:49:03 +00:00
Caio Marcelo de Oliveira Filho 3b79fe2fc7 builder: fix spurious print in stopWatch
Likely a typo when converting to the logger interface. Stops printing
a memory address of the writer given to the stopWatch and just print a
newline.
2019-03-04 16:45:34 +01:00
Rodrigo Chiossi fdb8288298 builder: Handle write error on Stopwatch buffer
Use the logger interface to write stopwatch output. With this change,
any error that occurs while trying to write the output is handled
internally by the log module.

This patch also fix a bug where the line break was printed to STDOUT
instead of the stopwatch buffer.

Signed-off-by: Rodrigo Chiossi <rodrigo.chiossi@intel.com>
2018-10-23 10:04:52 -07:00
Caio Marcelo de Oliveira Filho 68bbef0daa builder: time the main steps in BuildUpdate
Add a small struct to count the time taken by the important steps of
BuildUpdate. This will make easier to compare when we move the steps
to use the new swupd implementation -- and might be useful to keep
even after that comparison is not needed.

Signed-off-by: Caio Marcelo de Oliveira Filho <caio.oliveira@intel.com>
2018-01-17 10:43:36 -08:00