Skip to content

Instantly share code, notes, and snippets.

View CnrLwlss's full-sized avatar

Conor Lawless CnrLwlss

View GitHub Profile
@jasikpark
jasikpark / mathjax-script-for-hugo.js
Created September 3, 2018 18:37
MathJax config for Hugo
<script type="text/javascript" async
src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-AMS-MML_HTMLorMML">
MathJax.Hub.Config({
tex2jax: {
inlineMath: [['$','$'], ['\\(','\\)']],
displayMath: [['$$','$$']],
processEscapes: true,
processEnvironments: true,
skipTags: ['script', 'noscript', 'style', 'textarea', 'pre'],
TeX: { equationNumbers: { autoNumber: "AMS" },
@TimSC
TimSC / mjpeg.py
Last active April 5, 2020 01:59
Python code to parse a JPEG structure and to convert Motion JPEG/MJPG binary data to standard JPEG. This code may be used under CC0.
import struct
huffmanSegment = '\xFF\xC4\x01\xA2\x00\x00\x01\x05\x01\x01\x01\x01'\
'\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x01\x02'\
'\x03\x04\x05\x06\x07\x08\x09\x0A\x0B\x01\x00\x03'\
'\x01\x01\x01\x01\x01\x01\x01\x01\x01\x00\x00\x00'\
'\x00\x00\x00\x01\x02\x03\x04\x05\x06\x07\x08\x09'\
'\x0A\x0B\x10\x00\x02\x01\x03\x03\x02\x04\x03\x05'\
'\x05\x04\x04\x00\x00\x01\x7D\x01\x02\x03\x00\x04'\
@jbgo
jbgo / free-space-on-boot-disk.md
Last active April 19, 2023 20:47
Free up space on /boot disk (ubuntu)

Free disk space when /boot is full (Ubuntu)

TL;DR

dpkg -l linux-image*
uname -r
sudo apt-get remove linux-image-2.6.32-{21,37,38,39,40,41,42,43,44}-server
sudo apt-get autoremove
@catawbasam
catawbasam / julia_npp.xml
Created October 9, 2012 12:23
Julia language syntax highlighting for Notepad++. Goes in /users/{username}/AppData/Roaming/Notepad++.
<NotepadPlus>
<UserLang name="Julia" ext="jl">
<Settings>
<Global caseIgnored="no" />
<TreatAsSymbol comment="no" commentLine="yes" />
<Prefix words1="no" words2="no" words3="no" words4="no" />
</Settings>
<KeywordLists>
<Keywords name="Delimiters">&quot;00&quot;00</Keywords>
<Keywords name="Folder+">begin function type for while if</Keywords>