mirror of
https://github.com/aptly-dev/aptly.git
synced 2026-10-21 10:58:23 +00:00
Default distribution/component could be specified when creating repo. #12
This commit is contained in:
1 parent
7f2f435e2d
commit
0f8f43b9f0
38 files changed
+113
-49
No files matched your search
@@ -15,6 +15,8 @@ func aptlyRepoCreate(cmd *commander.Command, args []string) error {
|
||||
}
|
||||
|
||||
repo := debian.NewLocalRepo(args[0], cmd.Flag.Lookup("comment").Value.String())
|
||||
repo.DefaultDistribution = cmd.Flag.Lookup("distribution").Value.String()
|
||||
repo.DefaultComponent = cmd.Flag.Lookup("component").Value.String()
|
||||
|
||||
err = context.collectionFactory.LocalRepoCollection().Add(repo)
|
||||
if err != nil {
|
||||
@@ -43,6 +45,8 @@ Example:
|
||||
}
|
||||
|
||||
cmd.Flag.String("comment", "", "any text that would be used to described local repository")
|
||||
cmd.Flag.String("distribution", "", "default distribution when publishing")
|
||||
cmd.Flag.String("component", "main", "default component when publishing")
|
||||
|
||||
return cmd
|
||||
}
|
||||
Reference in new issue
Block a user