aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMax Magorsch <arzano@gentoo.org>2020-05-03 15:20:08 +0200
committerMax Magorsch <arzano@gentoo.org>2020-05-03 15:20:08 +0200
commit6ba81ea88d3925a8fbc36c24289e4c94f32b3609 (patch)
treecffc949e66ee251d100802a0712781a9590ae01c /pkg/portage/repository/mask.go
parentIncrease the shm-size of the postgres container (diff)
downloadsoko-6ba81ea88d3925a8fbc36c24289e4c94f32b3609.tar.gz
soko-6ba81ea88d3925a8fbc36c24289e4c94f32b3609.tar.bz2
soko-6ba81ea88d3925a8fbc36c24289e4c94f32b3609.zip
Fix the import of local useflags
So far local useflags have not been imported as use.local.desc is part of .gitignore. This has been fixed in this commit by explicitly importing/updating profiles/use.local.desc during each update. Signed-off-by: Max Magorsch <arzano@gentoo.org>
Diffstat (limited to 'pkg/portage/repository/mask.go')
-rw-r--r--pkg/portage/repository/mask.go22
1 files changed, 15 insertions, 7 deletions
diff --git a/pkg/portage/repository/mask.go b/pkg/portage/repository/mask.go
index c0ee191..ce8fe80 100644
--- a/pkg/portage/repository/mask.go
+++ b/pkg/portage/repository/mask.go
@@ -35,17 +35,25 @@ func UpdateMask(path string) {
splittedLine := strings.Split(path, "\t")
+ var status, changedFile string
if len(splittedLine) == 2 {
- status := splittedLine[0]
- changedFile := splittedLine[1]
+ status = splittedLine[0]
+ changedFile = splittedLine[1]
+ } else if len(splittedLine) == 1 {
+ // This happens in case of a full update
+ status = "A"
+ changedFile = splittedLine[0]
+ } else {
+ // should not happen
+ return
+ }
- if status != "D" && isMask(changedFile) {
+ if status != "D" && isMask(changedFile) {
- logger.Info.Println("Updating Masks")
+ logger.Info.Println("Updating Masks")
- for _, packageMask := range getMasks(changedFile) {
- parsePackageMask(packageMask)
- }
+ for _, packageMask := range getMasks(changedFile) {
+ parsePackageMask(packageMask)
}
}
}