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
003c77f2
Commit
003c77f2
authored
Mar 14, 2016
by
k8s-merge-robot
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #22949 from ixdy/verify-all
Auto commit by PR queue bot
parents
9c1e6926
457b9d36
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
3 deletions
+10
-3
util.sh
hack/lib/util.sh
+10
-3
No files found.
hack/lib/util.sh
View file @
003c77f2
...
@@ -332,13 +332,20 @@ kube::util::has_changes_against_upstream_branch() {
...
@@ -332,13 +332,20 @@ kube::util::has_changes_against_upstream_branch() {
echo
"Checking for '
${
pattern
}
' changes against '
${
full_branch
}
'"
echo
"Checking for '
${
pattern
}
' changes against '
${
full_branch
}
'"
# make sure the branch is valid, otherwise the check will pass erroneously.
# make sure the branch is valid, otherwise the check will pass erroneously.
if
!
git describe
"
${
full_branch
}
"
>
/dev/null
;
then
if
!
git describe
"
${
full_branch
}
"
>
/dev/null
;
then
# abort!
exit
1
exit
1
fi
fi
# notice this uses ... to find the first shared ancestor
# notice this uses ... to find the first shared ancestor
if
!
git diff
--name-only
"
${
full_branch
}
...HEAD"
|
grep
"
${
pattern
}
"
>
/dev/null
;
then
if
git diff
--name-only
"
${
full_branch
}
...HEAD"
|
grep
"
${
pattern
}
"
>
/dev/null
;
then
echo
"No '
${
pattern
}
' changes detected."
return
0
return
1
fi
fi
# also check for pending changes
if
git status
--porcelain
|
grep
"
${
pattern
}
"
>
/dev/null
;
then
echo
"Detected '
${
pattern
}
' uncommitted changes."
return
0
fi
echo
"No '
${
pattern
}
' changes detected."
return
1
}
}
# ex: ts=2 sw=2 et filetype=sh
# ex: ts=2 sw=2 et filetype=sh
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