Packager configuration
The packager takes all the defined html, js, css, ... files and bundles them into the application binary. To make this possible, a configuration file is required for the packager.
miletus.config.json
The structure of the configuration file with default values follows as:
{
"name": "",
"productName": "",
"description": "",
"version": "",
"fileVersion": "",
"company": "",
"output": "output",
"debug": false,
"main": {
"html": "",
"width": 640,
"height": 480,
"title": "",
"stayOnTop": false,
"maximized": false,
"minimized": false,
"border": "sizeable",
"borderIcons": ["minimize", "maximize", "close"],
"position": "default"
},
"target": [],
"icon": {
"win": "",
"mac": "",
"linux": "",
"raspi": ""
},
"include": [],
"deploy": []
}
name
string
- The name of the application. It will be used as the executable name too.
productName (Windows only)
string
- Corresponds to FileVersionInfo.ProductName.
This property is only supported on Windows. It will be ignored for macOS, Linux and Rapsberry Pi.
description
string
- Description of the application.
version
string
- A .
separated value, the application version. Default value is 1.0.0
.
On Windows an additional number can be added. See FileVersionInfo.ProductVersion.
fileVersion (Windows only)
string
- A .
separated value, corresponds to FileVersionInfo.FileVersion. Default value is 1.0.0.0
.
This property is only supported on Windows. It will be ignored for macOS, Linux and Raspberry Pi.
company (Windows only)
string
- Corresponds to FileVersionInfo.CompanyName.
This property is only supported on Windows. It will be ignored for macOS, Linux and Raspberry Pi.
output
string
- Output folder for the packaged applications. If left empty, the same directory will be used where the miletus.config.json
file can be found.
debug
boolean
- Determines if debugging capabilities should be enabled in the application.
main
object
- This section describes the main application window.
-
html
string
- The entry point to the application, the main HTML file.This is a mandatory field.
-
width
number
- The width of the main application window. Default value is640
. -
height
number
- The height of the main application window. Default value is480
. -
title
string
- The title of the main application window. Default value is""
. -
stayOnTop
boolean
- Determines if the main application windows should stay on top of all other application windows. Default value isfalse
. -
maximized
boolean
- Determines if the main application window should be maximized at start. Default value isfalse
. -
minimized
boolean
- Determines if the main application window should be minimzed at start. Default value isfalse
. -
border
string
- The type of the application window border.-
none
- No border will be shown. -
single
- Border is visible but the window cannot be resized manually. -
sizeable
(Default) - Border is visible and the window can be resized manually.
-
-
borderIcons
string[]
- The border icons to be shown in the application titlebar. By default all values are added. Supported values:-
minimize
-
maximize
-
close
-
-
position
string
- The position of the main application window on the screen.-
default
(Default) - Default position. -
screenCenter
- The window is positioned in the center of the screen. Note that in multi-monitor applications, this may result in a window that does not fall entirely on one monitor. -
desktopCenter
- The window is positioned in the center of the screen.
-
target
string[]
- A string array containing all the targets. Supported values:
-
win_ia32
-
win_x64
-
linux_x64
-
mac_x64
-
mac_arm64
-
raspi_armv7l
icon
object
- Contains the icons for all platforms separately.
-
win
Path to the Windows icon. The supported extension is
.ico
. -
mac
Path to the macOS icon. The supported extension is
.icns
. -
linux
Path to the Linux icon. The supported extension is
.png
. -
raspi
Path to the Raspberry icon. The supported extension is
.png
.
include
string[]
- A list of files to include (html, js, css, etc...) that build up the web application.
If not present, all files are bundled form the root directory.
Wildcards are supported (for example: src/*
will contain all files from the src
folder).
deploy
string[]
- A list of files to deploy into the output folder.