Skip to content

Commit

Permalink
port mirror: Respect special license NoMirror
Browse files Browse the repository at this point in the history
Use this license to prevent mirroring of ports which license does not
allow to host their distfiles on our servers.
  • Loading branch information
raimue authored and neverpanic committed Mar 12, 2018
1 parent 521e014 commit fae17c2
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/port1.0/portmirror.tcl
Expand Up @@ -51,7 +51,12 @@ namespace eval portmirror {
# It also records the path in a database.

proc portmirror::mirror_main {args} {
global fetch.type mirror_filemap portdbpath
global fetch.type mirror_filemap portdbpath subport license

if {[lsearch -exact -nocase $license "nomirror"] >= 0} {
ui_info "Not mirroring $subport due to license NoMirror"
return
}

set mirror_filemap_path [file join $portdbpath distfiles_mirror.db]
filemap open mirror_filemap $mirror_filemap_path
Expand Down

0 comments on commit fae17c2

Please sign in to comment.