Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
k3s
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
k3s
Commits
2363136f
Unverified
Commit
2363136f
authored
Apr 07, 2019
by
Christoph Blecker
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove has_changes logic from vendor scripts
parent
668a2885
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
30 deletions
+8
-30
verify-vendor-licenses.sh
hack/verify-vendor-licenses.sh
+1
-10
verify-vendor.sh
hack/verify-vendor.sh
+7
-20
No files found.
hack/verify-vendor-licenses.sh
View file @
2363136f
...
...
@@ -21,15 +21,6 @@ set -o pipefail
KUBE_ROOT
=
$(
dirname
"
${
BASH_SOURCE
[0]
}
"
)
/..
source
"
${
KUBE_ROOT
}
/hack/lib/init.sh"
readonly
branch
=
${
1
:-${
KUBE_VERIFY_GIT_BRANCH
:-
master
}}
if
!
[[
${
KUBE_FORCE_VERIFY_CHECKS
:-}
=
~ ^[yY]
$
]]
&&
\
!
kube::util::has_changes
"
${
branch
}
"
'Godeps/'
&&
\
!
kube::util::has_changes
"
${
branch
}
"
'go.mod'
&&
\
!
kube::util::has_changes
"
${
branch
}
"
'go.sum'
&&
\
!
kube::util::has_changes
"
${
branch
}
"
'vendor/'
;
then
exit
0
fi
# create a nice clean place to put our new licenses
# must be in the user dir (e.g. KUBE_ROOT) in order for the docker volume mount
# to work with docker-machine on macs
...
...
@@ -40,7 +31,7 @@ function cleanup {
#echo "Removing workspace: ${_tmpdir}"
rm
-rf
"
${
_tmpdir
}
"
}
trap
cleanup EXIT
kube::util::trap_add
cleanup EXIT
cp
-r
"
${
KUBE_ROOT
}
/Godeps"
"
${
_tmpdir
}
/Godeps"
ln
-s
"
${
KUBE_ROOT
}
/LICENSE"
"
${
_tmpdir
}
"
...
...
hack/verify-vendor.sh
View file @
2363136f
...
...
@@ -21,29 +21,16 @@ set -o pipefail
KUBE_ROOT
=
$(
dirname
"
${
BASH_SOURCE
[0]
}
"
)
/..
source
"
${
KUBE_ROOT
}
/hack/lib/init.sh"
readonly
branch
=
${
1
:-${
KUBE_VERIFY_GIT_BRANCH
:-
master
}}
if
!
[[
${
KUBE_FORCE_VERIFY_CHECKS
:-}
=
~ ^[yY]
$
]]
&&
\
!
kube::util::has_changes
"
${
branch
}
"
'Godeps/'
&&
\
!
kube::util::has_changes
"
${
branch
}
"
'go.mod'
&&
\
!
kube::util::has_changes
"
${
branch
}
"
'go.sum'
&&
\
!
kube::util::has_changes
"
${
branch
}
"
'vendor/'
&&
\
!
kube::util::has_changes
"
${
branch
}
"
'staging/'
&&
\
!
kube::util::has_changes
"
${
branch
}
"
'hack/lib/'
&&
\
!
kube::util::has_changes
"
${
branch
}
"
'hack/.*vendor'
;
then
exit
0
fi
if
[[
-z
${
TMP_GOPATH
:-}
]]
;
then
# Create a nice clean place to put our new vendor
_tmpdir
=
"
$(
kube::realpath
"
$(
mktemp
-d
-t
verifyvendor.XXXXXX
)
"
)
"
else
# reuse what we might have saved previously
_tmpdir
=
"
${
TMP_GOPATH
}
"
fi
# create a nice clean place to put our new licenses
# must be in the user dir (e.g. KUBE_ROOT) in order for the docker volume mount
# to work with docker-machine on macs
mkdir
-p
"
${
KUBE_ROOT
}
/_tmp"
_tmpdir
=
"
$(
mktemp
-d
"
${
KUBE_ROOT
}
/_tmp/kube-vendor.XXXXXX"
)
"
if
[[
-z
${
KEEP_TMP
:-}
]]
;
then
KEEP_TMP
=
false
fi
function
cleanup
{
# make go module dirs writeable
chmod
-R
+w
"
${
_tmpdir
}
"
...
...
@@ -54,7 +41,7 @@ function cleanup {
rm
-rf
"
${
_tmpdir
}
"
fi
}
trap
cleanup EXIT
kube::util::trap_add
cleanup EXIT
# Copy the contents of the kube directory into the nice clean place (which is NOT shaped like a GOPATH)
_kubetmp
=
"
${
_tmpdir
}
"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment