
Product
Introducing Rust Support in Socket
Socket now supports Rust and Cargo, offering package search for all users and experimental SBOM generation for enterprise projects.
Advanced syntax highlighting library with built-in compiler (dockr) for multiple languages.
pip install highlighter
from highlighter import Highlighter
hl = Highlighter()
code = """
def hello(name):
print(f"Hello, {name}!")
"""
# Get HTML output
html_output = hl.highlight(code, "python")
print(html_output)
# Get terminal output
term_output = hl.highlight(code, "python", output_format="terminal")
print(term_output)
# Get CSS for the highlighting
print(hl.get_css())
from highlighter import DockrCompiler
compiler = DockrCompiler()
code = """
#include <stdio.h>
int main() {
printf("Hello from C!\\n");
return 0;
}
"""
output, error, return_code = compiler.compile_and_run(code, "c")
print(f"Output: {output}")
print(f"Error: {error}")
print(f"Return code: {return_code}")
# Run a Python file
dockr script.py
# Run a C file with input
dockr program.c -i input.txt
MIT
FAQs
Advanced syntax highlighter with built-in compiler
We found that pyhighlighter-c demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
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.
Product
Socket now supports Rust and Cargo, offering package search for all users and experimental SBOM generation for enterprise projects.
Product
Socket’s precomputed reachability slashes false positives by flagging up to 80% of vulnerabilities as irrelevant, with no setup and instant results.
Product
Socket is launching experimental protection for Chrome extensions, scanning for malware and risky permissions to prevent silent supply chain attacks.