reworked examples

main
Michal 2 years ago
parent a576848703
commit 6074f6cab8
No known key found for this signature in database
GPG Key ID: A6A1A4DCB22279B9

6
.gitignore vendored

@ -2,5 +2,7 @@
.idea
.direnv
example*/*
!example*/mlc.toml
examples/workspace/*
examples/repository/*
!examples/workspace/mlc.toml
!examples/repository/mlc.toml

@ -0,0 +1,24 @@
[base]
mode = "repository"
smart_pull = true
[mode.repository]
name = "repository-test"
build_on_update = true
[mode.repository.signing]
enabled = true
key = "michal@tar.black"
on_gen = true
[mode.workspace]
[repositories]
name = [
"1::crystal-keyring",
"2::pfetch!",
]
urls = [
"https://github.com/crystal-linux/%repo%",
"https://github.com/crystal-linux/pkgbuild.%repo%",
]

@ -9,4 +9,5 @@ pub enum AppExitCode {
NoPkgs = 8,
ConfigParseError = 9,
NoPackagesFound = 10,
InvalidRepo = 11,
}

@ -81,6 +81,14 @@ pub fn generate(verbose: bool) {
.wait()
.unwrap();
// This should never happen, crash and burn if it does
if zst.success() && xz.success() {
crash!(
AppExitCode::InvalidRepo,
"Both .tar.zst and .tar.xz files found in repository. You've done something wrong. Aborting"
);
}
// Ensuring aarch64/ALARM support for the future
let aarch64_mode = if zst.success() {
false

Loading…
Cancel
Save