ACC SHELL

Path : /usr/share/YaST2/include/packager/
File Upload :
Current File : //usr/share/YaST2/include/packager/storage_include.ycp

/**
 * File:	include/packager/storage_include.ycp
 * Module:	Packager
 * Summary:	Storage calls
 * Authors:	Lukas Ocilka <locilka@suse.cz>
 *
 * $Id: storage_include.ycp 57028 2009-04-29 10:58:09Z lslezak $
 *
 */
{
    textdomain "installation";

    import "SourceManager";

    /**
     * Function releases the the device when EVMS is used and the install
     * source is disk. See bugzilla 208222 for more details.
     */
    void ReleaseHDDUsedAsInstallationSource () {
	string install_src_partition = SourceManager::InstallationSourceOnPartition();
	if (install_src_partition != "") {
	    if (! regexpmatch(install_src_partition, "/dev/"))
		install_src_partition = sformat ("/dev/%1", install_src_partition);

	    y2milestone ("Calling Storage::RemoveDmMapsTo(%1)", install_src_partition);
	    any ret = WFM::call("wrapper_storage", ["RemoveDmMapsTo", [install_src_partition]]);
	    y2milestone("Storage::RemoveDmMapsTo(%1) result: %2", install_src_partition, ret);
	}
    }
}

ACC SHELL 2018