Skip to content

Instantly share code, notes, and snippets.

View jdc-cunningham's full-sized avatar

Jacob David C Cunningham jdc-cunningham

View GitHub Profile
@cb372
cb372 / riscv.md
Last active April 2, 2024 06:41
Writing an OS in Rust to run on RISC-V

(This is a translation of the original article in Japanese by moratorium08.)

(UPDATE (22/3/2019): Added some corrections provided by the original author.)

Writing your own OS to run on a handmade CPU is a pretty ambitious project, but I've managed to get it working pretty well so I'm going to write some notes about how I did it.

@devStepsize
devStepsize / slack_webhook_post.py
Last active August 7, 2023 09:28
POST a JSON payload to a Slack Incoming Webhook using Python requests
'''
This is an example of how to send data to Slack webhooks in Python with the
requests module.
Detailed documentation of Slack Incoming Webhooks:
https://api.slack.com/incoming-webhooks
'''
import json
import requests
@aweijnitz
aweijnitz / install_CUPS_all_defaults.sh
Last active November 12, 2023 19:55
Installing CUPS printer on Debian and add PDF printer
#!/bin/bash
sudo apt-get -y install cups
sudo apt-get -y install cups-pdf
# add pdf printer to cups
# - named files end up in ~/PDF/
# - unnamed files are stored in /var/spool/cups-pdf/ANONYMOUS/, such as PDF:s created by streaming bytes over an API
sudo lpadmin -p cups-pdf -v cups-pdf:/ -E -P /usr/share/ppd/cups-pdf/CUPS-PDF.ppd