-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use gitpython for tags #4052
Use gitpython for tags #4052
Changes from 1 commit
02b447f
a096a03
ef619e7
5f5b51a
d050221
b659748
e3e5f87
851d2b8
a6a60d5
65409a8
472eadf
d3e3b5b
f4c53c8
fdba591
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -89,12 +89,24 @@ def make_test_git(): | |
|
||
# Checkout to master branch again | ||
check_output(['git', 'checkout', 'master'], env=env) | ||
|
||
# Create some tags | ||
chdir(path) | ||
return directory | ||
|
||
|
||
def create_tag(directory, tag, annotated=False): | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
and I think that There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Directory makes reference to the tmp directory, and path is used for the cwd, |
||
env = environ.copy() | ||
env['GIT_DIR'] = pjoin(directory, '.git') | ||
path = getcwd() | ||
chdir(directory) | ||
|
||
command = ['git', 'tag'] | ||
if annotated: | ||
command.extend(['-a', '-m', 'Some tag']) | ||
command.append(tag) | ||
check_output(command, env=env) | ||
chdir(path) | ||
|
||
|
||
def make_test_hg(): | ||
directory = mkdtemp() | ||
path = getcwd() | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we need to do this here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because we don't make the
clone
part, so the vcs object will try to search the repo in/project/checkouts/...
. Sorry for the late reply, I was focused in fixin the unicode problem 😁