This email list is read-only. Emails sent to this list will be discarded
----------------------------------
debian/changelog | 5 +++--
libs/mic_cfg.py | 7 ++++---
libs/pdk_utils.py | 12 +++++++++++-
3 files changed, 18 insertions(+), 6 deletions(-)
New commits:
commit 5720dc4fa3f5a4469c83982e6a585f5fd0768e22
Author: Prajwal Mohan <[EMAIL PROTECTED]>
Date: Sun Aug 17 11:06:19 2008 -0700
Minor changes to pdk_utils and mic_cfg
Diff in this email is a maximum of 400 lines.
diff --git a/debian/changelog b/debian/changelog
index 3c89e5f..9b38265 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -104,9 +104,10 @@ moblin-image-creator (0.45) UNRELEASED; urgency=low
[ Prajwal Mohan ]
* Adding nand to command line
* Adding repo editor and changes to gui
- * Adding conflicts to fsets
+ * Adding conflicts to fsets
+ * Minor changes to pdk_utils and mic_cfg
- -- Prajwal Mohan <[EMAIL PROTECTED]> Sun, 17 Aug 2008 11:01:31 -0700
+ -- Prajwal Mohan <[EMAIL PROTECTED]> Sun, 17 Aug 2008 11:05:50 -0700
moblin-image-creator (0.44) gaston; urgency=low
diff --git a/libs/mic_cfg.py b/libs/mic_cfg.py
index e146e6e..1981d04 100755
--- a/libs/mic_cfg.py
+++ b/libs/mic_cfg.py
@@ -156,13 +156,14 @@ def addDefaults():
config.set(section, option, value)
# What distribution are we running on
dist = platform.dist()[0]
- config.set('general', 'distribution', dist)
if dist == "debian":
pkg_manager = "apt"
- elif dist == "fedora":
+ elif dist == "fedora" or dist == "redhat":
+ dist = "fedora"
pkg_manager = "yum"
else:
- pkg_manager = _("unsupported distribution")
+ pkg_manager = "unsupported distribution"
+ config.set('general', 'distribution', dist)
config.set('general', 'package_manager', pkg_manager)
if '__main__' == __name__:
diff --git a/libs/pdk_utils.py b/libs/pdk_utils.py
index 045b224..768f6d3 100755
--- a/libs/pdk_utils.py
+++ b/libs/pdk_utils.py
@@ -123,8 +123,17 @@ def get_current_udisks():
work_list = getUsbDirTree(dirname)
usb_list = [ x for x in work_list if re.search(r'usb', x) ]
for filename in usb_list:
+ print _("usb_list file is %s") % filename
device_dir = os.path.join('/sys/devices', filename)
- if os.path.isdir(device_dir):
+ block_dir = os.path.join(device_dir, 'block')
+ if (os.path.isdir(block_dir)) :
+ for result in os.listdir(block_dir):
+ print result
+ usb_dev = os.path.join('/dev',result)
+ if os.path.exists(usb_dev):
+ usb_devices.append(usb_dev)
+ break
+ elif os.path.isdir(device_dir):
for device_file in os.listdir(device_dir):
full_path = os.path.join(device_dir, device_file)
result = re.search(r'^block:(?P<dev>.*)', device_file)
@@ -132,6 +141,7 @@ def get_current_udisks():
usb_dev = os.path.join('/dev', result.group('dev'))
if os.path.exists(usb_dev):
usb_devices.append(usb_dev)
+ break
return usb_devices
def getUsbDirTree(dirname):
_______________________________________________
Commits mailing list
[email protected]
https://www.moblin.org/mailman/listinfo/commits