Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
M
marlin-anet-a8
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Jonas Leder
marlin-anet-a8
Commits
eede8679
Commit
eede8679
authored
7 years ago
by
Scott Lahteine
Browse files
Options
Downloads
Patches
Plain Diff
Fix up git helper scripts
parent
1f2acc33
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
buildroot/share/git/mfpub
+20
-12
20 additions, 12 deletions
buildroot/share/git/mfpub
buildroot/share/git/mfup
+2
-0
2 additions, 0 deletions
buildroot/share/git/mfup
with
22 additions
and
12 deletions
buildroot/share/git/mfpub
+
20
−
12
View file @
eede8679
...
...
@@ -35,7 +35,7 @@ fi
echo
"Stashing any changes to files..."
echo
"Don't forget to update and push 'master'!"
# GOJF Card
git stash
[[
$(
git stash
)
!=
"No local "
*
]]
&&
HAS_STASH
=
1
COMMIT
=
$(
git log
--format
=
"%H"
-n
1
)
...
...
@@ -46,7 +46,10 @@ git clean -d -f
if
[[
$BRANCH
==
"master"
]]
;
then
# Don't lose upstream changes!
mfup
git fetch upstream
# Rebase onto latest master
if
git rebase upstream/master
;
then
# Allow working directly with the main fork
echo
...
...
@@ -57,6 +60,13 @@ if [[ $BRANCH == "master" ]]; then
echo
-n
"Pushing to upstream/master... "
git push
-f
upstream
else
echo
"Merge conflicts? Stopping here."
exit
fi
else
if
[
-z
"
$(
git branch
-vv
|
grep
^
\*
|
grep
\\
[
origin
)
"
]
;
then
...
...
@@ -114,6 +124,4 @@ rm -rf ${TMPFOLDER}
# Go back to the branch we started from
git checkout
$BRANCH
if
[[
$BRANCH
!=
"master"
]]
;
then
git stash pop
fi
[[
$HAS_STASH
==
1
]]
&&
git stash pop
This diff is collapsed.
Click to expand it.
buildroot/share/git/mfup
+
2
−
0
View file @
eede8679
...
...
@@ -38,6 +38,8 @@ if [[ $BRANCH != $TARG ]]; then
else
echo
"No such branch!"
fi
else
git reset
--hard
upstream/
$TARG
fi
echo
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment