From: Julien Nicoulaud Date: Sat, 18 Jan 2020 12:43:22 +0000 (+0100) Subject: add basic support for --repositories option for Arch Linux X-Git-Tag: v6~92^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F398%2Fhead;p=thirdparty%2Fmkosi.git add basic support for --repositories option for Arch Linux --- diff --git a/mkosi b/mkosi index f0d51204f..57ca60e0e 100755 --- a/mkosi +++ b/mkosi @@ -1923,6 +1923,19 @@ SigLevel = Required DatabaseOptional TrustAll [community] {server} +""") + + if args.repositories: + for repository in args.repositories: + # repositories must be passed in the form :: + repository_name, repository_server = repository.split('::', 1) + + # note: for additional repositories, signature checking options are set to pacman's default values + f.write(f"""\ + +[{repository_name}] +SigLevel = Optional TrustedOnly +Server = {repository_server} """) def run_pacman(args: List[str], **kwargs: Any) -> subprocess.CompletedProcess: diff --git a/mkosi.md b/mkosi.md index 0d63b37d7..beadc5990 100644 --- a/mkosi.md +++ b/mkosi.md @@ -181,7 +181,9 @@ details see the table below. one or more URLs as argument, separated by commas. This option may be used multiple times, in which case the list of repositories to use is combined. Use "!\*" to remove all repositories from to the list - or use e.g. "!repo-url" to remove just one specific repository. + or use e.g. "!repo-url" to remove just one specific repository. For Arch + Linux, additional repositories must be passed in the form `::` + (e.g. `myrepo::https://myrepo.net`). `--architecture=`