Created
June 29, 2011 16:47
-
-
Save miratcan/1054283 to your computer and use it in GitHub Desktop.
Simple script for migrating from pivotaltracker to github
This file contains hidden or 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
from github2.client import Github | |
from csv import reader as CsvReader | |
# FILL INFORMATION BELOW | |
# your username at github | |
GITHUB_USERNAME = "" | |
# your api token, you can find it at https://github.com/account/admin | |
GITHUB_API_TOKEN = "" | |
# path to file that you exported from pivotal tracker | |
PROJECT_CSV_PATH = "" | |
# project path at github like: "user/projectname" | |
GITHUB_PROJECT_PATH = "" | |
github = Github( | |
username=GITHUB_USERNAME, | |
api_token=GITHUB_API_TOKEN, | |
request_per_second=1) | |
reader = CsvReader(open(PROJECT_CSV_PATH, "r"), delimiter=",") | |
for row in reader: | |
print "title :", row[1] | |
print "description :", row[14] | |
print "--------" | |
github.issues.open(GITHUB_PROJECT_PATH, title=row[1], body=row[14]) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment