Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
V
vcsh
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Container registry
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor 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
Kevin Lyda
vcsh
Commits
b40cd1a7
Commit
b40cd1a7
authored
9 years ago
by
Richard Hartmann
Browse files
Options
Downloads
Patches
Plain Diff
vcsh: Handle Git older than 2.x
We will fetch more data than needed with Git 1.8, but other than that...
parent
cf9bd27d
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
vcsh
+6
-1
6 additions, 1 deletion
vcsh
with
6 additions
and
1 deletion
vcsh
+
6
−
1
View file @
b40cd1a7
...
@@ -159,7 +159,12 @@ clone() {
...
@@ -159,7 +159,12 @@ clone() {
You should add files to your new repository."
You should add files to your new repository."
exit
exit
fi
fi
GIT_VERSION_MAJOR
=
$(
git
--version
|
sed
-n
's/.* \([0-9]\)\..*/\1/p'
)
if
[
2
-ge
"
$GIT_VERSION_MAJOR
"
]
;
then
git fetch origin
"
$VCSH_BRANCH
"
git fetch origin
"
$VCSH_BRANCH
"
else
git fetch origin
fi
hook pre-merge
hook pre-merge
git ls-tree
-r
--name-only
origin/
"
$VCSH_BRANCH
"
|
(
while
read
object
;
do
git ls-tree
-r
--name-only
origin/
"
$VCSH_BRANCH
"
|
(
while
read
object
;
do
[
-e
"
$object
"
]
&&
[
-e
"
$object
"
]
&&
...
...
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