Skip to content

Instantly share code, notes, and snippets.

@dorneanu
dorneanu / plugin_architecture.md
Last active April 9, 2025 16:18
Python: Implement basic plugin architecture with Python and importlib

Implementing a basic plugin architecture shouldn't be a complicated task. The solution described here is working but you still have to import every plugin (inheriting from the base class).

This is my solution:

Basic project structure

$ tree
@justincbagley
justincbagley / How_to_Convert_Markdown_to_PDF.md
Last active March 27, 2025 03:38
How To Convert Markdown to PDF

How to convert markdown to PDF:

This post reviews several methods for converting a Markdown (.md) formatted file to PDF, from UNIX or Linux machines.

Using Pandoc:

$ pandoc How_I_got_svg-resizer_working_on_Mac_OSX.md -s -o test1.pdf
@tmakin
tmakin / ExportPdf.cs
Last active October 24, 2024 21:21
Create PDF Rendering service in Azure Functions
using System.Net;
using System.Net.Http;
using System.Net.Http.Headers;
using System.Threading.Tasks;
using DinkToPdf;
using Microsoft.AspNetCore.Http;
using Microsoft.Azure.WebJobs;
using Microsoft.Azure.WebJobs.Extensions.Http;
using Microsoft.Extensions.Logging;
using IPdfConverter = DinkToPdf.Contracts.IConverter;
@gothburz
gothburz / sharedmedia.lua
Created December 5, 2015 20:24
Add new fonts to ElvUI complete UI system for World of Warcraft
--[[
Navigate to your main WoW installation folder then go into Interface/AddOns/ElvUI
Steps:
1) Drop .ttf files into ElvUI/media/fonts
2) Go up a directory into ElvUI/media and open sharedmedia.lua, add this line
LSM:Register("font","XX", [[Interface\AddOns\ElvUI\media\fonts\XX.ttf]])
@jbarrett
jbarrett / chmayor.pl
Created March 18, 2013 20:38
First pass at a script to change the mayor and organisation name in SimCity 2000 for DOS
#!/usr/bin/env perl
# Change the mayor's name in SimCity 2000
#
# You should probably stick with plain ASCII if you use it.
use strict;
use warnings;
use bytes;