JAL-3447 minor corrections to cif and mmcif file associations
authorBen Soares <bsoares@dundee.ac.uk>
Mon, 6 Jan 2020 16:08:30 +0000 (16:08 +0000)
committerBen Soares <bsoares@dundee.ac.uk>
Mon, 6 Jan 2020 16:08:30 +0000 (16:08 +0000)
utils/install4j/auto_file_associations-i4j8.pl
utils/install4j/file_associations_auto-Info_plist.xml
utils/install4j/file_associations_auto-install4j8.xml
utils/install4j/install4j8_template.install4j

index bf24b11..9b26f22 100755 (executable)
@@ -23,7 +23,7 @@ my $mimetypes = {
   scorematrix => "application/x-jalview-scorematrix+text",
   pdb => "chemical/x-pdb",
   mmcif => "chemical/x-cif",
-  mmcif2 => "chemical/x-mcif",
+  mmcif2 => "chemical/x-mmcif",
   jalview => "application/x-jalview+xml+zip",
   jvl => "application/x-jalview-jvl+text",
   annotations => "application/x-jalview-annotations+text",
@@ -37,6 +37,7 @@ my $add_associations = {
   gff3 => {shortname=>"gff3",name=>"Generic Features Format v3",extensions=>["gff3"]},
   features => {shortname=>"features",name=>"Jalview Features",extensions=>["features","jvfeatures"]},
   annotations => {shortname=>"annotations",name=>"Jalview Annotations",extensions=>["annotations","jvannotations"]},
+  mmcif => {shortname=>"mmcif",name=>"CIF",extensions=>["cif"]},
   mmcif2 => {shortname=>"mmcif2",name=>"mmCIF",extensions=>["mcif","mmcif"]},
   jvl => {shortname=>"jvl",name=>"Jalview Launch",extensions=>["jvl"],iconfile=>"Jalview-Launch"},
   jnet => {shortname=>"jnet",name=>"JnetFile",extensions=>["concise","jnet"]},
@@ -213,6 +214,6 @@ close(MA);
 sub xml_escape {
   my $x = shift;
   # stolen from Pod::Simple::XMLOutStream in base distro
-  $x =~ s/([^-\n\t !\#\$\%\(\)\*\+,\.\~\/\:\;=\?\@\[\\\]\^_\`\{\|\}abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789])/'&#'.(ord($1)).';'/eg;
+  $x =~ s/([^-\n\t !\#\$\%\(\)\*\+,\.\~\/\:\;=\?\@\[\\\]\^_\`\{\|\}a-zA-Z0-9])/'&#'.(ord($1)).';'/eg;
   return $x;
 }  
index 67f5ba0..fac86a3 100644 (file)
@@ -45,7 +45,7 @@
 <string>cif</string>
 </array>
 <key>CFBundleTypeName</key>
-<string>mmCIF File</string>
+<string>CIF File</string>
 <key>CFBundleTypeIconFile</key>
 <string>Jalview-File.icns</string>
 <key>CFBundleTypeRole</key>
@@ -72,7 +72,7 @@
 <string>Viewer</string>
 <key>CFBundleTypeMIMETypes</key>
 <array>
-<string>chemical/x-mcif</string>
+<string>chemical/x-mmcif</string>
 </array>
 <key>LSIsAppleDefaultForType</key>
 <false/>
index 9314f6a..c9f5dc6 100644 (file)
                   </action>
 <!-- END -->
 
-<!-- mmCIF (.cif) BEGIN -->
-                  <action name="mmCIF (.cif) message" id="10006" customizedId="mmCIF-cif-10006-message" beanClass="com.install4j.runtime.beans.actions.control.SetMessageAction" actionElevationType="none" rollbackBarrierExitCode="0">
+<!-- CIF (.cif) BEGIN -->
+                  <action name="CIF (.cif) message" id="10006" customizedId="CIF-cif-10006-message" beanClass="com.install4j.runtime.beans.actions.control.SetMessageAction" actionElevationType="none" rollbackBarrierExitCode="0">
                     <serializedBean>
-                      <property name="detailMessage" type="string">mmCIF (.cif)</property>
+                      <property name="detailMessage" type="string">CIF (.cif)</property>
                       <property name="statusMessage" type="string">Creating file associations...</property>
                       <property name="useDetail" type="boolean" value="true" />
                       <property name="useStatus" type="boolean" value="true" />
                     </serializedBean>
                   </action>
 
-                  <action name="mmCIF (.cif) progress bar 8" id="10007" customizedId="mmCIF-cif-10007-progressbar" beanClass="com.install4j.runtime.beans.actions.control.SetProgressAction" actionElevationType="none" rollbackBarrierExitCode="0">
+                  <action name="CIF (.cif) progress bar 8" id="10007" customizedId="CIF-cif-10007-progressbar" beanClass="com.install4j.runtime.beans.actions.control.SetProgressAction" actionElevationType="none" rollbackBarrierExitCode="0">
                     <serializedBean>
                       <property name="percentValue" type="int" value="8" />
                     </serializedBean>
                   </action>
 
-                  <action name="mmCIF (.cif) file association" id="10008" customizedId="mmCIF-cif-10008-fileassociation" beanClass="com.install4j.runtime.beans.actions.desktop.CreateFileAssociationAction" actionElevationType="elevated" rollbackBarrierExitCode="0" errorMessage="Could not make .cif file association">
+                  <action name="CIF (.cif) file association" id="10008" customizedId="CIF-cif-10008-fileassociation" beanClass="com.install4j.runtime.beans.actions.desktop.CreateFileAssociationAction" actionElevationType="elevated" rollbackBarrierExitCode="0" errorMessage="Could not make .cif file association">
                     <serializedBean>
-                      <property name="description" type="string">mmCIF File</property>
+                      <property name="description" type="string">CIF File</property>
                       <property name="extension" type="string">cif</property>
                       <property name="launcherId" type="string">737</property>
                       <property name="selected" type="boolean" value="false" />
                           <string>Jalview-File.icns</string>
                         </object>
                       </property>
-                      <!--<property name="macMimeType" type="string">chemical/x-mcif</property>-->
+                      <!--<property name="macMimeType" type="string">chemical/x-mmcif</property>-->
                       <property name="macRole" type="enum" class="com.install4j.runtime.beans.actions.desktop.MacAssociationRole" value="EDITOR" />
                       <property name="restartFinder" type="boolean" value="true" />
                       <property name="unix" type="boolean" value="true" />
                           <string>Jalview-File.png</string>
                         </object>
                       </property>
-                      <property name="unixMimeType" type="string">chemical/x-mcif</property>
+                      <property name="unixMimeType" type="string">chemical/x-mmcif</property>
                       <property name="windowsIconFile">
                         <object class="com.install4j.api.beans.ExternalFile">
                           <string>Jalview-File.ico</string>
index 134bc7d..3d39720 100644 (file)
@@ -1164,6 +1164,7 @@ return console.askYesNo(message, true);
         <entry filesetId="880" />
         <entry filesetId="882" />
         <entry filesetId="1873" />
+        <entry filesetId="2105" />
       </exclude>
     </unixInstaller>
     <unixArchive name="Unix .tar.gz Archive" id="1596" mediaFileName="${compiler:sys.shortName}-${compiler:JALVIEW_VERSION}-${compiler:sys.platform}-java_${compiler:JAVA_INTEGER_VERSION}">