Skip to main content

Plugin SDK for building ForkBit plugins

Project description

ForkBit SDK

Build plugins for ForkBit — the desktop app for managing app store workflows.

Installation

pip install forkbit-sdk

Quick Start

Create a new plugin:

forkbit plugin init my_plugin

This generates a ready-to-run plugin scaffold:

my_plugin/
  plugin.json    — manifest (id, name, version, dependencies)
  main.py        — your plugin code (BasePlugin subclass)
  settings.json  — settings schema

Writing a Plugin

Every plugin is a BasePlugin subclass that builds its UI in on_ready():

from PySide6.QtCore import Qt
from PySide6.QtWidgets import QLabel, QVBoxLayout

from forkbit_sdk import BasePlugin


class MyPlugin(BasePlugin):

    def on_ready(self) -> None:
        layout = QVBoxLayout(self.container)
        layout.setAlignment(Qt.AlignmentFlag.AlignTop)

        label = QLabel("Hello from my plugin!")
        layout.addWidget(label)

Your plugin inherits the app's theme automatically — standard PySide6 widgets just work.

Plugin API

Property / Method Description
self.container QWidget — build your UI inside this
self.settings dict — current plugin settings values
self.project_id str — current project ID
self.project_path str — path to the project directory
self.data_dir Path — per-instance storage directory
self.git GitClient — git operations (status, tags, push, pull, commit)
self.read_json(filename) Read JSON from data_dir
self.write_json(filename, data) Atomic-write JSON to data_dir
self.notify(message, level) Show a toast notification
self.translate(text, src, tgt, on_done, on_error) Async translation
self.set_subtitle(text) Update the plugin header subtitle
self.secret_file(field_id) Get raw bytes of a secret file setting
on_ready() Override to build UI and initialize state
on_settings_changed(settings) Override to react to settings changes

Settings Schema

Define user-configurable settings in settings.json:

{
  "fields": [
    { "id": "api_key", "label": "API Key", "type": "password" },
    { "id": "auto_sync", "label": "Auto-sync on save", "type": "bool", "default": true }
  ]
}

Supported types: text, password, textarea, bool, secret_file.

Plugin Manifest

plugin.json defines your plugin's metadata:

{
  "id": "com.mycompany.myplugin",
  "name": "My Plugin",
  "version": "1.0.0",
  "description": "What it does",
  "entry": "main.py",
  "min_app_version": "0.2.0",
  "requirements": []
}

CLI Commands

forkbit plugin init [dir]        # scaffold a new plugin
forkbit plugin validate [dir]    # check manifest and imports
forkbit plugin build [dir]       # build for current platform
forkbit plugin release [dir]     # build for all platforms

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

forkbit_sdk-0.1.0.tar.gz (23.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

forkbit_sdk-0.1.0-py3-none-any.whl (18.9 kB view details)

Uploaded Python 3

File details

Details for the file forkbit_sdk-0.1.0.tar.gz.

File metadata

  • Download URL: forkbit_sdk-0.1.0.tar.gz
  • Upload date:
  • Size: 23.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.2

File hashes

Hashes for forkbit_sdk-0.1.0.tar.gz
Algorithm Hash digest
SHA256 9b3f94d3e8b890963b3cf44fce071d2c5b35ef1025e197a1079f09cfd3b7471d
MD5 82d50861411dd0bd96bed54cf3289e31
BLAKE2b-256 34bb255ae16c1abe7f16b9addb8fdb9397b6c4b182ea0c5a948e31881e2bce93

See more details on using hashes here.

File details

Details for the file forkbit_sdk-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: forkbit_sdk-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 18.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.2

File hashes

Hashes for forkbit_sdk-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 2c27fea9e796222549f8c27a9b489bf7be6fe6d7dfed52d30a0a8ff89cebfe60
MD5 3b7f6c3bd7b309723f78d76db20e8612
BLAKE2b-256 7a63e337aad670f0a4e7c5a9a2b1d9381837149437071fb6c0bb1a1cbfa322a9

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page