Configuration

Overview of settings and options.

Plugify uses three main configuration files to manage its behavior, plugins, and language modules: plugify.pconfig, *.pplugin, and *.pmodule. Below is a detailed explanation of each file and its configuration options.

Config Manifest

The plugify.pconfig file is required for the plug testing app to locate the res directory and configure its behavior. It should be placed in the root directory and contain the following fields:

plugify.pconfig
{
    "$schema": "https://raw.githubusercontent.com/untrustedmodders/plugify/refs/heads/main/schemas/config.schema.json",
    "baseDir": "res",
    "logSeverity": "debug",
    "repositories": [],
    "preferOwnSymbols": false
}

Configuration Options:

  • baseDir: Specifies the directory where plugins and language modules are located (default: res).
  • logSeverity: Controls the logging level (e.g., debug, info, error).
  • repositories: A list of remote repositories for downloading packages (leave empty for local testing).
  • preferOwnSymbols: Determines whether Plugify should prefer its own symbols over those provided by plugins (set to false for most use cases).

Plugin Manifest

The .pplugin file defines the configuration for a specific plugin. Below is an example:

*.pplugin
{
  "fileVersion": 1,
  "version": "1.0.0",
  "friendlyName": "Sample Plugin",
  "description": "This is a sample plugin.",
  "createdBy": "untrustedmodders",
  "createdByURL": "https://github.com/untrustedmodders/",
  "docsURL": "https://github.com/untrustedmodders/sample_plugin",
  "downloadURL": "https://github.com/untrustedmodders/sample_plugin/releases/download/v1.0/sample_plugin.zip",
  "updateURL": "https://raw.githubusercontent.com/untrustedmodders/sample_plugin/main/sample_plugin.json",
  "entryPoint": "bin/sample_plugin",
  "supportedPlatforms": [],
  "languageModule": {
    "name": "cpp"
  },
  "dependencies": [],
  "exportedMethods": []
}

Configuration Options:

  • fileVersion: The version number of the configuration file format.
  • version: The semantic version of the plugin.
  • friendlyName: A user-friendly name for the plugin.
  • description: A brief description or overview of the plugin.
  • createdBy: The creator or author of the plugin.
  • createdByURL: The URL linking to the creator's profile or information.
  • docsURL: The URL linking to the documentation for the plugin.
  • downloadURL: The URL for downloading the plugin, typically a release package or ZIP file.
  • updateURL: The URL for checking and fetching updates for the plugin.
  • entryPoint: The entry point or main executable for the plugin, specified as bin/sample_plugin. (Depends on the language module.)
  • supportedPlatforms: An array listing the platforms supported by the plugin. (Currently empty in this example.)
  • languageModule: Information about the programming language module used. In this case, it's specified as "cpp" (C++).
  • dependencies: A list of plugin references specifying the dependencies required for the plugin. This field is crucial for topological sorting to load plugins in the correct order of initialization.
  • exportedMethods: An array describing functions/methods exposed by the plugin.

Module Manifest

The .pmodule file defines the configuration for a language module. Below is an example:

*.pmodule
{
    "fileVersion": 1,
    "version": "1.0.0",
    "friendlyName": "C++ language module",
    "language": "cpp",
    "description": "Adds support for C++ plugins",
    "createdBy": "untrustedmodders",
    "createdByURL": "https://github.com/untrustedmodders/",
    "docsURL": "https://github.com/untrustedmodders/cpp-lang-module/README.md",
    "downloadURL": "https://github.com/untrustedmodders/cpp-lang-module/releases/download/v1.0/cpp-lang-module.zip",
    "updateURL": "https://raw.githubusercontent.com/untrustedmodders/cpp-lang-module/main/cpp-lang-module.json",
    "supportedPlatforms": [],
    "forceLoad": false
}

Configuration Options:

  • fileVersion: The version number of the configuration file format.
  • version: The semantic version of the language module.
  • friendlyName: A user-friendly name for the language module.
  • language: The programming language supported by this module (e.g., "cpp" for C++).
  • description: A brief description or overview of the language module.
  • createdBy: The creator or author of the language module.
  • createdByURL: The URL linking to the creator's profile or information.
  • docsURL: The URL linking to the documentation for the language module.
  • downloadURL: The URL for downloading the language module, typically a release package or ZIP file.
  • updateURL: The URL for checking and fetching updates for the language module.
  • supportedPlatforms: An array listing the platforms supported by the language module.
  • forceLoad: A boolean indicating whether the language module should be forcibly loaded by the core.

Notes:

  • Ensure all configuration files are valid JSON and adhere to the schema provided by Plugify.
  • Use the $schema field to validate your configuration files against the official schema.
  • For local testing, leave the repositories field in plugify.pconfig empty.