Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • In the /install-files/ folder, create a folder called jre1jrex.8x.0x_20x. This will hold the Java Runtime for each platform.
    • Download the latest JREs zips from the BitRock website. You'll need:
      • JRE Windows
      • JRE Windows x64
      • JRE Linux
      • JRE Linux x64
      • JRE Mac OS X
    • Each of these zips will be structured like:

      Code Block
      languagebash
      jre1jrex.8x.0x_20x-<platform>/
      └── java-<platform>/
          ├── bin/
          │   ...
          └── lib/
              ...
    • From each of the zips, copy the java-<platform> folder into /install-files/jre1jrex.8x.0x_20x/
      Your folder structure should look like:

      Code Block
      .
      └── install-files/
          ├── icons/
          ├── images/
          └── jre1jrex.8x.0x_20x/
              ├── java-linux/
              │   ├── bin/
              │   └   ...
              ├── java-linux-x64/
              ├── java-osx/
              ├── java-windows/
              └── java-windows-x64/

    • Edit the java.xml file to update the jre version.  The jre version is throughout the file.  So its best to use a text editor that can do a search and replace.

      Code Block
      languagexml
      titleinstall-files/java.xml
                  <distributionFileList>
                      <distributionFile>
                          <allowWildcards>1</allowWildcards>
                          <origin>install-files/jre1.8.0_25/java-windows/*</origin>
                      </distributionFile>
                  </distributionFileList>

      For instance, if the jre version is upgraded to jre1.8.0_26, use the following command with vim.

      Code Block
      languagebash
      titleVIM search & replace
      %s/jre1.8.0_25/jre1.8.0_26

 

  • The NautDrafter compiled distributable must also be added.
    • In the main NautDrafter repo (cloned from https://bitbucket.org/nautdrafter/nautdrafter), run ./gradlew distZip (in the root directory). This will generate zip files in <project>/build/distributions/<project>.zip.
    • Extract <main-nautdrafter-repo>/NautDrafter/build/distributions/NautDrafter.zip to the root of the installer repo.
      You should now have the following folder structure:

      Code Block
      .
      ├── install-files/
      │   ├── icons/
      │   ├── images/
      │   └── jre1.8.0_20/
      └── NautDrafter/
          ├── assets/
          ├── bin/
          ├── bundles/
          ├── lib/
          └── style/
  • You are now ready to generate an installer!

...

For every NautDrafter release 10 installers must be generated - each platform has a main installer and an updater. The main difference between these two installers is that the updater does not bundle Java. The updater also performs some extra actions to check whether the user has Java 8 installed and (if they don't have Java 8) if a previous version of NautDrafter is installed (this is done by checking the selected installation directory for the NautDrafter.jar file. On Windows the registry is used to automatically find the previous install location).

Auotmation

If on linux, the scripts directory allows for automation in build and uploading to bitbucket.    See the following commands.

Code Block
languagebash
titlebuild the installers
scripts/build.bash
Code Block
languagebash
titleUpload to Bitbucket
scripts/upload.bash <username> <password>

 

Manual

The table below gives the command to run in order to generate the installer for each platform

...