Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • redox-os/installer
  • Sag0Sag0/installer
  • microcolonel/installer
  • mich/installer
  • potatogim/installer
  • bruceadams/installer
  • rw_van/installer
  • carrot93/installer
  • Ivan/installer
  • josh_williams/installer
  • bjorn3/installer
  • freewilll/installer
  • Chocimier/installer
  • andypython/installer
  • 4lDO2/installer
  • amyipdev/installer
  • coolreader18/installer
  • adi-g15/installer
  • enygmator/installer
  • josh/installer
20 results
Show changes
Commits on Source (1)
......@@ -18,6 +18,7 @@ fn main() {
let mut parser = ArgParser::new(4)
.add_opt("b", "cookbook")
.add_opt("c", "config")
.add_flag(&["filesystem-size"])
.add_flag(&["r", "repo-binary"])
.add_flag(&["l", "list-packages"])
.add_flag(&["live"]);
......@@ -51,7 +52,9 @@ fn main() {
config.general.repo_binary = Some(true);
}
if parser.found("list-packages") {
if parser.found("filesystem-size") {
println!("{}", config.general.filesystem_size.unwrap_or(0));
} else if parser.found("list-packages") {
// List the packages that should be fetched or built by the cookbook
for (packagename, package) in &config.packages {
match package {
......
......@@ -3,6 +3,7 @@ pub struct GeneralConfig {
pub prompt: Option<bool>,
// Allow config to specify cookbook recipe or binary package as default
pub repo_binary: Option<bool>,
pub filesystem_size: Option<u32>, //MiB
pub efi_partition_size: Option<u32>, //MiB
}
......@@ -10,6 +11,7 @@ impl GeneralConfig {
pub(super) fn merge(&mut self, other: GeneralConfig) {
self.prompt = other.prompt.or(self.prompt);
self.repo_binary = other.repo_binary.or(self.repo_binary);
self.filesystem_size = other.filesystem_size.or(self.filesystem_size);
self.efi_partition_size = other.efi_partition_size.or(self.efi_partition_size);
}
}