Fix license script to handle single-segment packages

This commit is contained in:
Jordan Liggitt 2019-07-31 16:05:50 -04:00
parent 8c8c4113f0
commit 7232c0fd0b

View File

@ -87,9 +87,12 @@ process_content () {
# - gopkg.in/square/go-jose.v2
package_root=$(echo "${package}" |grep -oh '.*\.v[0-9]')
;;
*)
*/*)
package_root=$(echo "${package}" |awk -F/ '{ print $1"/"$2 }')
;;
*)
package_root="${package}"
;;
esac
# Find files - only root and package level