Table of Contents
sense.toml
The sense.toml file contains all important meta data of a given Sense. As you can probably glean from the file extension, these files are in the TOML 1.0.0 format. If you're unsure about the formatting, refer to the linked documentation. The general structure of the file is roughly inspired by Cargo.toml used by projects in Rust programming language.
The values in this file can be read out during runtime in the info
table in the sense global.
Sections
These are the sections that are expected within a Sense.toml file. Unrecognised or otherwise unsupported values should not cause errors, but should be avoided.
version
This field is required! Versions are formatted according to the SemVer 2.0.0 specification.
Remember to change these values if you make changes to a Sense. For fixing bugs increment PATCH, if you added a feature without disrupting existing functionality increment MINOR, and if you think your change overhauled things significantly enough, or changed the way the Sense was previously interacted with entirely, increment MAJOR!
This field is most important for library Senses but it is good practice to keep it maintained anyway, this value is used by the dependency resolver and the runtime loader can also set version constraints.
Example
Value used by the forex
Sense.
version = "1.0.4"
description
The description field is a string containing a short summary explaining what this Sense package does.
Example
Value used by the die
Sense.
description = "The command that allows you to roll the dice."
authors
The authors field is an array containing the authors of a Sense.
You can just specify a name like "flashwave"
, but you may also include your e-mail address like "flash <me@flash.moe>"
.
Example
Value used by the gork
Sense.
authors = [ "flashwave <me@flash.moe>", "Neeko" ]
sources
The sources field is an array containing the paths to all Lua scripts that should be executed, in the order specified.
Paths are relative to the Sense package directory, however you should NEVER traverse the directory structure upwards!
Example
Value used by the splatoon
Sense.
sources = [ "utils.lua", "games/splatoon1.lua", "games/splatoon2.lua", "games/splatoon3.lua", "festival.lua", "schedule.lua", "splatoon.lua" ]
[depends]
This table contains the list of dependencies this Sense package has on other Sense packages.
Each key/value pair, both strings, is interpreted a Sense library name as the key and the value containing the accepted range of versions. The format of these ranges works as described on semver.npmjs.com.
Example
Value used by the urlmeta
Sense.
[depends] strexts = "^1.0"