deviceinfo: add heimdall partitions / make flasher variables optional

This commit is contained in:
Oliver Smith 2017-07-10 20:17:31 +02:00
parent 51bdc24315
commit efab009a1f
No known key found for this signature in database
GPG key ID: 5AE7F5513E0885CB
9 changed files with 84 additions and 27 deletions

View file

@ -18,6 +18,7 @@ along with pmbootstrap. If not, see <http://www.gnu.org/licenses/>.
"""
import logging
import os
import pmb.config
def deviceinfo(args, device=None):
@ -48,4 +49,10 @@ def deviceinfo(args, device=None):
key = split[0][len("deviceinfo_"):]
value = split[1].replace("\"", "").replace("\n", "")
ret[key] = value
# Assign empty string as default
for key in pmb.config.deviceinfo_attributes:
if key not in ret:
ret[key] = ""
return ret