Britton Smith avatar Britton Smith committed 4ca41eb

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

Comments (0)

Files changed (1)

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:
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.