Skip to main content

embed scripting engine by Infrared LLC.

Project description

🧱 lanectl

lanectl is the embed scripting engine for infrared.

It parses a block of text, replaces variables, and turns it into an embed with an optional discord.ui.View.
No GUI. No builder. Just script → message.


▶ Example

{content:welcome, {user.name}}
{title:infrared online}
{description:this server runs cold}
{color:#ED1C24}
{author:Pusha && https://i.imgur.com/pusha.png}
{field:Rank && King && inline}
{footer:real bars only && https://i.imgur.com/footer.png}
{button:enter && 🚪 && https://infrared.something && red}
{timestamp}

✅ Supported Fields

All fields are optional. Missing values are ignored.

Field Format
content {content:text}
title {title:text}
description {description:text}
color {color:#hex}
author {author:Name && Icon && URL}
footer {footer:Text && Icon}
field {field:Name && Value && inline}
button {button:Label && Emoji && URL && Style}
timestamp {timestamp}

🔀 Variables

Variables are replaced in any field.

{user}, {user.name}, {user.id}, {user.avatar}, {user.created_at}, {user.joined_at}
{guild}, {guild.name}, {guild.id}, {guild.owner}, {guild.member_count}, {guild.created_at}
{target}, {target.name}, {target.id}, {target.avatar}, ...

🧪 Bot Usage

from lanectl import Lane

@bot.command()
async def createembed(ctx, *, script: str):
    r = Lane(script, ctx.author)

    await ctx.send(
        content=r.content,
        embed=r.render(),
        view=r.view()
    )

If the script defines nothing, r.content, r.render(), and r.view() all return None.


⚙️ Install

pip install lane

Or just copy the lanectl/ folder into your project, i dont really care.


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

lanectl-0.3.0.tar.gz (8.3 kB view details)

Uploaded Source

Built Distribution

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

lanectl-0.3.0-py3-none-any.whl (9.3 kB view details)

Uploaded Python 3

File details

Details for the file lanectl-0.3.0.tar.gz.

File metadata

  • Download URL: lanectl-0.3.0.tar.gz
  • Upload date:
  • Size: 8.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.18

File hashes

Hashes for lanectl-0.3.0.tar.gz
Algorithm Hash digest
SHA256 ee0477dee07f9271a9f47bbc80e53a243c86d96381b8d8af16ecef2ccc0c4ac1
MD5 988bf7a80b819b995faa63743815283e
BLAKE2b-256 f2c09712817d2e7f66ae44f674770500b2ee1d2f7eadd6a6676b8d43f509bd89

See more details on using hashes here.

File details

Details for the file lanectl-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: lanectl-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 9.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.18

File hashes

Hashes for lanectl-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 5749e88ef26959eef54917b69c9934acabf73d169d1aff49af08b225a49f9ff3
MD5 8d661309bcbee70beccb913394aee995
BLAKE2b-256 c8916b8671970fe0691ea8549259de1724e12435d9df827067fb76441c2364ec

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