mirror of
https://github.com/rocky-linux/srpmproc.git
synced 2025-01-07 17:00:56 +00:00
Fix metadata creation and simplify deduplication
This commit is contained in:
parent
0db0040f1d
commit
b699ae6dac
1 changed files with 5 additions and 3 deletions
|
@ -220,11 +220,13 @@ func ProcessRPM(pd *ProcessData) {
|
|||
log.Fatalf("could not create metadata file: %v", err)
|
||||
}
|
||||
for _, source := range md.sourcesToIgnore {
|
||||
if source.expired {
|
||||
sourcePath := source.name
|
||||
|
||||
_, err := w.Filesystem.Stat(sourcePath)
|
||||
if source.expired || err != nil {
|
||||
continue
|
||||
}
|
||||
|
||||
sourcePath := source.name
|
||||
sourceFile, err := w.Filesystem.Open(sourcePath)
|
||||
if err != nil {
|
||||
log.Fatalf("could not open ignored source file %s: %v", sourcePath, err)
|
||||
|
@ -246,7 +248,7 @@ func ProcessRPM(pd *ProcessData) {
|
|||
log.Fatalf("could not write to metadata file: %v", err)
|
||||
}
|
||||
|
||||
path := fmt.Sprintf("%s", checksum)
|
||||
path := checksum
|
||||
if strContains(alreadyUploadedBlobs, path) {
|
||||
continue
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue