{"action":"created","comment":{"url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/pulls/comments/40935944","id":40935944,"diff_hunk":"@@ -66,16 +80,45 @@ private static void readPropertiesFromFile(String[] args) {\n \t\tString propFileLocation;\n \t\tif(args.length == 0) {\n \t\t\tM_log.error(\"Command line arguments are not provided\");\n-\t\t\tSystem.exit(0);\n+\t\t\tSystem.exit(1);\n \t\t}\n \t\tpropFileLocation = args[0];\n \t\tproperties = Utils.getPropertiesFromURL(propFileLocation);\n \t\tcanvasToken = properties.getProperty(CANVAS_TOKEN);\n \t\tcanvasURL = properties.getProperty(CANVAS_URL);\n \t\tesbURL=properties.getProperty(ESB_URL);\n-\t\tsisTermIdFromPropsFile = properties.getProperty(SIS_TERM_ID);\n+\t\tgetTermsInfoFromProperties(properties);\n \t\tcheckForApiType(properties);\n \t}\n+\t/*\n+\t * The Terms that needs for course deletion are listed in the properties file. Each term has 2 piece of information \n+\t * term1=2030;04/06/15, the sisTermCode and the endDate of that term. We will check if the current system date is\n+\t * past the endDate then that term becomes eligible for deleting the unused/unpublished courses that are created \n+\t * as apart of auto-provisioning of courses in canvas\n+\t * \n+\t */\n+\tprivate static void getTermsInfoFromProperties(Properties properties) {\n+\t\tM_log.debug(\"getTermsInfoFromProperties(): called\");\n+\t\tString termCount = properties.getProperty(TERM_COUNT);\n+\t\tif(termCount.isEmpty()) {\n+\t\t\tM_log.error(\"The property \\\"term.count\\\" is not set in the properties file \\\"canvasCourseDelete.properties\\\"\");","path":"src/main/java/edu/umich/tl/CourseDelete.java","position":106,"original_position":106,"commit_id":"8ddd478db0ffcaf8f0e098c99933c2e75ee4a025","original_commit_id":"8ddd478db0ffcaf8f0e098c99933c2e75ee4a025","user":{"login":"dlhaines","id":74063,"avatar_url":"https://avatars.githubusercontent.com/u/74063?v=3","gravatar_id":"","url":"https://api.github.com/users/dlhaines","html_url":"https://github.com/dlhaines","followers_url":"https://api.github.com/users/dlhaines/followers","following_url":"https://api.github.com/users/dlhaines/following{/other_user}","gists_url":"https://api.github.com/users/dlhaines/gists{/gist_id}","starred_url":"https://api.github.com/users/dlhaines/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dlhaines/subscriptions","organizations_url":"https://api.github.com/users/dlhaines/orgs","repos_url":"https://api.github.com/users/dlhaines/repos","events_url":"https://api.github.com/users/dlhaines/events{/privacy}","received_events_url":"https://api.github.com/users/dlhaines/received_events","type":"User","site_admin":false},"body":"Good comment.  The user will know what the problem is.","created_at":"2015-10-01T16:40:26Z","updated_at":"2015-10-01T16:40:26Z","html_url":"https://github.com/tl-its-umich-edu/canvasCourseDeleteUtility/pull/4#discussion_r40935944","pull_request_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/pulls/4","_links":{"self":{"href":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/pulls/comments/40935944"},"html":{"href":"https://github.com/tl-its-umich-edu/canvasCourseDeleteUtility/pull/4#discussion_r40935944"},"pull_request":{"href":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/pulls/4"}}},"pull_request":{"url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/pulls/4","id":46536956,"html_url":"https://github.com/tl-its-umich-edu/canvasCourseDeleteUtility/pull/4","diff_url":"https://github.com/tl-its-umich-edu/canvasCourseDeleteUtility/pull/4.diff","patch_url":"https://github.com/tl-its-umich-edu/canvasCourseDeleteUtility/pull/4.patch","issue_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/issues/4","number":4,"state":"open","locked":false,"title":"Tlunizin 148-Getting the terms info for deleting courses from properties file","user":{"login":"pushyamig","id":8579775,"avatar_url":"https://avatars.githubusercontent.com/u/8579775?v=3","gravatar_id":"","url":"https://api.github.com/users/pushyamig","html_url":"https://github.com/pushyamig","followers_url":"https://api.github.com/users/pushyamig/followers","following_url":"https://api.github.com/users/pushyamig/following{/other_user}","gists_url":"https://api.github.com/users/pushyamig/gists{/gist_id}","starred_url":"https://api.github.com/users/pushyamig/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pushyamig/subscriptions","organizations_url":"https://api.github.com/users/pushyamig/orgs","repos_url":"https://api.github.com/users/pushyamig/repos","events_url":"https://api.github.com/users/pushyamig/events{/privacy}","received_events_url":"https://api.github.com/users/pushyamig/received_events","type":"User","site_admin":false},"body":"@dlhaines @lsloan due10/5/15","created_at":"2015-10-01T15:17:13Z","updated_at":"2015-10-01T16:40:26Z","closed_at":null,"merged_at":null,"merge_commit_sha":"3d9d0d9c936a347f871d03c0c78868e3018fd06e","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/pulls/4/commits","review_comments_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/pulls/4/comments","review_comment_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/pulls/comments{/number}","comments_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/issues/4/comments","statuses_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/statuses/8ddd478db0ffcaf8f0e098c99933c2e75ee4a025","head":{"label":"tl-its-umich-edu:TLUNIZIN-148","ref":"TLUNIZIN-148","sha":"8ddd478db0ffcaf8f0e098c99933c2e75ee4a025","user":{"login":"tl-its-umich-edu","id":8292960,"avatar_url":"https://avatars.githubusercontent.com/u/8292960?v=3","gravatar_id":"","url":"https://api.github.com/users/tl-its-umich-edu","html_url":"https://github.com/tl-its-umich-edu","followers_url":"https://api.github.com/users/tl-its-umich-edu/followers","following_url":"https://api.github.com/users/tl-its-umich-edu/following{/other_user}","gists_url":"https://api.github.com/users/tl-its-umich-edu/gists{/gist_id}","starred_url":"https://api.github.com/users/tl-its-umich-edu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tl-its-umich-edu/subscriptions","organizations_url":"https://api.github.com/users/tl-its-umich-edu/orgs","repos_url":"https://api.github.com/users/tl-its-umich-edu/repos","events_url":"https://api.github.com/users/tl-its-umich-edu/events{/privacy}","received_events_url":"https://api.github.com/users/tl-its-umich-edu/received_events","type":"Organization","site_admin":false},"repo":{"id":41931279,"name":"canvasCourseDeleteUtility","full_name":"tl-its-umich-edu/canvasCourseDeleteUtility","owner":{"login":"tl-its-umich-edu","id":8292960,"avatar_url":"https://avatars.githubusercontent.com/u/8292960?v=3","gravatar_id":"","url":"https://api.github.com/users/tl-its-umich-edu","html_url":"https://github.com/tl-its-umich-edu","followers_url":"https://api.github.com/users/tl-its-umich-edu/followers","following_url":"https://api.github.com/users/tl-its-umich-edu/following{/other_user}","gists_url":"https://api.github.com/users/tl-its-umich-edu/gists{/gist_id}","starred_url":"https://api.github.com/users/tl-its-umich-edu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tl-its-umich-edu/subscriptions","organizations_url":"https://api.github.com/users/tl-its-umich-edu/orgs","repos_url":"https://api.github.com/users/tl-its-umich-edu/repos","events_url":"https://api.github.com/users/tl-its-umich-edu/events{/privacy}","received_events_url":"https://api.github.com/users/tl-its-umich-edu/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/tl-its-umich-edu/canvasCourseDeleteUtility","description":"","fork":false,"url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility","forks_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/forks","keys_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/keys{/key_id}","collaborators_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/teams","hooks_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/hooks","issue_events_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/issues/events{/number}","events_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/events","assignees_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/assignees{/user}","branches_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/branches{/branch}","tags_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/tags","blobs_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/git/refs{/sha}","trees_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/git/trees{/sha}","statuses_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/statuses/{sha}","languages_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/languages","stargazers_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/stargazers","contributors_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/contributors","subscribers_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/subscribers","subscription_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/subscription","commits_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/commits{/sha}","git_commits_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/git/commits{/sha}","comments_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/comments{/number}","issue_comment_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/issues/comments{/number}","contents_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/contents/{+path}","compare_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/compare/{base}...{head}","merges_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/merges","archive_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/downloads","issues_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/issues{/number}","pulls_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/pulls{/number}","milestones_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/milestones{/number}","notifications_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/labels{/name}","releases_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/releases{/id}","created_at":"2015-09-04T18:21:53Z","updated_at":"2015-09-10T14:18:56Z","pushed_at":"2015-10-01T15:20:59Z","git_url":"git://github.com/tl-its-umich-edu/canvasCourseDeleteUtility.git","ssh_url":"git@github.com:tl-its-umich-edu/canvasCourseDeleteUtility.git","clone_url":"https://github.com/tl-its-umich-edu/canvasCourseDeleteUtility.git","svn_url":"https://github.com/tl-its-umich-edu/canvasCourseDeleteUtility","homepage":null,"size":212,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"tl-its-umich-edu:master","ref":"master","sha":"ec9be7014e2b05c4948adddafadc30ea63d47743","user":{"login":"tl-its-umich-edu","id":8292960,"avatar_url":"https://avatars.githubusercontent.com/u/8292960?v=3","gravatar_id":"","url":"https://api.github.com/users/tl-its-umich-edu","html_url":"https://github.com/tl-its-umich-edu","followers_url":"https://api.github.com/users/tl-its-umich-edu/followers","following_url":"https://api.github.com/users/tl-its-umich-edu/following{/other_user}","gists_url":"https://api.github.com/users/tl-its-umich-edu/gists{/gist_id}","starred_url":"https://api.github.com/users/tl-its-umich-edu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tl-its-umich-edu/subscriptions","organizations_url":"https://api.github.com/users/tl-its-umich-edu/orgs","repos_url":"https://api.github.com/users/tl-its-umich-edu/repos","events_url":"https://api.github.com/users/tl-its-umich-edu/events{/privacy}","received_events_url":"https://api.github.com/users/tl-its-umich-edu/received_events","type":"Organization","site_admin":false},"repo":{"id":41931279,"name":"canvasCourseDeleteUtility","full_name":"tl-its-umich-edu/canvasCourseDeleteUtility","owner":{"login":"tl-its-umich-edu","id":8292960,"avatar_url":"https://avatars.githubusercontent.com/u/8292960?v=3","gravatar_id":"","url":"https://api.github.com/users/tl-its-umich-edu","html_url":"https://github.com/tl-its-umich-edu","followers_url":"https://api.github.com/users/tl-its-umich-edu/followers","following_url":"https://api.github.com/users/tl-its-umich-edu/following{/other_user}","gists_url":"https://api.github.com/users/tl-its-umich-edu/gists{/gist_id}","starred_url":"https://api.github.com/users/tl-its-umich-edu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tl-its-umich-edu/subscriptions","organizations_url":"https://api.github.com/users/tl-its-umich-edu/orgs","repos_url":"https://api.github.com/users/tl-its-umich-edu/repos","events_url":"https://api.github.com/users/tl-its-umich-edu/events{/privacy}","received_events_url":"https://api.github.com/users/tl-its-umich-edu/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/tl-its-umich-edu/canvasCourseDeleteUtility","description":"","fork":false,"url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility","forks_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/forks","keys_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/keys{/key_id}","collaborators_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/teams","hooks_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/hooks","issue_events_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/issues/events{/number}","events_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/events","assignees_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/assignees{/user}","branches_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/branches{/branch}","tags_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/tags","blobs_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/git/refs{/sha}","trees_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/git/trees{/sha}","statuses_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/statuses/{sha}","languages_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/languages","stargazers_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/stargazers","contributors_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/contributors","subscribers_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/subscribers","subscription_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/subscription","commits_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/commits{/sha}","git_commits_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/git/commits{/sha}","comments_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/comments{/number}","issue_comment_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/issues/comments{/number}","contents_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/contents/{+path}","compare_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/compare/{base}...{head}","merges_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/merges","archive_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/downloads","issues_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/issues{/number}","pulls_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/pulls{/number}","milestones_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/milestones{/number}","notifications_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/labels{/name}","releases_url":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/releases{/id}","created_at":"2015-09-04T18:21:53Z","updated_at":"2015-09-10T14:18:56Z","pushed_at":"2015-10-01T15:20:59Z","git_url":"git://github.com/tl-its-umich-edu/canvasCourseDeleteUtility.git","ssh_url":"git@github.com:tl-its-umich-edu/canvasCourseDeleteUtility.git","clone_url":"https://github.com/tl-its-umich-edu/canvasCourseDeleteUtility.git","svn_url":"https://github.com/tl-its-umich-edu/canvasCourseDeleteUtility","homepage":null,"size":212,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/pulls/4"},"html":{"href":"https://github.com/tl-its-umich-edu/canvasCourseDeleteUtility/pull/4"},"issue":{"href":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/issues/4"},"comments":{"href":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/issues/4/comments"},"review_comments":{"href":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/pulls/4/comments"},"review_comment":{"href":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/pulls/4/commits"},"statuses":{"href":"https://api.github.com/repos/tl-its-umich-edu/canvasCourseDeleteUtility/statuses/8ddd478db0ffcaf8f0e098c99933c2e75ee4a025"}}}}