🚀 Big News:Socket Has Acquired Secure Annex.Learn More →
Socket
Book a DemoSign in
Socket

termynal

Package Overview
Dependencies
Maintainers
1
Versions
25
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

termynal

A lightweight and modern animated terminal window

pipPyPI
Version
0.14.0
Maintainers
1

Termynal

GitHub Workflow Status PyPI PyPI - Python Version Docs GitHub PyPI - Downloads GitHub last commit

A lightweight and modern animated terminal window. Built for mkdocs and zensical.

Installation

termynal

Examples

Usage

Use <!-- termynal --> before code block

<!-- termynal -->

```
$ python script.py
```

Mkdocs integration

Declare the plugin:

...
plugins:
  - termynal
...

Optionally, pass options to the processor:

[...]
plugins:
  - termynal:
      prompt_literal_start:
        - "$"
        - ">"
[...]

If you do not want to copy termynal.css and termynal.js as static files, you can embed them directly in generated HTML:

[...]
plugins:
  - termynal:
      include_assets: true
[...]

This config allows you to use another prompt:

<!-- termynal -->

```
> pip install termynal
---> 100%
Installed
```

Zensical integration

zensical does not support arbitrary MkDocs plugins yet, but it supports Python Markdown extensions. Use termynal as a markdown extension and enable inline assets:

[project.markdown_extensions.termynal]
include_assets = true
title = "bash"
buttons = "macos"
prompt_literal_start = ["$"]

You can override default assets with your own files:

[project.markdown_extensions.termynal]
include_assets = true
assets_override_css = "docs/stylesheets/termynal.css"
assets_override_js = "docs/javascripts/termynal.js"

For Zensical-style asset management, keep include_assets = false and register assets explicitly:

[project]
extra_css = ["stylesheets/termynal.css"]
extra_javascript = ["javascripts/termynal.js"]

[project.markdown_extensions.termynal]
include_assets = false

Credits

Thanks ines

Contribution

Contribution guidelines for this project

Keywords

markdown

FAQs

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts