Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Tor
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Container Registry
Model registry
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
The Tor Project
Core
Tor
Commits
1ffb3b54
Unverified
Commit
1ffb3b54
authored
5 years ago
by
teor
Browse files
Options
Downloads
Patches
Plain Diff
scripts/git: Add TOR_EXTRA_REMOTE_* for an extra git remote
When running git-setup-dirs.sh. Part of 32347.
parent
38e8cca6
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
scripts/git/git-setup-dirs.sh
+19
-0
19 additions, 0 deletions
scripts/git/git-setup-dirs.sh
with
19 additions
and
0 deletions
scripts/git/git-setup-dirs.sh
+
19
−
0
View file @
1ffb3b54
...
...
@@ -42,6 +42,14 @@ function usage()
echo
" (current:
$GITHUB_PUSH
)"
echo
" TOR_EXTRA_CLONE_ARGS: extra arguments to git clone"
echo
" (current:
$TOR_EXTRA_CLONE_ARGS
)"
echo
" TOR_EXTRA_REMOTE_NAME: the name of an extra remote"
echo
" This remote is not pulled by this script or git-pull-all.sh."
echo
" This remote is not pushed by git-push-all.sh."
echo
" (current:
$TOR_EXTRA_REMOTE_NAME
)"
echo
" TOR_EXTRA_REMOTE_PULL: the extra remote pull URL."
echo
" (current:
$TOR_EXTRA_REMOTE_PULL
)"
echo
" TOR_EXTRA_REMOTE_PUSH: the extra remote push URL"
echo
" (current:
$TOR_EXTRA_REMOTE_PUSH
)"
echo
" we recommend that you set these env vars in your ~/.profile"
}
...
...
@@ -510,6 +518,17 @@ set_tor_github_pr_fetch_config
# Now fetch them all
fetch_remote
"tor-github"
# Extra remote
if
[
"
$TOR_EXTRA_REMOTE_NAME
"
]
;
then
printf
"%s Setting up remote %s
\\
n"
"
$MARKER
"
\
"
${
BYEL
}
$TOR_EXTRA_REMOTE_NAME
${
CNRM
}
"
# Add remote
add_remote
"
$TOR_EXTRA_REMOTE_NAME
"
"
$TOR_EXTRA_REMOTE_PULL
"
set_remote_push
"
$TOR_EXTRA_REMOTE_NAME
"
"
$TOR_EXTRA_REMOTE_PUSH
"
# But leave it to the user to decide if they want to fetch it
#fetch_remote "$TOR_EXTRA_REMOTE_NAME"
fi
# Go over all configured worktree.
for
((
i
=
0
;
i<COUNT
;
i++
))
;
do
branch
=
${
!WORKTREE[
$i
]
:0:1
}
...
...
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