Commits

Britton Smith committed 4ca41eb

Added function to get the date of the last run of the install script.

  • Participants
  • Parent commits 288b124
  • Branches yt

Comments (0)

Files changed (1)

File yt/utilities/command_line.py

 
     )
 
+def _get_yt_stack_date():
+    if "YT_DEST" not in os.environ:
+        print "Could not determine when yt stack was last updated."
+        return
+    date_file = os.path.join(os.environ["YT_DEST"], ".yt_update")
+    if not os.path.exists(date_file):
+        print "Could not determine when yt stack was last updated."
+        return
+    print "".join(file(date_file, 'r').readlines())
+    print "To update all dependencies, run \"yt update --all\"."
+    
 def _update_yt_stack(path):
     "Rerun the install script to updated all dependencies."
     
                 if opts.update_source:
                     update_hg(path)
                 print "Updated successfully."
+                _get_yt_stack_date()
         elif opts.update_source:
             print
             print "YT site-packages not in path, so you must"
             print "This installation CAN be automatically updated."
             update_hg(path, skip_rebuild=opts.reinstall)
             print "Updated successfully."
+            _get_yt_stack_date()
             if opts.reinstall:
                 _update_yt_stack(path)
         else: