mirror of
https://github.com/parchlinux/calamares.git
synced 2025-06-26 17:05:36 -04:00
Be more verbose while scanning devices
This commit is contained in:
parent
ef065c1183
commit
232bbe18bc
1 changed files with 11 additions and 3 deletions
|
@ -153,19 +153,27 @@ PartitionCoreModule::doInit()
|
||||||
{
|
{
|
||||||
FileSystemFactory::init();
|
FileSystemFactory::init();
|
||||||
|
|
||||||
|
using DeviceList = QList< Device* >;
|
||||||
|
|
||||||
CoreBackend* backend = CoreBackendManager::self()->backend();
|
CoreBackend* backend = CoreBackendManager::self()->backend();
|
||||||
QList< Device* > devices = backend->scanDevices( true );
|
DeviceList devices = backend->scanDevices( true );
|
||||||
|
|
||||||
|
cDebug() << "Winnowing" << devices.count() << "devices.";
|
||||||
|
|
||||||
// Remove the device which contains / from the list
|
// Remove the device which contains / from the list
|
||||||
for ( QList< Device* >::iterator it = devices.begin(); it != devices.end(); )
|
for ( DeviceList::iterator it = devices.begin(); it != devices.end(); )
|
||||||
if ( ! (*it) || hasRootPartition( *it ) ||
|
if ( ! (*it) || hasRootPartition( *it ) ||
|
||||||
(*it)->deviceNode().startsWith( "/dev/zram") ||
|
(*it)->deviceNode().startsWith( "/dev/zram") ||
|
||||||
isIso9660( *it ) )
|
isIso9660( *it ) )
|
||||||
|
{
|
||||||
|
cDebug() << " .. Winnowing" << ( (*it) ? (*it)->deviceNode() : QString( "<null device>" ) );
|
||||||
it = devices.erase( it );
|
it = devices.erase( it );
|
||||||
|
}
|
||||||
else
|
else
|
||||||
++it;
|
++it;
|
||||||
|
|
||||||
cDebug() << "LIST OF DETECTED DEVICES:\nnode\tcapacity\tname\tprettyName";
|
cDebug() << "LIST OF DETECTED DEVICES:";
|
||||||
|
cDebug() << "node\tcapacity\tname\tprettyName";
|
||||||
for ( auto device : devices )
|
for ( auto device : devices )
|
||||||
{
|
{
|
||||||
auto deviceInfo = new DeviceInfo( device );
|
auto deviceInfo = new DeviceInfo( device );
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue