-
Notifications
You must be signed in to change notification settings - Fork 125
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
Add setup.py script to build the package using setuptools #143
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,7 @@ | ||
*.egg-info/ | ||
*.pyc | ||
*.pyo | ||
.tox/ | ||
/*.html | ||
build/ | ||
dist/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
include completions/git-imerge | ||
include COPYING | ||
include t/create-test-repo | ||
include t/test-conflicted | ||
include t/test-drop | ||
include t/test-unconflicted | ||
include tox.ini |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,3 @@ | ||
#! /usr/bin/env python | ||
# -*- coding: utf-8 -*- | ||
|
||
# Copyright 2012-2013 Michael Haggerty <[email protected]> | ||
|
@@ -4137,11 +4136,15 @@ def add_tip2_argument(subparser): | |
parser.error('Unrecognized subcommand') | ||
|
||
|
||
if __name__ == '__main__': | ||
def climain(): | ||
try: | ||
main(sys.argv[1:]) | ||
except Failure as e: | ||
sys.exit(str(e)) | ||
|
||
|
||
if __name__ == "__main__": | ||
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. This block and the |
||
climain() | ||
|
||
|
||
# vim: set expandtab ft=python: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
import errno | ||
import subprocess | ||
|
||
from setuptools import setup | ||
|
||
data_files = [] | ||
try: | ||
completionsdir = subprocess.check_output( | ||
["pkg-config", "--variable=completionsdir", "bash-completion"] | ||
) | ||
except OSError as e: | ||
if e.errno != errno.ENOENT: | ||
raise | ||
else: | ||
completionsdir = completionsdir.strip().decode('utf-8') | ||
if completionsdir: | ||
data_files.append((completionsdir, ["completions/git-imerge"])) | ||
|
||
|
||
setup( | ||
name="gitimerge", | ||
description="Incremental merge for git", | ||
url="https://github.com/mhagger/git-imerge", | ||
author="Michael Haggerty", | ||
author_email="[email protected]", | ||
license="GPLv2+", | ||
version="1.1.0", | ||
py_modules=["gitimerge"], | ||
data_files=data_files, | ||
entry_points={"console_scripts": ["git-imerge = gitimerge:climain"]}, | ||
python_requires=">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*", | ||
classifiers=[ | ||
"Development Status :: 5 - Production/Stable", | ||
"License :: OSI Approved :: GNU General Public License v2 or later (GPLv2+)", | ||
"Programming Language :: Python", | ||
"Programming Language :: Python :: 2", | ||
"Programming Language :: Python :: 2.7", | ||
"Programming Language :: Python :: 3", | ||
"Programming Language :: Python :: 3.4", | ||
"Programming Language :: Python :: 3.5", | ||
"Programming Language :: Python :: 3.6", | ||
"Programming Language :: Python :: 3.7", | ||
], | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
[tox] | ||
envlist = py | ||
|
||
[testenv] | ||
commands = | ||
/bin/sh t/create-test-repo | ||
/bin/sh t/test-unconflicted | ||
/bin/sh t/test-conflicted | ||
/bin/sh t/test-drop |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
Just to be clear...the files under
t/
are only needed for testing. Their inclusion here doesn't imply that they will be installed for end-users, does it?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.
Correct.
It is customary to include test files in an sdist (source distribution).
While these files are included in the .tar.gz file, they are not installed on the user's system.