Skip to content
Permalink
Browse files

port1.0/portlint.tcl:

Check for incorrect svn properties

git-svn-id: https://svn.macports.org/repository/macports/trunk/base@89428 d073be05-634f-4543-b044-5fe20cf6d1d6
  • Loading branch information
raimue committed Jan 28, 2012
1 parent a82f43b commit 29ff33b997b943e6c13f5fafc701fce54a3402fb
Showing with 27 additions and 0 deletions.
  1. +27 −0 src/port1.0/portlint.tcl
@@ -606,6 +606,33 @@ proc portlint::lint_main {args} {
ui_debug "Version: $version"
ui_debug "Revision: $revision"
ui_debug "Archs: $portarch"

###################################################################

set svn_cmd ""
catch {set svn_cmd [findBinary svn]}
if {$svn_cmd != "" && ([file exists $portpath/.svn] || ![catch {exec $svn_cmd info $portpath > /dev/null 2>@1}])} {
ui_debug "Checking svn properties"
if [catch {exec $svn_cmd propget svn:keywords $portfile 2>@1} output] {
ui_warn "Unable to check for svn:keywords property: $output"
} else {
ui_debug "Property svn:keywords is \"$output\", should be \"Id\""
if {$output != "Id"} {
ui_error "Missing subversion property on Portfile, please execute: svn ps svn:keywords Id Portfile"
incr errors
}
}
if [catch {exec $svn_cmd propget svn:eol-style $portfile 2>@1} output] {
ui_warn "Unable to check for svn:eol-style property: $output"
} else {
ui_debug "Property svn:eol-style is \"$output\", should be \"native\""
if {$output != "native"} {
ui_error "Missing subversion property on Portfile, please execute: svn ps svn:eol-tyle native Portfile"
incr errors
}
}
}

###################################################################

ui_notice "$UI_PREFIX [format [msgcat::mc "%d errors and %d warnings found."] $errors $warnings]"

0 comments on commit 29ff33b

Please sign in to comment.
You can’t perform that action at this time.