chiark / gitweb /
Improve comments about extending source-info.txt
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Thu, 29 Oct 2009 17:26:06 +0000 (17:26 +0000)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Thu, 29 Oct 2009 17:35:46 +0000 (17:35 +0000)
yarrg/Commods.pm
yarrg/db-idempotent-populate

index 372fe16f51544081e9378d68563a91a5b38868df..f74571ddd39c6c5093902c51aae03969cb780532 100644 (file)
@@ -51,7 +51,33 @@ BEGIN {
     @EXPORT_OK   = qw();
 }
 
-our $masterinfoversion= 2; # version we understand
+our $masterinfoversion= 2; # version we understand.
+#
+# To extend the source-info.txt format:
+#
+#    * Commods.pm:parse_info1
+#       add code to parse new version
+#
+#    * source-info.txt
+#       add new information
+#
+# If new data should NOT be in master-info.txt too:
+#
+#    * update-master-info:process_some_info
+#       check that code for converting source-info to master-info
+#       removes the extra info; add code to remove it if necessary
+#
+#    * db-idempotent-populate
+#       if database schema is extended, add code to copy data
+#
+# If new data DOES need to be in master-info.txt too:
+#
+#    * Commods.pm:$masterinfoversion
+#       increment
+#
+#    * update-master-info:process_some_info
+#       add code to convert new version to old, by removing
+#       extra info conditionally depending on version
 
 our %oceans; # eg $oceans{'Midnight'}{'Ruby'}{'Eta Island'}= $sources;
 our %clients; # eg $clients{'ypp-sc-tools'}= [ qw(last-page) ];
index 1d106f2b4f9ef6924cebc6f19b0677ce8352d008..c4bd4a761431ef4968520b0080e894925871f73f 100755 (executable)
@@ -5,7 +5,7 @@
 #
 # usage: ./db-idempotent-populate <Oceanname>
 #  creates or updates OCEAN-Oceanname.db
-#  from master-master.txt
+#  from source-info.txt
 
 # This is part of ypp-sc-tools, a set of third-party tools for assisting
 # players of Yohoho Puzzle Pirates.