CREATOR | Mark Raynsford |
DATE | 2024-10-03T17:13:28+00:00 |
DESCRIPTION | User manual for the Montarre package. |
IDENTIFIER | f51d65bd-fc7b-4cc8-85bf-dbed171a9550 |
LANGUAGE | en |
RIGHTS | Public Domain |
TITLE | Montarre User Manual |
$ wget https://repo1.maven.org/maven2/com/io7m/montarre/com.io7m.montarre.cmdline/0.0.5/com.io7m.montarre.cmdline-0.0.5-main.jar.asc
$ wget https://repo1.maven.org/maven2/com/io7m/montarre/com.io7m.montarre.cmdline/0.0.5/com.io7m.montarre.cmdline-0.0.5-main.jar
$ gpg --verify com.io7m.montarre.cmdline-0.0.5-main.jar.asc
$ java -jar com.io7m.montarre.cmdline-0.0.5-main.jar montarre: usage: montarre [command] [arguments ...] The montarre command-line application. Use the "help" command to examine specific commands: $ montarre help help. Command-line arguments can be placed one per line into a file, and the file can be referenced using the @ symbol: $ echo help > file.txt $ echo help >> file.txt $ montarre @file.txt Commands: help Show usage information for a command. maven-central Maven Central commands. native Native package commands. package Package commands. version Show the application version. wix WiX commands. Documentation: https://www.io7m.com/software/montarre/
$ unzip -p com.io7m.montarre.distribution/target/com.io7m.montarre.distribution-0.0.1-SNAPSHOT.mpk META-INF/MONTARRE/PACKAGE.XML <Package xmlns="urn:com.io7m.montarre.package:1"> <Metadata ApplicationKind="CONSOLE"> <Category Name="Building"></Category> <Category Name="Development"></Category> <Copying Copyright="Copyright © 2024 Mark Raynsford <code@io7m.com> https://www.io7m.com" License="ISC"></Copying> <Description> <Text Language="en">Package Java applications</Text> </Description> <Flatpak> <FlatpakPermission Value="--share=network"></FlatpakPermission> <FlatpakPermission Value="--filesystem=home:rw"></FlatpakPermission> <FlatpakRuntime Name="org.freedesktop.Sdk" Role="SDK" Version="24.08"></FlatpakRuntime> <FlatpakRuntime Name="org.freedesktop.Platform" Role="PLATFORM" Version="24.08"></FlatpakRuntime> </Flatpak> <JavaInfo MainModule="com.io7m.montarre.cmdline/com.io7m.montarre.cmdline.MMain" RequiredJDKVersion="21"></JavaInfo> <Link Role="SCM" Target="https://www.github.com/io7m-com/montarre"></Link> <Link Role="ISSUES" Target="https://www.github.com/io7m-com/montarre/issues"></Link> <Link Role="HOME_PAGE" Target="https://www.io7m.com/software/montarre"></Link> <LongDescription Language="en"> <Paragraph>The Montarre package provides a set of tools for producing native platform artifacts from platform-independent Java packages.</Paragraph> <Feature>A rich, strictly-defined, and well-specified packaging format that remains platform-independent whilst allowing straightforward zero-configuration transformations to a wide range of platform-specific package formats.</Feature> <Feature>Extensive, type-driven, ahead-of-time checking; if your package validates, you should get working native packages on all platforms.</Feature> <Feature>Reproducible builds by default.</Feature> <Feature>Support for producing simple jpackage "app-image" executables on any platform.</Feature> <Feature>Support for producing Debian .deb packages.</Feature> <Feature>Support for producing Windows MSI installers.</Feature> <Feature>Support for producing Flatpaks.</Feature> <Feature>A carefully-engineered Java API for creating, manipulating, and transforming packages.</Feature> <Feature>A full command-line interface built on top of the Java API.</Feature> <Feature>A Maven plugin for producing packages from any Maven module.</Feature> </LongDescription> <Names HumanName="Montarre" Name="com.io7m.montarre" ShortName="montarre"></Names> <Vendor ID="com.io7m" Name="io7m"></Vendor> <Version Date="2024-01-01" Number="0.0.1-SNAPSHOT"></Version> </Metadata> <Manifest> <Module File="lib/com.io7m.anethum.api-1.1.1.jar" HashAlgorithm="SHA-256" HashValue="bef5e82eeac406d93b993858e575ba304366ad333d54134969951d1223ff2ce8"></Module> <Module File="lib/com.io7m.blackthorne.core-2.0.2.jar" HashAlgorithm="SHA-256" HashValue="48b994b273dddd8a2a410c43db3efcd0d91a71910fc27189a24736313fb2bb23"></Module> <Module File="lib/com.io7m.blackthorne.jxe-2.0.2.jar" HashAlgorithm="SHA-256" HashValue="bfcf0e162aa3b636f29f933de5d80f01a1ee1ebb32780f1ff8ca96d56a75ecdf"></Module> <Module File="lib/com.io7m.jaffirm.core-4.0.1.jar" HashAlgorithm="SHA-256" HashValue="dc02592647284de9b985a3852e3ad967e9ee561d44772d3e4ecd99afbbc22f18"></Module> <Module File="lib/com.io7m.jcip-2.0.1.jar" HashAlgorithm="SHA-256" HashValue="f103daf09059c6969efb7e87dbd427da9dd2b9088224f3aca36e76865edd8ba2"></Module> <Module File="lib/com.io7m.jdownload.core-1.0.0.jar" HashAlgorithm="SHA-256" HashValue="807ec26e9b987dd7e5e475f64494501582af0a89375ec106a8307102a269095d"></Module> <Module File="lib/com.io7m.jlexing.core-3.2.0.jar" HashAlgorithm="SHA-256" HashValue="e26c6046de6cf41819fe2ed15e38279ce3447cf45430166b0f25a3f589d55c93"></Module> <Module File="lib/com.io7m.jmulticlose.core-1.1.3.jar" HashAlgorithm="SHA-256" HashValue="c0e5164f515e530dc210772d98120bbf8f60c9933b9e178e3ad4dbbf4ef43b92"></Module> <Module File="lib/com.io7m.junreachable.core-4.0.2.jar" HashAlgorithm="SHA-256" HashValue="979cb909924e8ea64e17b03340c601a8e6b6e1620c4e751a0bd74a34ffb9d5e9"></Module> <Module File="lib/com.io7m.jxe.core-2.0.0.jar" HashAlgorithm="SHA-256" HashValue="3520d03a2606787c4e88625f151c9dbbc853bd4987e752c509e6030a83238b67"></Module> <Module File="lib/com.io7m.jxtrand.api-2.1.0.jar" HashAlgorithm="SHA-256" HashValue="53c1a2cc739b6359441ba7aacc2aee74166ea416060b197ef6530e8a60052b27"></Module> <Module File="lib/com.io7m.jxtrand.vanilla-2.1.0.jar" HashAlgorithm="SHA-256" HashValue="c1bbcea8b4ec0a99093e1ec745036e7849f98687158ad3b777179618052ce9b2"></Module> <Module File="lib/com.io7m.lanark.core-1.2.0.jar" HashAlgorithm="SHA-256" HashValue="c725d2de4b82b9632cc2d72219b27f5d4c4700dde3dd2905f965f06894f04503"></Module> <Module File="lib/com.io7m.montarre.api-0.0.1-SNAPSHOT.jar" HashAlgorithm="SHA-256" HashValue="57cd2bf03e9b80f1ee78011d4a1ee45a5a6051ef8652917b89c5e368ea1d538f"></Module> <Module File="lib/com.io7m.montarre.cmdline-0.0.1-SNAPSHOT.jar" HashAlgorithm="SHA-256" HashValue="6e8b6e26827c9d46a678742aa5981cb9060d0ea68a295466a173481a7b0cf441"></Module> <Module File="lib/com.io7m.montarre.io-0.0.1-SNAPSHOT.jar" HashAlgorithm="SHA-256" HashValue="61bf500d463fac19cbe595bb6e3612936ba2f68aedf1ec9107ebd7addf37eeda"></Module> <Module File="lib/com.io7m.montarre.nativepack-0.0.1-SNAPSHOT.jar" HashAlgorithm="SHA-256" HashValue="f2d9ffcd1080036d47f2759a6bc174818d7fd73bbe4188141889d895f630deb1"></Module> <Module File="lib/com.io7m.montarre.schema-0.0.1-SNAPSHOT.jar" HashAlgorithm="SHA-256" HashValue="1027ae156398734ee4124839189361255b58b98bdd7dab2036dbfde231eaf3af"></Module> <Module File="lib/com.io7m.montarre.xml-0.0.1-SNAPSHOT.jar" HashAlgorithm="SHA-256" HashValue="9c614cda97071bef22da7fdcaeb446ccf6f4f5e29f654eab874b99725d01c124"></Module> <Module File="lib/com.io7m.quarrel.core-1.6.1.jar" HashAlgorithm="SHA-256" HashValue="20047834fc6d68a57ea251bccc52822de8bac068c4a13dcb6ae99111e542be90"></Module> <Module File="lib/com.io7m.quarrel.ext.logback-1.6.1.jar" HashAlgorithm="SHA-256" HashValue="48827e4267a6e85c5900649381bf73ddfb0ccee9e4e181834d3c17bd12e4fb48"></Module> <Module File="lib/com.io7m.seltzer.api-1.1.0.jar" HashAlgorithm="SHA-256" HashValue="1097d2d28fcf12e6a9699fc9b527712f954ebe8d25467ccfa8201e445eeadf96"></Module> <Module File="lib/com.io7m.streamtime.core-1.0.0.jar" HashAlgorithm="SHA-256" HashValue="d062c6142754e507c51a3e127b449ae2d95cf30afb65b4cfd6fffa7f7717a0c8"></Module> <Module File="lib/com.io7m.verona.core-1.0.1.jar" HashAlgorithm="SHA-256" HashValue="b6c2fb9858a9736c32e05513f0c0801ebcf38d7226d5c70f62dd7ba4dbd311e2"></Module> <Module File="lib/commons-codec-1.17.1.jar" HashAlgorithm="SHA-256" HashValue="f9f6cb103f2ddc3c99a9d80ada2ae7bf0685111fd6bffccb72033d1da4e6ff23"></Module> <Module File="lib/commons-compress-1.27.1.jar" HashAlgorithm="SHA-256" HashValue="293d80f54b536b74095dcd7ea3cf0a29bbfc3402519281332495f4420d370d16"></Module> <Module File="lib/commons-io-2.17.0.jar" HashAlgorithm="SHA-256" HashValue="4aa4ca48f3dfd30b78220b7881d8cb93eac4093ec94361b6befa9487998a550b"></Module> <Module File="lib/commons-lang3-3.17.0.jar" HashAlgorithm="SHA-256" HashValue="6ee731df5c8e5a2976a1ca023b6bb320ea8d3539fbe64c8a1d5cb765127c33b4"></Module> <Module File="lib/logback-classic-1.5.8.jar" HashAlgorithm="SHA-256" HashValue="89b0f7bec5fa8a9c9246acd1e99f0e84d6cb3bbadaa5b095a14c2cd0f4732d05"></Module> <Module File="lib/logback-core-1.5.8.jar" HashAlgorithm="SHA-256" HashValue="a698e4cff3eac45eec9b2755df93bb7a9725d853f7938030654ce5430b37c41d"></Module> <Module File="lib/slf4j-api-2.0.16.jar" HashAlgorithm="SHA-256" HashValue="a12578dde1ba00bd9b816d388a0b879928d00bab3c83c240f7013bf4196c579a"></Module> <Resource File="meta/bom.xml" HashAlgorithm="SHA-256" HashValue="822512da044a72e5e851f73347027c802e90f21468235266b32fca6cd7193bcc" Role="BOM"></Resource> <Resource File="meta/icon.ico" HashAlgorithm="SHA-256" HashValue="a36ce859182d76a764bfdb2260b05e0c00580a191e7bc36155a00062ccd06b0e" Role="ICO_WINDOWS"></Resource> <Resource File="meta/icon128.png" HashAlgorithm="SHA-256" HashValue="404b0d848df4c98a02804b6e7566b4c4bf27430f7c584381d32cf43a0b3e4028" Role="ICON_128"></Resource> <Resource File="meta/icon16.png" HashAlgorithm="SHA-256" HashValue="47734e7530a565bca0d8b3c2015600441b31fe151c59855b4f0af535360e1cf9" Role="ICON_16"></Resource> <Resource File="meta/icon24.png" HashAlgorithm="SHA-256" HashValue="7597832ef6ebff7f4fa8ac0c8774552f54b47391f8db8479ea96e395556c7da0" Role="ICON_24"></Resource> <Resource File="meta/icon32.png" HashAlgorithm="SHA-256" HashValue="e3ea34ef4296b538d7ef5d58ad511ab5bd4b4b078a30f1910e9789143c98776a" Role="ICON_32"></Resource> <Resource File="meta/icon48.png" HashAlgorithm="SHA-256" HashValue="35d5ada26910c3f707f9b8cfb016b1dca9a575c940018fa5048d71258581b0fc" Role="ICON_48"></Resource> <Resource File="meta/icon64.png" HashAlgorithm="SHA-256" HashValue="c30a14e51ade414a6110daa447e8d44cfa10808fa9ce06b4bb67f37def7fd04e" Role="ICON_64"></Resource> <Resource File="meta/license.txt" HashAlgorithm="SHA-256" HashValue="cb2db7e26966764c369e6fb4ca08a989e752d926016dd132661a8c64b25149f4" Role="LICENSE"></Resource> <Resource File="meta/screenshot.png" HashAlgorithm="SHA-256" HashValue="8341f4b229fea93885c52d7ad3797da8803d4e291b3a9e6f8c2c4d4d641637aa" Role="SCREENSHOT"> <Caption> <Text Language="en">The main command-line entry point.</Text> </Caption> </Resource> </Manifest> </Package>
<plugin> <groupId>com.io7m.montarre</groupId> <artifactId>com.io7m.montarre.maven_plugin</artifactId> <version>...</version> <executions> <execution> <id>make-distribution</id> <goals> <goal>package</goal> </goals> <phase>package</phase> <configuration> <validationWarningsAreErrors>true</validationWarningsAreErrors> <applicationKind>CONSOLE</applicationKind> <categories> <category>Development</category> <category>Building</category> </categories> <copyright>Copyright © 2024 Mark Raynsford <code@io7m.com> https://www.io7m.com</copyright> <humanName>Montarre</humanName> <packageName>com.io7m.montarre</packageName> <shortName>montarre</shortName> <description>Package Java applications</description> <version> <number>${project.version}</number> <date>2024-10-06</date> </version> <vendor> <id>com.io7m</id> <name>io7m</name> </vendor> <longDescriptions> <longDescription>${project.basedir}/src/main/meta/description-en.xml</longDescription> </longDescriptions> <mainModule>com.io7m.montarre.cmdline/com.io7m.montarre.cmdline.MMain</mainModule> <requiredJDKVersion>21</requiredJDKVersion> <flatpak> <runtimes> <runtime> <name>org.freedesktop.Sdk</name> <version>24.08</version> <role>SDK</role> </runtime> <runtime> <name>org.freedesktop.Platform</name> <version>24.08</version> <role>PLATFORM</role> </runtime> </runtimes> <permissions> <permission>--share=network</permission> <permission>--filesystem=home:rw</permission> </permissions> </flatpak> <libraries> <excludes> <exclude>com\.io7m\.montarre\.cmdline-.*-main\.jar</exclude> <exclude>com\.io7m\.montarre\.distribution-.*</exclude> <exclude>maven-.*</exclude> <exclude>com\.io7m\.montarre\.maven_plugin-.*</exclude> </excludes> </libraries> <resources> <resource> <role>BOM</role> <file>${project.build.directory}/bom.xml</file> <entryName>bom.xml</entryName> </resource> <resource> <role>ICON_16</role> <file>${project.basedir}/src/main/meta/icon16.png</file> <entryName>icon16.png</entryName> </resource> <resource> <role>ICON_24</role> <file>${project.basedir}/src/main/meta/icon24.png</file> <entryName>icon24.png</entryName> </resource> <resource> <role>ICON_32</role> <file>${project.basedir}/src/main/meta/icon32.png</file> <entryName>icon32.png</entryName> </resource> <resource> <role>ICON_48</role> <file>${project.basedir}/src/main/meta/icon48.png</file> <entryName>icon48.png</entryName> </resource> <resource> <role>ICON_64</role> <file>${project.basedir}/src/main/meta/icon64.png</file> <entryName>icon64.png</entryName> </resource> <resource> <role>ICON_128</role> <file>${project.basedir}/src/main/meta/icon128.png</file> <entryName>icon128.png</entryName> </resource> <resource> <role>SCREENSHOT</role> <file>${project.basedir}/src/main/meta/screenshot.png</file> <entryName>screenshot.png</entryName> <captions> <caption> <language>en</language> <text>The main command-line entry point.</text> </caption> </captions> </resource> <resource> <role>ICO_WINDOWS</role> <file>${project.basedir}/src/main/meta/icon.ico</file> <entryName>icon.ico</entryName> </resource> <resource> <role>LICENSE</role> <file>${project.basedir}/../README-LICENSE.txt</file> <entryName>license.txt</entryName> </resource> </resources> </configuration> </execution> </executions> </plugin>
$ ls com.io7m.montarre.distribution/target/*.mpk com.io7m.montarre.distribution/target/com.io7m.montarre.distribution-0.0.1-SNAPSHOT.mpk
$ montarre native create \ --package montarre.mpk \ --work-directory /tmp/work0 \ --output-directory /tmp/work0-output \ --java-runtime-download-uri https://github.com/adoptium/temurin21-binaries/releases/download/jdk-21.0.4%2B7/OpenJDK21U-jdk_x64_linux_hotspot_21.0.4_7.tar.gz \ --java-runtime-sha256 51fb4d03a4429c39d397d3a03a779077159317616550e4e71624c9843083e7b9 \ --java-runtime-format TAR_GZ
$ ls -alF /tmp/work0-output total 187632 drwxr-xr-x 2 montarre montarre 120 Oct 15 12:13 ./ drwxrwxrwt 30 root root 880 Oct 16 17:37 ../ -rw-r--r-- 1 montarre montarre 4138851 Oct 15 12:13 com.io7m.montarre-0.0.1-SNAPSHOT-any.tgz -rw-r--r-- 1 montarre montarre 81923503 Oct 15 12:11 com.io7m.montarre-0.0.1-SNAPSHOT-x86_64-linux.tgz -rw-r--r-- 1 montarre montarre 52665048 Oct 15 12:13 com.io7m.montarre.flatpak -rw-r--r-- 1 montarre montarre 53400220 Oct 15 12:11 montarre-0.0.1-SNAPSHOT-x86_64-linux.deb
1 |
It might be necessary to adjust the module path to account for the fact that the package
might have included, for
example, native libraries that should not be placed on the module path on some platforms.
The included package
metadata contains all of the information required to make these decisions. Most applications
do not include native
libraries, so the point generally stands.
References to this footnote:
1
|
2 |
The schema is so strict, in fact, that simply creating a Package element in the
correct urn:com.io7m.montarre.package:1 namespace in any modern IDE will automatically
create and fill in most of the elements!
References to this footnote:
1
|
<plugin> <groupId>com.io7m.montarre</groupId> <artifactId>com.io7m.montarre.maven_plugin</artifactId> <version>0.0.5</version> </plugin>
<applicationKind>CONSOLE</applicationKind>
<categories> <category>Development</category> <category>Building</category> </categories>
<copyright>Copyright © 2024 Mark Raynsford <code@io7m.com> https://www.io7m.com</copyright>
<description>Application packaging tools.</description>
<flatpak> <runtimes> <runtime> <name>org.freedesktop.Sdk</name> <version>24.08</version> <role>SDK</role> </runtime> <runtime> <name>org.freedesktop.Platform</name> <version>24.08</version> <role>PLATFORM</role> </runtime> </runtimes> <permissions> <permission>--share=network</permission> <permission>--filesystem=home:rw</permission> </permissions> </flatpak>
<humanName>Montarre</humanName>
<libraries> <excludes> <exclude>com\.io7m\.montarre\.cmdline-.*-main\.jar</exclude> <exclude>com\.io7m\.montarre\.distribution-.*</exclude> <exclude>maven-.*</exclude> <exclude>com\.io7m\.montarre\.maven_plugin-.*</exclude> </excludes> </libraries>
<license>ISC</license>
<links> <link> <role>HOME_PAGE</role> <target>https://www.io7m.com/software/montarre/</target> </link> <link> <role>SCM</role> <target>https://www.github.com/io7m-com/montarre/</target> </link> <link> <role>ISSUES</role> <target>https://www.github.com/io7m-com/montarre/issues/</target> </link> </links>
<longDescriptions> <longDescription>src/main/meta/description-en.xml</longDescription> </longDescriptions>
$ cat src/main/meta/description-en.xml <?xml version="1.0" encoding="UTF-8" ?> <LongDescription xmlns="urn:com.io7m.montarre.package:1" Language="en"> <Paragraph> The Montarre package provides a set of tools for producing native platform artifacts from platform-independent Java packages. </Paragraph> ...
<mainModule>com.io7m.montarre.cmdline/com.io7m.montarre.cmdline.MMain</mainModule>
<outputFile>com.io7m.montarre.cmdline-0.0.5.mpk</mainModule>
<packageName>com.io7m.montarre</packageName>
<version> <number>0.0.5</number> <date>2024-10-06</date> </version>
<platformLibraries> <platformLibrary> <architecture>x86_64</architecture> <operatingSystem>linux</operatingSystem> <includes> <include>lwjgl-natives-linux-amd64\.jar</include> </includes> </platformLibrary> <platformLibrary> <architecture>aarch64</architecture> <operatingSystem>linux</operatingSystem> <includes> <include>lwjgl-natives-linux-aarch64\.jar</include> </includes> </platformLibrary> <platformLibrary> <architecture>x86_64</architecture> <operatingSystem>windows</operatingSystem> <includes> <include>lwjgl-natives-windows-amd64\.jar</include> </includes> </platformLibrary> <platformLibrary> <architecture>aarch64</architecture> <operatingSystem>windows</operatingSystem> <includes> <include>lwjgl-natives-windows-aarch64\.jar</include> </includes> </platformLibrary> </platformLibraries>
<requiredJDKVersion>21</requiredJDKVersion>
<resources> <resource> <role>BOM</role> <file>/tmp/releases/montarre/com.io7m.montarre.documentation/target/bom.xml</file> <entryName>bom.xml</entryName> </resource> <resource> <role>ICON_16</role> <file>/tmp/releases/montarre/com.io7m.montarre.documentation/src/main/meta/icon16.png</file> <entryName>icon16.png</entryName> </resource> <resource> <role>ICON_24</role> <file>/tmp/releases/montarre/com.io7m.montarre.documentation/src/main/meta/icon24.png</file> <entryName>icon24.png</entryName> </resource> <resource> <role>ICON_32</role> <file>/tmp/releases/montarre/com.io7m.montarre.documentation/src/main/meta/icon32.png</file> <entryName>icon32.png</entryName> </resource> <resource> <role>ICON_48</role> <file>/tmp/releases/montarre/com.io7m.montarre.documentation/src/main/meta/icon48.png</file> <entryName>icon48.png</entryName> </resource> <resource> <role>ICON_64</role> <file>/tmp/releases/montarre/com.io7m.montarre.documentation/src/main/meta/icon64.png</file> <entryName>icon64.png</entryName> </resource> <resource> <role>ICON_128</role> <file>/tmp/releases/montarre/com.io7m.montarre.documentation/src/main/meta/icon128.png</file> <entryName>icon128.png</entryName> </resource> <resource> <role>ICO_WINDOWS</role> <file>/tmp/releases/montarre/com.io7m.montarre.documentation/src/main/meta/icon.ico</file> <entryName>icon.ico</entryName> </resource> <resource> <role>LICENSE</role> <file>/tmp/releases/montarre/com.io7m.montarre.documentation/../README-LICENSE.txt</file> <entryName>license.txt</entryName> </resource> </resources>
<shortName>montarre</requiredJDKVersion>
<vendor> <id>com.io7m</id> <name>io7m</name> </vendor>
montarre: usage: montarre [command] [arguments ...] The montarre command-line application. Use the "help" command to examine specific commands: $ montarre help help. Command-line arguments can be placed one per line into a file, and the file can be referenced using the @ symbol: $ echo help > file.txt $ echo help >> file.txt $ montarre @file.txt Commands: help Show usage information for a command. maven-central Maven Central commands. native Native package commands. package Package commands. version Show the application version. wix WiX commands. Documentation: https://www.io7m.com/software/montarre/
$ montarre package check --file com.io7m.montarre.distribution/target/com.io7m.montarre.distribution-0.0.1-SNAPSHOT.mpk ... $ (cat <<EOF package check --file com.io7m.montarre.distribution/target/com.io7m.montarre.distribution-0.0.1-SNAPSHOT.mpk EOF ) > args.txt $ montarre @args.txt
$ montarre help package check montarre: usage: check [named-arguments ...] Check a package file. Named parameters: --check-hashes Description : Whether to check file hashes. Type : Boolean Cardinality : [1]; Specify exactly once, or use the default. Default value : true Syntax : true | false * --file Description : The input file. Type : Path Cardinality : [1]; Specify exactly once. Syntax : <platform-specific path syntax> --verbose Description : Set the logging level of the application. Type : QLogLevel Cardinality : [1]; Specify exactly once, or use the default. Default value : info Syntax : trace|debug|info|warn|error The command does not accept any positional arguments.
Attribute | Value |
---|---|
Name | --artifact |
Type | java.lang.String |
Default Value | |
Cardinality | [1, 1] |
Description | The artifact name. |
Attribute | Value |
---|---|
Name | --base-uri-releases |
Type | java.net.URI |
Default Value | https://repo1.maven.org/maven2 |
Cardinality | [1, 1] |
Description | The base repository URI for release versions. |
Attribute | Value |
---|---|
Name | --base-uri-snapshots |
Type | java.net.URI |
Default Value | https://s01.oss.sonatype.org/content/repositories/snapshots |
Cardinality | [1, 1] |
Description | The base repository URI for -SNAPSHOT versions. |
Attribute | Value |
---|---|
Name | --classifier |
Type | java.lang.String |
Default Value | |
Cardinality | [0, 1] |
Description | The classifier name. |
Attribute | Value |
---|---|
Name | --group |
Type | java.lang.String |
Default Value | |
Cardinality | [1, 1] |
Description | The group name. |
Attribute | Value |
---|---|
Name | --output-file |
Type | java.nio.file.Path |
Default Value | |
Cardinality | [1, 1] |
Description | The output file. |
Attribute | Value |
---|---|
Name | --type |
Type | java.lang.String |
Default Value | jar |
Cardinality | [1, 1] |
Description | The artifact type. |
Attribute | Value |
---|---|
Name | --verbose |
Type | com.io7m.quarrel.ext.logback.QLogLevel |
Default Value | info |
Cardinality | [1, 1] |
Description | Set the logging level of the application. |
Attribute | Value |
---|---|
Name | --version |
Type | java.lang.String |
Default Value | |
Cardinality | [1, 1] |
Description | The version. |
$ montarre maven-central download \ --artifact com.io7m.junreachable.core \ --version 4.0.0 \ --group com.io7m.junreachable \ --output-file junreachable.jar INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: Downloading: https://repo1.maven.org/maven2/com/io7m/junreachable/com.io7m.junreachable.core/4.0.0/com.io7m.junreachable.core-4.0.0.jar INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: Checksum: https://repo1.maven.org/maven2/com/io7m/junreachable/com.io7m.junreachable.core/4.0.0/com.io7m.junreachable.core-4.0.0.jar.sha1 INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: Download: 0 bytes/4 KB (0 bytes/s) ~PT0S remaining INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: Download: 0 bytes/40 bytes (0 bytes/s) ~PT0S remaining
Attribute | Value |
---|---|
Name | --adoptium-temurin-version |
Type | java.lang.Runtime.Version |
Default Value | |
Cardinality | [0, 1] |
Description | The version of the Adoptium Temurin runtime to use. |
Attribute | Value |
---|---|
Name | --include-packagers |
Type | java.lang.String |
Default Value | [] |
Cardinality | [0, N] |
Description | Only run the named packagers. |
Attribute | Value |
---|---|
Name | --java-runtime-download-uri |
Type | java.net.URI |
Default Value | |
Cardinality | [0, 1] |
Description | The location for a Java runtime. |
Attribute | Value |
---|---|
Name | --java-runtime-format |
Type | com.io7m.montarre.api.MArchiveFormat |
Default Value | |
Cardinality | [0, 1] |
Description | The format of the Java runtime archive. |
Attribute | Value |
---|---|
Name | --java-runtime-sha256 |
Type | java.lang.String |
Default Value | |
Cardinality | [0, 1] |
Description | The SHA-256 of the Java runtime. |
Attribute | Value |
---|---|
Name | --output-directory |
Type | java.nio.file.Path |
Default Value | |
Cardinality | [1, 1] |
Description | The output directory. |
Attribute | Value |
---|---|
Name | --package |
Type | java.nio.file.Path |
Default Value | |
Cardinality | [1, 1] |
Description | The input package. |
Attribute | Value |
---|---|
Name | --verbose |
Type | com.io7m.quarrel.ext.logback.QLogLevel |
Default Value | info |
Cardinality | [1, 1] |
Description | Set the logging level of the application. |
Attribute | Value |
---|---|
Name | --work-directory |
Type | java.nio.file.Path |
Default Value | |
Cardinality | [1, 1] |
Description | The work directory. |
$ montarre native create \ --verbose info \ --package com.io7m.montarre.distribution/target/com.io7m.montarre.distribution-0.0.1-SNAPSHOT.mpk \ --work-directory /tmp/work0 \ --output-directory /tmp/work0-output \ --java-runtime-download-uri https://github.com/adoptium/temurin21-binaries/releases/download/jdk-21.0.4%2B7/OpenJDK21U-jdk_x64_linux_hotspot_21.0.4_7.tar.gz \ --java-runtime-sha256 51fb4d03a4429c39d397d3a03a779077159317616550e4e71624c9843083e7b9 \ --java-runtime-format TAR_GZ INFO com.io7m.montarre.cmdline.internal.MCNativeCreate: Opening package com.io7m.montarre.distribution/target/com.io7m.montarre.distribution-0.0.1-SNAPSHOT.mpk. INFO com.io7m.montarre.cmdline.internal.MCNativeCreate: Creating output directory /tmp/work0-output INFO com.io7m.montarre.cmdline.internal.MCNativeCreate: Creating workspace /tmp/work0. INFO com.io7m.montarre.cmdline.internal.MCNativeCreate: Workspace architecture: x86_64 INFO com.io7m.montarre.cmdline.internal.MCNativeCreate: Workspace OS: linux ... $ ls -alF /tmp/work0-output/ total 187632 drwxr-xr-x 2 montarre montarre 120 Oct 13 12:13 ./ drwxrwxrwt 29 root root 840 Oct 13 12:12 ../ -rw-r--r-- 1 montarre montarre 4138851 Oct 13 12:13 com.io7m.montarre-0.0.1-SNAPSHOT-any.tgz -rw-r--r-- 1 montarre montarre 81923503 Oct 13 12:11 com.io7m.montarre-0.0.1-SNAPSHOT-x86_64-linux.tgz -rw-r--r-- 1 montarre montarre 52665048 Oct 13 12:13 com.io7m.montarre.flatpak -rw-r--r-- 1 montarre montarre 53400220 Oct 13 12:11 montarre-0.0.1-SNAPSHOT-x86_64-linux.deb
Attribute | Value |
---|---|
Name | --verbose |
Type | com.io7m.quarrel.ext.logback.QLogLevel |
Default Value | info |
Cardinality | [1, 1] |
Description | Set the logging level of the application. |
$ montarre native packagers Name: com.io7m.montarre.app_image Description: Produces jpackage 'app-images'. Supported: yes -- Name: com.io7m.montarre.deb Description: Produces Debian .deb packages. Supported: yes -- Name: com.io7m.montarre.flatpak Description: Produces Flatpak packages. Supported: yes -- Name: com.io7m.montarre.msi_wix Description: Produces MSI packages. Supported: no Reason: Cannot run program "wix": error=2, No such file or directory Exception: com.io7m.montarre.api.MException: Cannot run program "wix": error=2, No such file or directory at com.io7m.montarre.nativepack.MNativeProcesses.executeAndWait(MNativeProcesses.java:109) at com.io7m.montarre.nativepack.internal.msi.MNPackagerMSI.unsupportedReason(MNPackagerMSI.java:93) at com.io7m.montarre.cmdline.internal.MCNativePackagers.onExecute(MCNativePackagers.java:89) at com.io7m.quarrel.core.internal.QCommandContext.execute(QCommandContext.java:207) at com.io7m.quarrel.core.QApplicationType.run(QApplicationType.java:94) at com.io7m.montarre.cmdline.MMain.run(MMain.java:191) at com.io7m.montarre.cmdline.MMain.mainExitless(MMain.java:166) at com.io7m.montarre.cmdline.MMain.main(MMain.java:151) Caused by: java.io.IOException: Cannot run program "wix": error=2, No such file or directory at java.base/java.lang.ProcessBuilder.start(ProcessBuilder.java:1170) at java.base/java.lang.ProcessBuilder.start(ProcessBuilder.java:1089) at com.io7m.montarre.nativepack.MNativeProcesses.executeAndWait(MNativeProcesses.java:76) ... 7 more Caused by: java.io.IOException: error=2, No such file or directory at java.base/java.lang.ProcessImpl.forkAndExec(Native Method) at java.base/java.lang.ProcessImpl.<init>(ProcessImpl.java:295) at java.base/java.lang.ProcessImpl.start(ProcessImpl.java:225) at java.base/java.lang.ProcessBuilder.start(ProcessBuilder.java:1126) ... 9 more -- Name: com.io7m.montarre.shell Description: Produces shell packages. Supported: yes --
Attribute | Value |
---|---|
Name | --check-hashes |
Type | java.lang.Boolean |
Default Value | true |
Cardinality | [1, 1] |
Description | Whether to check file hashes. |
Attribute | Value |
---|---|
Name | --file |
Type | java.nio.file.Path |
Default Value | |
Cardinality | [1, 1] |
Description | The input file. |
Attribute | Value |
---|---|
Name | --verbose |
Type | com.io7m.quarrel.ext.logback.QLogLevel |
Default Value | info |
Cardinality | [1, 1] |
Description | Set the logging level of the application. |
$ montarre package check --file com.io7m.montarre.distribution/target/com.io7m.montarre.distribution-0.0.1-SNAPSHOT.mpk INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.anethum.api-1.1.1.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.blackthorne.core-2.0.2.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.blackthorne.jxe-2.0.2.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.jaffirm.core-4.0.1.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.jcip-2.0.1.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.jdownload.core-1.0.0.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.jlexing.core-3.2.0.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.jmulticlose.core-1.1.3.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.junreachable.core-4.0.2.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.jxe.core-2.0.0.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.jxtrand.api-2.1.0.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.jxtrand.vanilla-2.1.0.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.lanark.core-1.2.0.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.montarre.api-0.0.1-SNAPSHOT.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.montarre.cmdline-0.0.1-SNAPSHOT.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.montarre.io-0.0.1-SNAPSHOT.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.montarre.nativepack-0.0.1-SNAPSHOT.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.montarre.schema-0.0.1-SNAPSHOT.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.montarre.xml-0.0.1-SNAPSHOT.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.quarrel.core-1.6.1.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.quarrel.ext.logback-1.6.1.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.seltzer.api-1.1.0.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.streamtime.core-1.0.0.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/com.io7m.verona.core-1.0.1.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/commons-codec-1.17.1.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/commons-compress-1.27.1.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/commons-io-2.17.0.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/commons-lang3-3.17.0.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/logback-classic-1.5.8.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/logback-core-1.5.8.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: lib/slf4j-api-2.0.16.jar: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: meta/bom.xml: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: meta/icon.ico: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: meta/icon128.png: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: meta/icon16.png: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: meta/icon24.png: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: meta/icon32.png: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: meta/icon48.png: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: meta/icon64.png: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: meta/license.txt: OK INFO com.io7m.montarre.cmdline.internal.MCPackageCheck: meta/screenshot.png: OK
Attribute | Value |
---|---|
Name | --file |
Type | java.nio.file.Path |
Default Value | |
Cardinality | [1, 1] |
Description | The input file. |
Attribute | Value |
---|---|
Name | --verbose |
Type | com.io7m.quarrel.ext.logback.QLogLevel |
Default Value | info |
Cardinality | [1, 1] |
Description | Set the logging level of the application. |
$ montarre package extract-declaration --file com.io7m.montarre.distribution/target/com.io7m.montarre.distribution-0.0.1-SNAPSHOT.mpk <Package xmlns="urn:com.io7m.montarre.package:1"> <Metadata ApplicationKind="CONSOLE"> <Category Name="Building"></Category> ...
Attribute | Value |
---|---|
Name | --input-directory |
Type | java.nio.file.Path |
Default Value | |
Cardinality | [1, 1] |
Description | The input directory. |
Attribute | Value |
---|---|
Name | --output-file |
Type | java.nio.file.Path |
Default Value | |
Cardinality | [1, 1] |
Description | The output file. |
Attribute | Value |
---|---|
Name | --verbose |
Type | com.io7m.quarrel.ext.logback.QLogLevel |
Default Value | info |
Cardinality | [1, 1] |
Description | Set the logging level of the application. |
$ montarre package pack --input-directory /tmp/out2 --output-file montarre.mpk
Attribute | Value |
---|---|
Name | --verbose |
Type | com.io7m.quarrel.ext.logback.QLogLevel |
Default Value | info |
Cardinality | [1, 1] |
Description | Set the logging level of the application. |
Attribute | Value |
---|---|
Name | --version |
Type | java.lang.Integer |
Default Value | 1 |
Cardinality | [1, 1] |
Description | The schema version. |
$ montarre package schema <?xml version="1.0" encoding="UTF-8" ?> <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="urn:com.io7m.montarre.package:1" xmlns:mp="urn:com.io7m.montarre.package:1"> <xsd:simpleType name="ApplicationKindType"> <xsd:annotation> ...
Attribute | Value |
---|---|
Name | --file |
Type | java.nio.file.Path |
Default Value | |
Cardinality | [1, 1] |
Description | The input file. |
Attribute | Value |
---|---|
Name | --output-directory |
Type | java.nio.file.Path |
Default Value | |
Cardinality | [1, 1] |
Description | The output directory. |
Attribute | Value |
---|---|
Name | --verbose |
Type | com.io7m.quarrel.ext.logback.QLogLevel |
Default Value | info |
Cardinality | [1, 1] |
Description | Set the logging level of the application. |
$ montarre package unpack \ --file com.io7m.montarre.distribution/target/com.io7m.montarre.distribution-0.0.1-SNAPSHOT.mpk \ --output-directory /tmp/out2 $ ls -alF /tmp/out2/ total 0 drwxr-xr-x 5 montarre montarre 100 Oct 13 12:19 ./ drwxrwxrwt 30 root root 860 Oct 13 12:19 ../ drwxr-xr-x 3 montarre montarre 60 Oct 13 12:19 META-INF/ drwxr-xr-x 2 montarre montarre 660 Oct 13 12:19 lib/ drwxr-xr-x 2 montarre montarre 240 Oct 13 12:19 meta/
Attribute | Value |
---|---|
Name | --file |
Type | java.nio.file.Path |
Default Value | |
Cardinality | [1, 1] |
Description | The input file. |
Attribute | Value |
---|---|
Name | --verbose |
Type | com.io7m.quarrel.ext.logback.QLogLevel |
Default Value | info |
Cardinality | [1, 1] |
Description | Set the logging level of the application. |
Attribute | Value |
---|---|
Name | --warnings-as-errors |
Type | java.lang.Boolean |
Default Value | true |
Cardinality | [1, 1] |
Description | Whether to treat warnings as errors. |
$ montarre package validate --file com.io7m.montarre.distribution/target/com.io7m.montarre.distribution-0.0.1-SNAPSHOT.mpk
$ montarre version com.io7m.montarre 0.0.1-SNAPSHOT f47e12fd7363837c6358eeec53b3122645b06df5
Attribute | Value |
---|---|
Name | --input-directory |
Type | java.nio.file.Path |
Default Value | |
Cardinality | [1, 1] |
Description | The input directory. |
Attribute | Value |
---|---|
Name | --package |
Type | java.nio.file.Path |
Default Value | |
Cardinality | [1, 1] |
Description | The input package. |
Attribute | Value |
---|---|
Name | --verbose |
Type | com.io7m.quarrel.ext.logback.QLogLevel |
Default Value | info |
Cardinality | [1, 1] |
Description | Set the logging level of the application. |
$ montarre wix xml --input-directory /tmp/out2 --package montarre.mpk <Wix xmlns="http://wixtoolset.org/schemas/v4/wxs"> <Package Language="1033" Manufacturer="io7m" Name="com.io7m.montarre" UpgradeCode="2e11817e-7476-336d-8cc7-1baa130f30dc" Version="0.0.1-SNAPSHOT.0"> <MajorUpgrade DowngradeErrorMessage="A newer version of [ProductName] is already installed."></MajorUpgrade> <Icon Id="Icon.ico" SourceFile="/tmp/out2/meta/icon.ico"></Icon> <Property Id="ARPPRODUCTICON" Value="Icon.ico"></Property> <MediaTemplate EmbedCab="yes"></MediaTemplate> <StandardDirectory Id="ProgramFilesFolder"> <Directory Id="CompanyFolder" Name="io7m"> <Directory Id="INSTALLLOCATION" Name="com.io7m.montarre"></Directory> </Directory> ...
File | Description |
---|---|
${SHORT_NAME}/META-INF/MONTARRE/PACKAGE.XML | The original package declaration taken from the input package. |
${SHORT_NAME}/bin/launch.jar | The launch jar. |
${SHORT_NAME}/bin/${SHORT_NAME} | The shell script for POSIX-like systems. |
${SHORT_NAME}/bin/${SHORT_NAME}.bat | The batch file for Windows-like systems. |
${SHORT_NAME}/lib/*.jar | The platform-neutral jar files for the application. |
${SHORT_NAME}/lib/${ARCH}/${OS}/*.jar | The platform-specific jar files for the application, organized by architecture and operating system. |
${SHORT_NAME}/meta/* | The metadata files taken from the input package. |
$ java -p "${SHORT_NAME}/lib:${SHORT_NAME}/lib/${ARCH}/${OS}" -m "${MAIN_CLASS}"
c:> cd montarre c:\montarre> dir Volume in drive C has no label. Volume Serial Number is 187C-D7E2 Directory of c:\montarre 13/10/2024 18:34 <DIR> . 13/10/2024 18:34 <DIR> .. 13/10/2024 16:03 <DIR> bin 13/10/2024 16:03 <DIR> lib 13/10/2024 16:03 <DIR> meta 13/10/2024 15:34 <DIR> META-INF 6 Dir(s) 485,913,133,056 bytes free c:\montarre> bin\montarre.bat MONTARRE_HOME is unset c:\montarre> set MONTARRE_HOME=c:\montarre c:\montarre> bin\montarre.bat montarre: usage: montarre [command] [arguments ...] The montarre command-line application. ...
@echo off REM Auto generated: Do not edit. REM This is a launch script for Windows-like platforms. if NOT DEFINED MONTARRE_HOME ( echo MONTARRE_HOME is unset exit /b 1 ) REM Check that the available Java runtime is suitable. java -jar "%MONTARRE_HOME%/bin/launch.jar" check-java-version 21 if %errorlevel% neq 0 exit /b 1 REM Build a module path. for /f %%i in ('java -jar %MONTARRE_HOME%\bin\launch.jar get-module-path %MONTARRE_HOME%') do set MONTARRE_MODULE_PATH=%%i if %errorlevel% neq 0 exit /b 1 REM Run the application. java -p %MONTARRE_MODULE_PATH% -m com.io7m.montarre.cmdline/com.io7m.montarre.cmdline.MMain %* if %errorlevel% neq 0 exit /b 1
$ cd montarre $ ls META-INF bin lib meta $ ./bin/montarre MONTARRE_HOME is unset $ export MONTARRE_HOME=$(realpath .) $ ./bin/montarre montarre: usage: montarre [command] [arguments ...] The montarre command-line application. ...
#!/bin/sh # Auto generated: Do not edit. # This is a launch script for UNIX-like platforms. if [ -z "${MONTARRE_HOME}" ] then echo "MONTARRE_HOME is unset" 1>&2 exit 1 fi # # Check that the available Java runtime is suitable. # /usr/bin/env java -jar "${MONTARRE_HOME}/bin/launch.jar" \ check-java-version 21 || exit 1 # # Build a module path. This is guaranteed to be: # ${MONTARRE_HOME}/lib # ${MONTARRE_HOME}/lib/${ARCH}/${OS} # MONTARRE_MODULE_PATH=$(/usr/bin/env java -jar "${MONTARRE_HOME}/bin/launch.jar" \ get-module-path "${MONTARRE_HOME}") || exit 1 # # Run the application. # exec /usr/bin/env java \ -p "${MONTARRE_MODULE_PATH}" \ -m com.io7m.montarre.cmdline/com.io7m.montarre.cmdline.MMain \ "$@"
$ java -jar bin/launch.jar Get-Arch x86_64 C:> java -jar bin\launch.jar Get-Arch x86_64
$ java -jar bin/launch.jar Get-OS linux C:> java -jar bin\launch.jar Get-OS windows
$ java --version openjdk 21.0.4 2024-07-16 OpenJDK Runtime Environment (build 21.0.4+7) OpenJDK 64-Bit Server VM (build 21.0.4+7, mixed mode, sharing) $ java -jar bin/launch.jar Check-Java-Version 21 $ java -jar bin/launch.jar Check-Java-Version 11 $ java -jar bin/launch.jar Check-Java-Version 22 Exception in thread "main" java.lang.RuntimeException: At least Java 22 is required, but this Java runtime is version 21.0.4+7 at com.io7m.montarre.launchstub.MLSMain.doCheckJava(MLSMain.java:102) at com.io7m.montarre.launchstub.MLSMain.main(MLSMain.java:70)
$ java -jar bin/launch.jar Get-Module-Path /example /example/lib:/example/lib/x86_64/linux C:> java -jar bin\launch.jar Get-Module-Path c:\example c:\example\lib;c:\example\lib\x86_64\windows
(** The opaque, abstract type of regular expressions. *) Parameter RegularExpressionT : string -> Set.
(** For the sake of specification simplicity, we assume that all strings are valid regular expressions. *) Parameter regex : forall (s : string), RegularExpressionT s.
(** A proposition that states that a given regular expression matches a given string. *) Parameter matches : forall (s : string) {e : string}, RegularExpressionT e -> Prop.
(** Whether a string matches a regular expression is decidable. *) Parameter matchesDecidable : forall (s : string) {e : string} (r : RegularExpressionT e), {matches s r}+{~matches s r}.
Definition lanarkDottedString := forall (s : string), matches s (regex "([a-z][a-z0-9_-]{0,63})(\.[a-z][a-z0-9_-]{0,62}){0,15}").
Definition LanguageT := string.
Inductive TranslatedTextT := TranslatedText { language : LanguageT; text : string; translations : LanguageMaps.t string }.
Inductive HashT := Hash { hashAlgorithm : HashAlgorithmT; hashValue : HashValueT }.
Definition HashAlgorithmT := string.
Inductive HashValueT := HashValue : forall (s : string), matches s (regex "[a-f0-9]{2,256}") -> HashValueT.
Inductive ArchitectureNameT := ArchitectureName : forall (s : string), matches s (regex "[a-z][a-z0-9_-]{0,32}") -> ArchitectureNameT.
Name | Description |
---|---|
aarch_64 | 64-bit ARM |
arm_32 | 32-bit ARM |
loongarch_64 | 64-bit LoongArch |
mips_32 | 32-bit MIPS |
mips_64 | 64-bit MIPS |
mipsle_32 | 32-bit little-endian MIPS |
mipsle_64 | 64-bit little-endian MIPS |
ppc_32 | 32-bit PowerPC |
ppc_64 | 64-bit PowerPC |
ppcle_32 | 32-bit little-endian PowerPC |
ppcle_64 | 64-bit little-endian PowerPC |
riscv_32 | 32-bit RISC-V |
riscv_64 | 64-bit RISC-V |
s390_64 | 64-bit IBM z/Architecture |
sparc_32 | 32-bit SPARC |
sparc_64 | 64-bit SPARC |
x86_32 | 32-bit x86 |
x86_64 | 64-bit x86 |
Inductive OperatingSystemNameT := OperatingSystemName : forall (s : string), matches s (regex "[a-z][a-z0-9_-]{0,32}") -> OperatingSystemNameT.
Name | Description |
---|---|
aix | IBM AIX |
freebsd | FreeBSD |
hpux | HP-UX |
linux | Linux |
netbsd | NetBSD |
openbsd | OpenBSD |
os400 | IBM i |
osx | MacOS |
solaris | Oracle Solaris |
windows | Microsoft Windows |
Inductive PlatformT := Platform { platformArch : ArchitectureNameT; platformOS : OperatingSystemNameT }.
Inductive MetadataT := Metadata { metaApplicationKind : ApplicationKindT; metaCategories : list CategoryT; metaCopying : CopyingT; metaDescription : DescriptionT; metaFlatpak : FlatpakT; metaJavaInfo : JavaInfoT; metaLinks : list LinkT; metaLongDescriptions : LanguageMaps.t LongDescriptionT; metaNames : NamesT; metaVendor : VendorT; metaVersion : VersionT }.
Value | Description |
---|---|
CONSOLE | The application is a text-only console application. |
GRAPHICAL | The application is a graphical application. |
Inductive ApplicationKindT := | CONSOLE | GRAPHICAL .
Inductive CategoryT := Category : forall (s : string), matches s (regex "[A-Z][A-Za-z0-9_-]{0,128}") -> CategoryT.
Inductive CopyingT := Copying { license : LicenseT; copyright : CopyrightT }.
Definition LicenseT := string.
Definition CopyrightT := string.
Definition DescriptionT := TranslatedTextT.
Inductive FlatpakT := Flatpak { flatpakPermissions : list FlatpakPermissionT; flatpakRuntimes : list FlatpakRuntimeT }.
Inductive FlatpakRuntimeT := FlatpakRuntime { flatpakRuntimeName : string; flatpakRuntimeVersion : string; flatpakRuntimeRole : FlatpakRuntimeRoleT }.
Value | Description |
---|---|
SDK | A runtime for building applications. |
PLATFORM | A runtime for running applications. |
Inductive FlatpakRuntimeRoleT := | SDK | PLATFORM .
Definition FlatpakPermissionT := string.
Inductive JavaInfoT := JavaInfo { requiredJDKVersion : nat; mainModule : string }.
Inductive LinkT := Link { linkRole : LinkRoleT; linkTarget : string }.
Value | Description |
---|---|
ISSUES | A link to an issue tracker. |
HOME_PAGE | A link to a home page. |
DONATION | A link to a donation page. |
CONTACT | A link to a contact page. |
FAQ | A link to an FAQ page. |
TRANSLATE | A link to a translation page. |
CONTRIBUTE | A link to a contribution page. |
SCM | A link to an SCM repository. |
Inductive LinkRoleT := | ISSUES | HOME_PAGE | DONATION | CONTACT | FAQ | TRANSLATE | CONTRIBUTE | SCM .
Inductive LongDescriptionT := LongDescription { descriptionLanguage : LanguageT; descriptions : list ParagraphT; features : list FeatureT }.
Definition ParagraphT := string.
Definition FeatureT := string.
Inductive NamesT := Names { namePackage : PackageNameT; nameShort : ShortNameT; nameHuman : HumanNameT }.
Definition PackageNameT := lanarkDottedString.
Definition HumanNameT := string.
Inductive ShortNameT := ShortName : forall (s : string), matches s (regex "[a-z][a-z0-9_-]{0,128}") -> ShortNameT.
Inductive VendorT := Vendor { vendorId : VendorIDT; vendorName : VendorNameT }.
Inductive VendorNameT := VendorName : forall (s : string), matches s (regex "[a-zA-Z][A-Za-z0-9_-]{0,128}") -> VendorNameT.
Definition VendorIDT := lanarkDottedString.
Inductive VersionT := Version { versionNumber : VersionNumberT; versionDate : VersionDateT }.
Inductive VersionNumberT := VersionNumber { major : nat; minor : nat; patch : nat; qualifier : option string }.
Inductive VersionDateT := VersionDate : forall (s : string), matches s (regex "[0-9]{4}-[0-9]{2}-[0-9]{2}") -> VersionDateT.
Inductive ManifestT := Manifest { manifestItems : list ItemT }.
Inductive ItemT := | ItemModule : ModuleT -> ItemT | ItemPlatformModule : PlatformModuleT -> ItemT | ItemResource : ResourceT -> ItemT .
Definition manifesItemsFilenamesUnique := forall (m : ManifestT), forall (i0 : ItemT), In i0 (manifestItems m) -> ~(exists i1 : ItemT, (In i1 (manifestItems m)) /\ (i0 <> i1) /\ (fileNamesSame (itemFileName i0) (itemFileName i1))).
Inductive FileNameT := FileName : forall (s : string), matches s (regex "([\p{L}\p{N}_\-.+]+)(/[\p{L}\p{N}_\-.+]+)*") -> FileNameT.
(** A function that produces an uppercase version of the given string. *) Parameter uppercaseOf : string -> string.
Definition uppercaseSame (s t : string) := uppercaseOf s = uppercaseOf t.
(** A proposition that states that two file names are the same if their uppercase transformations are the same. *) Definition fileNamesSame (s t : FileNameT) := match s, t with | FileName fs _, FileName ft _ => uppercaseSame fs ft end.
Inductive ModuleT := Module : FileNameT -> HashT -> ModuleT.
Inductive PlatformModuleT := PlatformModule : FileNameT -> HashT -> PlatformT -> PlatformModuleT.
Inductive ResourceT := Resource : FileNameT -> HashT -> ResourceRoleT -> CaptionT -> ResourceT.
Inductive ResourceRoleT := | BOM | LICENSE | ICO_WINDOWS | ICON_16 | ICON_24 | ICON_32 | ICON_48 | ICON_64 | ICON_128 | ICON_256 | ICON_512 | ICON_SVG | SCREENSHOT .
Value | Description |
---|---|
BOM | A bill-of-materials. Recommended to be in CycloneDX format. |
LICENSE | A plain text license file. |
ICO_WINDOWS | A Windows application icon (".ico"). |
ICON_16 | A 16x16 application icon. |
ICON_24 | A 24x24 application icon. |
ICON_32 | A 32x32 application icon. |
ICON_48 | A 48x48 application icon. |
ICON_64 | A 64x64 application icon. |
ICON_128 | A 128x128 application icon. |
ICON_256 | A 256x256 application icon. |
ICON_512 | A 512x512 application icon. |
ICON_SVG | An arbitrarily scaled SVG icon. |
SCREENSHOT | A screenshot. |
Definition CaptionT := TranslatedTextT.
Length Date Time Name --------- ---------- ----- ---- 9147 2024-10-14 00:00 META-INF/MONTARRE/PACKAGE.XML 15052 2024-10-14 00:00 LIB/COM.IO7M.ANETHUM.API-1.1.1.JAR 42944 2024-10-14 00:00 LIB/COM.IO7M.BLACKTHORNE.CORE-2.0.2.JAR 5166 2024-10-14 00:00 LIB/COM.IO7M.BLACKTHORNE.JXE-2.0.2.JAR 38355 2024-10-14 00:00 LIB/COM.IO7M.JAFFIRM.CORE-4.0.1.JAR 5569 2024-10-14 00:00 LIB/COM.IO7M.JCIP-2.0.1.JAR 21462 2024-10-14 00:00 LIB/COM.IO7M.JDOWNLOAD.CORE-1.0.0.JAR 12841 2024-10-14 00:00 LIB/COM.IO7M.JLEXING.CORE-3.2.0.JAR 10227 2024-10-14 00:00 LIB/COM.IO7M.JMULTICLOSE.CORE-1.1.3.JAR 4505 2024-10-14 00:00 LIB/COM.IO7M.JUNREACHABLE.CORE-4.0.2.JAR 21622 2024-10-14 00:00 LIB/COM.IO7M.JXE.CORE-2.0.0.JAR 6730 2024-10-14 00:00 LIB/COM.IO7M.JXTRAND.API-2.1.0.JAR 9797 2024-10-14 00:00 LIB/COM.IO7M.JXTRAND.VANILLA-2.1.0.JAR 10609 2024-10-14 00:00 LIB/COM.IO7M.LANARK.CORE-1.2.0.JAR 131113 2024-10-14 00:00 LIB/COM.IO7M.MONTARRE.API-0.0.1-SNAPSHOT.JAR 48154 2024-10-14 00:00 LIB/COM.IO7M.MONTARRE.CMDLINE-0.0.1-SNAPSHOT.JAR 35065 2024-10-14 00:00 LIB/COM.IO7M.MONTARRE.IO-0.0.1-SNAPSHOT.JAR 175186 2024-10-14 00:00 LIB/COM.IO7M.MONTARRE.NATIVEPACK-0.0.1-SNAPSHOT.JAR 7016 2024-10-14 00:00 LIB/COM.IO7M.MONTARRE.SCHEMA-0.0.1-SNAPSHOT.JAR 55257 2024-10-14 00:00 LIB/COM.IO7M.MONTARRE.XML-0.0.1-SNAPSHOT.JAR 109688 2024-10-14 00:00 LIB/COM.IO7M.QUARREL.CORE-1.6.1.JAR 5985 2024-10-14 00:00 LIB/COM.IO7M.QUARREL.EXT.LOGBACK-1.6.1.JAR 9077 2024-10-14 00:00 LIB/COM.IO7M.SELTZER.API-1.1.0.JAR 9750 2024-10-14 00:00 LIB/COM.IO7M.STREAMTIME.CORE-1.0.0.JAR 11838 2024-10-14 00:00 LIB/COM.IO7M.VERONA.CORE-1.0.1.JAR 372687 2024-10-14 00:00 LIB/COMMONS-CODEC-1.17.1.JAR 1087319 2024-10-14 00:00 LIB/COMMONS-COMPRESS-1.27.1.JAR 515978 2024-10-14 00:00 LIB/COMMONS-IO-2.17.0.JAR 673587 2024-10-14 00:00 LIB/COMMONS-LANG3-3.17.0.JAR 304513 2024-10-14 00:00 LIB/LOGBACK-CLASSIC-1.5.8.JAR 619394 2024-10-14 00:00 LIB/LOGBACK-CORE-1.5.8.JAR 69435 2024-10-14 00:00 LIB/SLF4J-API-2.0.16.JAR 262317 2024-10-14 00:00 META/BOM.XML 102134 2024-10-14 00:00 META/ICON.ICO 41273 2024-10-14 00:00 META/ICON128.PNG 544 2024-10-14 00:00 META/ICON16.PNG 732 2024-10-14 00:00 META/ICON24.PNG 1973 2024-10-14 00:00 META/ICON32.PNG 5461 2024-10-14 00:00 META/ICON48.PNG 10050 2024-10-14 00:00 META/ICON64.PNG 768 2024-10-14 00:00 META/LICENSE.TXT 16002 2024-10-14 00:00 META/SCREENSHOT.PNG --------- ------- 4896322 42 files
<?xml version="1.0" encoding="UTF-8" ?> <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="urn:com.io7m.montarre.package:1" xmlns:mp="urn:com.io7m.montarre.package:1"> <xsd:simpleType name="ApplicationKindType"> <xsd:annotation> <xsd:documentation xml:lang="en"> The type of application. Many packaging systems and some operating systems distinguish between "console" and "graphical" applications. </xsd:documentation> </xsd:annotation> <xsd:restriction base="xsd:string"> <xsd:enumeration value="CONSOLE"/> <xsd:enumeration value="GRAPHICAL"/> </xsd:restriction> </xsd:simpleType> <xsd:simpleType name="VersionType"> <xsd:annotation> <xsd:documentation xml:lang="en"> An arbitrary version number. </xsd:documentation> </xsd:annotation> <xsd:restriction base="xsd:string"/> </xsd:simpleType> <xsd:simpleType name="CategoryNameType"> <xsd:annotation> <xsd:documentation xml:lang="en"> A category name. </xsd:documentation> </xsd:annotation> <xsd:restriction base="xsd:string"> <xsd:pattern value="[A-Z][A-Za-z0-9_-]{0,128}"/> </xsd:restriction> </xsd:simpleType> <xsd:simpleType name="VendorIDType"> <xsd:annotation> <xsd:documentation xml:lang="en"> A vendor ID; A Lanark dotted name. </xsd:documentation> </xsd:annotation> <xsd:restriction base="xsd:string"> <xsd:pattern value="([a-z][a-z0-9_-]{0,63})(\.[a-z][a-z0-9_-]{0,62}){0,15}"/> </xsd:restriction> </xsd:simpleType> <xsd:simpleType name="PackageNameType"> <xsd:annotation> <xsd:documentation xml:lang="en"> A package name; A Lanark dotted name. </xsd:documentation> </xsd:annotation> <xsd:restriction base="xsd:string"> <xsd:pattern value="([a-z][a-z0-9_-]{0,63})(\.[a-z][a-z0-9_-]{0,62}){0,15}"/> </xsd:restriction> </xsd:simpleType> <xsd:simpleType name="ShortNameType"> <xsd:annotation> <xsd:documentation xml:lang="en"> A short package name. Used for systems such as Debian packages. </xsd:documentation> </xsd:annotation> <xsd:restriction base="xsd:string"> <xsd:pattern value="[a-z][a-z0-9_-]{0,128}"/> </xsd:restriction> </xsd:simpleType> <xsd:simpleType name="HashAlgorithmNameType"> <xsd:annotation> <xsd:documentation xml:lang="en"> A hash algorithm name. See " Java Security Standard Algorithm Names". </xsd:documentation> </xsd:annotation> <xsd:restriction base="xsd:string"> <xsd:pattern value="[A-Z][A-Z0-9_-]{0,128}"/> </xsd:restriction> </xsd:simpleType> <xsd:simpleType name="HashValueType"> <xsd:annotation> <xsd:documentation xml:lang="en"> A hex-encoded hash value. </xsd:documentation> </xsd:annotation> <xsd:restriction base="xsd:string"> <xsd:pattern value="[a-f0-9]{2,256}"/> </xsd:restriction> </xsd:simpleType> <xsd:simpleType name="OSNameType"> <xsd:annotation> <xsd:documentation xml:lang="en"> An operating system name. </xsd:documentation> </xsd:annotation> <xsd:restriction base="xsd:string"> <xsd:pattern value="[a-z][a-z0-9_-]{0,32}"/> </xsd:restriction> </xsd:simpleType> <xsd:simpleType name="ArchitectureNameType"> <xsd:annotation> <xsd:documentation xml:lang="en"> A hardware architecture name. </xsd:documentation> </xsd:annotation> <xsd:restriction base="xsd:string"> <xsd:pattern value="[a-z][a-z0-9_-]{0,32}"/> </xsd:restriction> </xsd:simpleType> <xsd:simpleType name="VendorNameType"> <xsd:annotation> <xsd:documentation xml:lang="en"> A vendor name. Must be a filesystem-safe name as these names can be used as directories in Windows installers. </xsd:documentation> </xsd:annotation> <xsd:restriction base="xsd:string"> <xsd:pattern value="[a-zA-Z][A-Za-z0-9_-]{0,128}"/> </xsd:restriction> </xsd:simpleType> <xsd:simpleType name="FlatpakPermissionType"> <xsd:annotation> <xsd:documentation xml:lang="en"> A flatpak permission. </xsd:documentation> </xsd:annotation> <xsd:restriction base="xsd:string"> <xsd:pattern value="--[a-z\-]+(=[a-zA-Z0-9\\._\-/:~]+)?"/> </xsd:restriction> </xsd:simpleType> <xsd:element name="Version"> <xsd:annotation> <xsd:documentation xml:lang="en"> Version information. </xsd:documentation> </xsd:annotation> <xsd:complexType> <xsd:attribute name="Number" type="xsd:string" use="required"> <xsd:annotation> <xsd:documentation xml:lang="en"> The version number. Typically in semantic version form ("2.0.0", "1.0.0-SNAPSHOT", etc). </xsd:documentation> </xsd:annotation> </xsd:attribute> <xsd:attribute name="Date" type="xsd:date" use="required"> <xsd:annotation> <xsd:documentation xml:lang="en"> The date the version was set. </xsd:documentation> </xsd:annotation> </xsd:attribute> </xsd:complexType> </xsd:element> <xsd:element name="Vendor"> <xsd:annotation> <xsd:documentation xml:lang="en"> A vendor. </xsd:documentation> </xsd:annotation> <xsd:complexType> <xsd:attribute name="ID" type="mp:VendorIDType" use="required"> <xsd:annotation> <xsd:documentation xml:lang="en"> The unique vendor ID. </xsd:documentation> </xsd:annotation> </xsd:attribute> <xsd:attribute name="Name" type="mp:VendorNameType" use="required"> <xsd:annotation> <xsd:documentation xml:lang="en"> The vendor name. </xsd:documentation> </xsd:annotation> </xsd:attribute> </xsd:complexType> </xsd:element> <xsd:element name="Category"> <xsd:annotation> <xsd:documentation xml:lang="en"> A category applied to an application. </xsd:documentation> </xsd:annotation> <xsd:complexType> <xsd:attribute name="Name" type="mp:CategoryNameType" use="required"/> </xsd:complexType> </xsd:element> <xsd:simpleType name="LinkRole"> <xsd:annotation> <xsd:documentation xml:lang="en"> The role of a link. </xsd:documentation> </xsd:annotation> <xsd:restriction base="xsd:string"> <xsd:enumeration value="ISSUES"/> <xsd:enumeration value="HOME_PAGE"/> <xsd:enumeration value="DONATION"/> <xsd:enumeration value="CONTACT"/> <xsd:enumeration value="FAQ"/> <xsd:enumeration value="TRANSLATE"/> <xsd:enumeration value="CONTRIBUTE"/> <xsd:enumeration value="SCM"/> </xsd:restriction> </xsd:simpleType> <xsd:element name="Link"> <xsd:annotation> <xsd:documentation xml:lang="en"> A link. </xsd:documentation> </xsd:annotation> <xsd:complexType> <xsd:attribute name="Role" type="mp:LinkRole" use="required"/> <xsd:attribute name="Target" type="xsd:anyURI" use="required"/> </xsd:complexType> </xsd:element> <xsd:element name="Copying"> <xsd:complexType> <xsd:attribute name="License" type="xsd:string" use="required"> <xsd:annotation> <xsd:documentation xml:lang="en"> An SPDX license identifier such as "ISC". </xsd:documentation> </xsd:annotation> </xsd:attribute> <xsd:attribute name="Copyright" type="xsd:string" use="required"> <xsd:annotation> <xsd:documentation xml:lang="en"> A copyright string such as "Copyright © 2024 Mark Raynsford <code@io7m.com> https://www.io7m.com". </xsd:documentation> </xsd:annotation> </xsd:attribute> </xsd:complexType> </xsd:element> <xsd:element name="JavaInfo"> <xsd:annotation> <xsd:documentation xml:lang="en"> Information relative to the Java runtime. </xsd:documentation> </xsd:annotation> <xsd:complexType> <xsd:attribute name="RequiredJDKVersion" type="xsd:unsignedLong" use="required"> <xsd:annotation> <xsd:documentation xml:lang="en"> The required JDK version. </xsd:documentation> </xsd:annotation> </xsd:attribute> <xsd:attribute name="MainModule" type="xsd:string" use="required"> <xsd:annotation> <xsd:documentation xml:lang="en"> The main application module. This should be in a fully-qualified module form such as "com.io7m.montarre.cmdline/com.io7m.montarre.cmdline.MMain". </xsd:documentation> </xsd:annotation> </xsd:attribute> </xsd:complexType> </xsd:element> <xsd:element name="Names"> <xsd:annotation> <xsd:documentation xml:lang="en"> Package name information. </xsd:documentation> </xsd:annotation> <xsd:complexType> <xsd:attribute name="Name" type="mp:PackageNameType" use="required"> <xsd:annotation> <xsd:documentation xml:lang="en"> The package name. </xsd:documentation> </xsd:annotation> </xsd:attribute> <xsd:attribute name="ShortName" type="mp:ShortNameType" use="required"> <xsd:annotation> <xsd:documentation xml:lang="en"> The package short name. The short name is used when exporting to some native package systems such as Debian packages. </xsd:documentation> </xsd:annotation> </xsd:attribute> <xsd:attribute name="HumanName" type="xsd:string" use="optional"> <xsd:annotation> <xsd:documentation xml:lang="en"> The optional human-readable application name. This will default to the package name if not specified. </xsd:documentation> </xsd:annotation> </xsd:attribute> </xsd:complexType> </xsd:element> <xsd:simpleType name="FlatpakRuntimeRole"> <xsd:restriction base="xsd:string"> <xsd:enumeration value="PLATFORM"/> <xsd:enumeration value="SDK"/> </xsd:restriction> </xsd:simpleType> <xsd:element name="FlatpakPermission"> <xsd:complexType> <xsd:attribute name="Value" use="required" type="mp:FlatpakPermissionType"> <xsd:annotation> <xsd:documentation xml:lang="en"> A flatpak permission such as "--share=network", "--share=ipc", etc. </xsd:documentation> </xsd:annotation> </xsd:attribute> </xsd:complexType> </xsd:element> <xsd:element name="FlatpakRuntime"> <xsd:complexType> <xsd:attribute name="Name" use="required" type="xsd:string"> <xsd:annotation> <xsd:documentation xml:lang="en"> A flatpak runtime such as "org.freedesktop.Platform". </xsd:documentation> </xsd:annotation> </xsd:attribute> <xsd:attribute name="Version" use="required" type="xsd:string"> <xsd:annotation> <xsd:documentation xml:lang="en"> A flatpak runtime version such as "24.08". </xsd:documentation> </xsd:annotation> </xsd:attribute> <xsd:attribute name="Role" use="required" type="mp:FlatpakRuntimeRole"> <xsd:annotation> <xsd:documentation xml:lang="en"> A runtime role such as "PLATFORM" or "SDK". </xsd:documentation> </xsd:annotation> </xsd:attribute> </xsd:complexType> </xsd:element> <xsd:element name="Flatpak"> <xsd:annotation> <xsd:documentation xml:lang="en"> Metadata specific to Flatpak packages. </xsd:documentation> </xsd:annotation> <xsd:complexType> <xsd:sequence> <xsd:sequence minOccurs="0" maxOccurs="unbounded"> <xsd:element ref="mp:FlatpakPermission"/> </xsd:sequence> <xsd:sequence minOccurs="0" maxOccurs="unbounded"> <xsd:element ref="mp:FlatpakRuntime"/> </xsd:sequence> </xsd:sequence> </xsd:complexType> </xsd:element> <xsd:element name="Text"> <xsd:annotation> <xsd:documentation xml:lang="en"> A text element in a specific language. </xsd:documentation> </xsd:annotation> <xsd:complexType mixed="true"> <xsd:attribute name="Language" use="required" type="xsd:NMTOKEN"/> </xsd:complexType> </xsd:element> <xsd:element name="Description"> <xsd:annotation> <xsd:documentation xml:lang="en"> A humanly-readable package description. </xsd:documentation> </xsd:annotation> <xsd:complexType> <xsd:sequence minOccurs="0" maxOccurs="1"> <xsd:element ref="mp:Text"/> </xsd:sequence> </xsd:complexType> <xsd:unique name="DescriptionTextLanguageUnique"> <xsd:selector xpath="mp:Text"/> <xsd:field xpath="@Language"/> </xsd:unique> </xsd:element> <xsd:element name="Feature"> <xsd:complexType mixed="true"/> </xsd:element> <xsd:element name="Paragraph"> <xsd:complexType mixed="true"/> </xsd:element> <xsd:element name="LongDescription"> <xsd:complexType> <xsd:sequence> <xsd:sequence minOccurs="1" maxOccurs="unbounded"> <xsd:element ref="mp:Paragraph"/> </xsd:sequence> <xsd:sequence minOccurs="0" maxOccurs="unbounded"> <xsd:element ref="mp:Feature"/> </xsd:sequence> </xsd:sequence> <xsd:attribute name="Language" use="required" type="xsd:NMTOKEN"/> </xsd:complexType> </xsd:element> <xsd:element name="Caption"> <xsd:annotation> <xsd:documentation xml:lang="en"> A humanly-readable resource caption. </xsd:documentation> </xsd:annotation> <xsd:complexType> <xsd:sequence minOccurs="1" maxOccurs="unbounded"> <xsd:element ref="mp:Text"/> </xsd:sequence> </xsd:complexType> <xsd:unique name="CaptionTextLanguageUnique"> <xsd:selector xpath="mp:Text"/> <xsd:field xpath="@Language"/> </xsd:unique> </xsd:element> <xsd:element name="Metadata"> <xsd:complexType> <xsd:sequence> <xsd:sequence minOccurs="0" maxOccurs="unbounded"> <xsd:element ref="mp:Category"/> </xsd:sequence> <xsd:element ref="mp:Copying"/> <xsd:element ref="mp:Description"/> <xsd:sequence> <xsd:element ref="mp:Flatpak" minOccurs="0" maxOccurs="1"/> </xsd:sequence> <xsd:element ref="mp:JavaInfo"/> <xsd:sequence minOccurs="0" maxOccurs="unbounded"> <xsd:element ref="mp:Link"/> </xsd:sequence> <xsd:sequence minOccurs="0" maxOccurs="1"> <xsd:element ref="mp:LongDescription"/> </xsd:sequence> <xsd:element ref="mp:Names"/> <xsd:element ref="mp:Vendor"/> <xsd:element ref="mp:Version"/> </xsd:sequence> <xsd:attribute name="ApplicationKind" type="mp:ApplicationKindType" use="required"> <xsd:annotation> <xsd:documentation xml:lang="en"> The kind of the application. </xsd:documentation> </xsd:annotation> </xsd:attribute> </xsd:complexType> </xsd:element> <xsd:element name="PlatformDependentModule"> <xsd:annotation> <xsd:documentation xml:lang="en"> A module that is only used when running on a specific platform. </xsd:documentation> </xsd:annotation> <xsd:complexType> <xsd:attribute name="File" type="xsd:string" use="required"> <xsd:annotation> <xsd:documentation xml:lang="en"> The file name within the package. </xsd:documentation> </xsd:annotation> </xsd:attribute> <xsd:attribute name="HashAlgorithm" type="mp:HashAlgorithmNameType" use="required"> <xsd:annotation> <xsd:documentation xml:lang="en"> The file hash algorithm name. </xsd:documentation> </xsd:annotation> </xsd:attribute> <xsd:attribute name="HashValue" type="mp:HashValueType" use="required"> <xsd:annotation> <xsd:documentation xml:lang="en"> The file hash value. </xsd:documentation> </xsd:annotation> </xsd:attribute> <xsd:attribute name="OperatingSystem" type="mp:OSNameType" use="required"> <xsd:annotation> <xsd:documentation xml:lang="en"> The operating system on which this module is used. </xsd:documentation> </xsd:annotation> </xsd:attribute> <xsd:attribute name="Architecture" type="mp:ArchitectureNameType" use="required"> <xsd:annotation> <xsd:documentation xml:lang="en"> The hardware architecture on which this module is used. </xsd:documentation> </xsd:annotation> </xsd:attribute> </xsd:complexType> </xsd:element> <xsd:element name="Module"> <xsd:annotation> <xsd:documentation xml:lang="en"> A module that is used on all platforms. </xsd:documentation> </xsd:annotation> <xsd:complexType> <xsd:attribute name="File" type="xsd:string" use="required"> <xsd:annotation> <xsd:documentation xml:lang="en"> The file name within the package. </xsd:documentation> </xsd:annotation> </xsd:attribute> <xsd:attribute name="HashAlgorithm" type="mp:HashAlgorithmNameType" use="required"> <xsd:annotation> <xsd:documentation xml:lang="en"> The file hash algorithm name. </xsd:documentation> </xsd:annotation> </xsd:attribute> <xsd:attribute name="HashValue" type="mp:HashValueType" use="required"> <xsd:annotation> <xsd:documentation xml:lang="en"> The file hash value. </xsd:documentation> </xsd:annotation> </xsd:attribute> </xsd:complexType> </xsd:element> <xsd:simpleType name="ResourceRole"> <xsd:restriction base="xsd:string"> <xsd:enumeration value="BOM"/> <xsd:enumeration value="ICON_128"/> <xsd:enumeration value="ICON_16"/> <xsd:enumeration value="ICON_24"/> <xsd:enumeration value="ICON_256"/> <xsd:enumeration value="ICON_32"/> <xsd:enumeration value="ICON_48"/> <xsd:enumeration value="ICON_64"/> <xsd:enumeration value="ICO_WINDOWS"/> <xsd:enumeration value="LICENSE"/> <xsd:enumeration value="SCREENSHOT"/> </xsd:restriction> </xsd:simpleType> <xsd:element name="Resource"> <xsd:annotation> <xsd:documentation xml:lang="en"> A metadata resource. </xsd:documentation> </xsd:annotation> <xsd:complexType> <xsd:sequence> <xsd:element ref="mp:Caption" minOccurs="0" maxOccurs="1"/> </xsd:sequence> <xsd:attribute name="File" type="xsd:string" use="required"> <xsd:annotation> <xsd:documentation xml:lang="en"> The file name within the package. </xsd:documentation> </xsd:annotation> </xsd:attribute> <xsd:attribute name="HashAlgorithm" type="mp:HashAlgorithmNameType" use="required"> <xsd:annotation> <xsd:documentation xml:lang="en"> The file hash algorithm name. </xsd:documentation> </xsd:annotation> </xsd:attribute> <xsd:attribute name="HashValue" type="mp:HashValueType" use="required"> <xsd:annotation> <xsd:documentation xml:lang="en"> The file hash value. </xsd:documentation> </xsd:annotation> </xsd:attribute> <xsd:attribute name="Role" type="mp:ResourceRole" use="required"> <xsd:annotation> <xsd:documentation xml:lang="en"> The role of the resource. </xsd:documentation> </xsd:annotation> </xsd:attribute> </xsd:complexType> </xsd:element> <xsd:group name="ManifestItemGroup"> <xsd:choice> <xsd:element ref="mp:Module"/> <xsd:element ref="mp:PlatformDependentModule"/> <xsd:element ref="mp:Resource"/> </xsd:choice> </xsd:group> <xsd:element name="Manifest"> <xsd:complexType> <xsd:sequence minOccurs="0" maxOccurs="unbounded"> <xsd:group ref="mp:ManifestItemGroup"/> </xsd:sequence> </xsd:complexType> <xsd:key name="ManifestItemUnique"> <xsd:selector xpath="mp:Module|mp:PlatformDependentModule|mp:BOM"/> <xsd:field xpath="@File"/> </xsd:key> </xsd:element> <xsd:element name="Package"> <xsd:complexType> <xsd:sequence> <xsd:element ref="mp:Metadata"/> <xsd:element ref="mp:Manifest"/> </xsd:sequence> </xsd:complexType> </xsd:element> </xsd:schema>
Require Import Coq.Unicode.Utf8_core. Require Import Coq.Strings.String. Require Import Coq.Strings.Ascii. Require Import Coq.FSets.FMapInterface. Require Import Coq.FSets.FMapWeakList. Require Import Coq.FSets.FMapFacts. Require Import Coq.Structures.Equalities. (** A mini decidable type module to instantiate maps. *) Module StringMiniDec : MiniDecidableType with Definition t := string. Definition t := string. Definition eq := @Logic.eq t. Definition eq_refl := @Logic.eq_refl t. Definition eq_sym := @Logic.eq_sym t. Definition eq_trans := @Logic.eq_trans t. Theorem eq_dec : forall x y : t, {eq x y} + {~ eq x y}. Proof. apply string_dec. Qed. End StringMiniDec. (** A usual decidable type module to instantiate maps. *) Module StringDec <: UsualDecidableType with Definition t := string with Definition eq := @Logic.eq string := Make_UDT StringMiniDec. (** A Maps module with string keys. *) Module StringMaps : FMapInterface.WS with Definition E.t := string with Definition E.eq := @Logic.eq string := FMapWeakList.Make StringDec. (** The opaque, abstract type of regular expressions. *) Parameter RegularExpressionT : string -> Set. (** For the sake of specification simplicity, we assume that all strings are valid regular expressions. *) Parameter regex : forall (s : string), RegularExpressionT s. (** A proposition that states that a given regular expression matches a given string. *) Parameter matches : forall (s : string) {e : string}, RegularExpressionT e -> Prop. (** Whether a string matches a regular expression is decidable. *) Parameter matchesDecidable : forall (s : string) {e : string} (r : RegularExpressionT e), {matches s r}+{~matches s r}. Definition lanarkDottedString := forall (s : string), matches s (regex "([a-z][a-z0-9_-]{0,63})(\.[a-z][a-z0-9_-]{0,62}){0,15}"). Inductive ApplicationKindT := | CONSOLE | GRAPHICAL . Inductive CategoryT := Category : forall (s : string), matches s (regex "[A-Z][A-Za-z0-9_-]{0,128}") -> CategoryT. Definition LicenseT := string. Definition CopyrightT := string. Inductive CopyingT := Copying { license : LicenseT; copyright : CopyrightT }. Definition LanguageT := string. (** A Maps module with language keys. *) Module LanguageMaps : FMapInterface.WS with Definition E.t := LanguageT with Definition E.eq := @Logic.eq LanguageT := FMapWeakList.Make StringDec. Inductive TranslatedTextT := TranslatedText { language : LanguageT; text : string; translations : LanguageMaps.t string }. Definition DescriptionT := TranslatedTextT. Inductive JavaInfoT := JavaInfo { requiredJDKVersion : nat; mainModule : string }. Inductive LinkRoleT := | ISSUES | HOME_PAGE | DONATION | CONTACT | FAQ | TRANSLATE | CONTRIBUTE | SCM . Inductive LinkT := Link { linkRole : LinkRoleT; linkTarget : string }. Inductive VendorNameT := VendorName : forall (s : string), matches s (regex "[a-zA-Z][A-Za-z0-9_-]{0,128}") -> VendorNameT. Definition VendorIDT := lanarkDottedString. Inductive VendorT := Vendor { vendorId : VendorIDT; vendorName : VendorNameT }. Inductive VersionNumberT := VersionNumber { major : nat; minor : nat; patch : nat; qualifier : option string }. Inductive VersionDateT := VersionDate : forall (s : string), matches s (regex "[0-9]{4}-[0-9]{2}-[0-9]{2}") -> VersionDateT. Inductive VersionT := Version { versionNumber : VersionNumberT; versionDate : VersionDateT }. Definition ParagraphT := string. Definition FeatureT := string. Inductive LongDescriptionT := LongDescription { descriptionLanguage : LanguageT; descriptions : list ParagraphT; features : list FeatureT }. Inductive FlatpakRuntimeRoleT := | SDK | PLATFORM . Definition FlatpakPermissionT := string. Inductive FlatpakRuntimeT := FlatpakRuntime { flatpakRuntimeName : string; flatpakRuntimeVersion : string; flatpakRuntimeRole : FlatpakRuntimeRoleT }. Inductive FlatpakT := Flatpak { flatpakPermissions : list FlatpakPermissionT; flatpakRuntimes : list FlatpakRuntimeT }. Definition PackageNameT := lanarkDottedString. Inductive ShortNameT := ShortName : forall (s : string), matches s (regex "[a-z][a-z0-9_-]{0,128}") -> ShortNameT. Definition HumanNameT := string. Inductive NamesT := Names { namePackage : PackageNameT; nameShort : ShortNameT; nameHuman : HumanNameT }. Inductive MetadataT := Metadata { metaApplicationKind : ApplicationKindT; metaCategories : list CategoryT; metaCopying : CopyingT; metaDescription : DescriptionT; metaFlatpak : FlatpakT; metaJavaInfo : JavaInfoT; metaLinks : list LinkT; metaLongDescriptions : LanguageMaps.t LongDescriptionT; metaNames : NamesT; metaVendor : VendorT; metaVersion : VersionT }. Definition HashAlgorithmT := string. Inductive HashValueT := HashValue : forall (s : string), matches s (regex "[a-f0-9]{2,256}") -> HashValueT. Inductive HashT := Hash { hashAlgorithm : HashAlgorithmT; hashValue : HashValueT }. Inductive ArchitectureNameT := ArchitectureName : forall (s : string), matches s (regex "[a-z][a-z0-9_-]{0,32}") -> ArchitectureNameT. Inductive OperatingSystemNameT := OperatingSystemName : forall (s : string), matches s (regex "[a-z][a-z0-9_-]{0,32}") -> OperatingSystemNameT. Inductive PlatformT := Platform { platformArch : ArchitectureNameT; platformOS : OperatingSystemNameT }. (** A function that produces an uppercase version of the given string. *) Parameter uppercaseOf : string -> string. Definition uppercaseSame (s t : string) := uppercaseOf s = uppercaseOf t. Inductive FileNameT := FileName : forall (s : string), matches s (regex "([\p{L}\p{N}_\-.+]+)(/[\p{L}\p{N}_\-.+]+)*") -> FileNameT. (** A proposition that states that two file names are the same if their uppercase transformations are the same. *) Definition fileNamesSame (s t : FileNameT) := match s, t with | FileName fs _, FileName ft _ => uppercaseSame fs ft end. Inductive ResourceRoleT := | BOM | LICENSE | ICO_WINDOWS | ICON_16 | ICON_24 | ICON_32 | ICON_48 | ICON_64 | ICON_128 | ICON_256 | ICON_512 | ICON_SVG | SCREENSHOT . Definition CaptionT := TranslatedTextT. Inductive ModuleT := Module : FileNameT -> HashT -> ModuleT. Inductive PlatformModuleT := PlatformModule : FileNameT -> HashT -> PlatformT -> PlatformModuleT. Inductive ResourceT := Resource : FileNameT -> HashT -> ResourceRoleT -> CaptionT -> ResourceT. Inductive ItemT := | ItemModule : ModuleT -> ItemT | ItemPlatformModule : PlatformModuleT -> ItemT | ItemResource : ResourceT -> ItemT . Definition itemFileName (i : ItemT) : FileNameT := match i with | ItemModule (Module f _) => f | ItemPlatformModule (PlatformModule f _ _) => f | ItemResource (Resource f _ _ _) => f end. Definition itemHash (i : ItemT) : HashT := match i with | ItemModule (Module _ h) => h | ItemPlatformModule (PlatformModule _ h _) => h | ItemResource (Resource _ h _ _) => h end. Inductive ManifestT := Manifest { manifestItems : list ItemT }. Definition manifesItemsFilenamesUnique := forall (m : ManifestT), forall (i0 : ItemT), In i0 (manifestItems m) -> ~(exists i1 : ItemT, (In i1 (manifestItems m)) /\ (i0 <> i1) /\ (fileNamesSame (itemFileName i0) (itemFileName i1))).
1 |
Vendor names are used in some native packaging systems as installation directories
and are therefore required to be
filesystem-safe.
References to this footnote:
1
|
2 |
Short names are used in some native packaging systems as executable names and are
therefore required to be
filesystem-safe.
References to this footnote:
1
|
3 |
Many hardware architectures have different names referring to the same thing. For
example, 64-bit x86 hardware is
often referred to as amd64, x64,
x86_64, etc.
References to this footnote:
1
|