Skip to content

Instantly share code, notes, and snippets.

View Ionizing's full-sized avatar
😵
Being defeated by DALAOs

Ionizing Ionizing

😵
Being defeated by DALAOs
  • Mars
View GitHub Profile

Using TikZ in Markup Languages

Introduction

So consider the tikz code at listing tikz-eg1 and figure Tikz-out1:

@mikeboiko
mikeboiko / tmux.conf
Last active March 23, 2024 07:32
Automatically update $DISPLAY for each tmux pane after attaching to session
set-hook -g client-attached 'run-shell /bin/update_display.sh'
@mag911
mag911 / Parallel_Tools_fix_for_Ubuntu_19.04.md
Last active July 1, 2024 18:24
Parallel Tools fix for Ubuntu 20.04, 19.04, 19.10, 18.04

Update 25 April 2020:

Many thanks to @KZL1992 @tomslominski @ptrofi @n-thumann for recent comments on their experiences with 20.04 and Parallels 13/14/15, especially the subsitution of the latest prl-tools-lin.iso for older Parallels to get it going.


First off, credit goes to github.com/rudolfratusinski for leading the way here.

https://gist.github.com/rudolfratusinski/a4d9e3caff11a4d9d81d2e84abc9afbf

@hjertnes
hjertnes / doom.txt
Created April 6, 2018 08:28
Doom Emacs Cheatsheet
SPC
SPC: find file
, switch buffer
. browse files
: MX
; EX
< switch buffer
` eval
u universal arg
x pop up scratch
\documentclass{article}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}
\draw[domain = 0:2.2, smooth, variable=\x, blue, samples = 221]
plot ({\x}, {sqrt(\x)})
node[anchor = west] {$ y = \sqrt x $};
\end{tikzpicture}
\end{document}
@FrancisMurillo
FrancisMurillo / meow.el
Created January 12, 2017 07:38
Literate Org Haskell
(defconst fn/haskell-file-extension ".hs"
"The de facto haskell file extension.")
(defun fn/add-haskell-file-extension (name)
"Add the extension of .hs to a file or buffer NAME."
(if (string/ends-with name fn/haskell-file-extension)
name (concat name fn/haskell-file-extension)))
(defvar fn/org-haskell-mode-hook nil
"Hook when buffer is haskellized.")
@jamesmacwhite
jamesmacwhite / Workarounds for Netflix and the blocking of IPv6 tunnels.md
Last active June 24, 2024 20:05
Prevent proxy/VPN streaming error messages from Netflix when using a Hurricane Electric IPv6 tunnel.

Workarounds for Netflix and the blocking of Hurricane Electric IPv6 tunnels

The dreaded "You seem to be using an unblocker or proxy." error message. Cool story bro.

This gist was essentially created out of my own rant about Netflix being hostile to IPv6 tunnel services since June 2016. You are welcome to read my opinion on the matter, this is the more technical side to the issue and how to combat it within your own network.

Since I wrote this, various GitHub users have contributed their thoughts and ideas which has been incorporated into this gist. Thank you to everyone who have contributed their own methods and implementations.

The problem

Netflix now treats IPv6 tunnel brokers (such as Hurricane Electric) as proxy servers. A while ago it became apparent to users and Netflix that somewhat by accident, IPv6 tunnel users were being served content outside of their geolocation because of the way Netflix was identifyi

@Liam0205
Liam0205 / example.tex
Last active April 15, 2024 05:30
widetext.sty
\documentclass[twocolumn]{article}
\usepackage{mwe}
\usepackage{widetext}
\begin{document}
\blindtext
\begin{widetext}
\[
E = mc^2.
\]
\end{widetext}
@gunjanpatel
gunjanpatel / revert-a-commit.md
Last active July 5, 2024 06:54
Git HowTo: revert a commit already pushed to a remote repository

Revert the full commit

Sometimes you may want to undo a whole commit with all changes. Instead of going through all the changes manually, you can simply tell git to revert a commit, which does not even have to be the last one. Reverting a commit means to create a new commit that undoes all changes that were made in the bad commit. Just like above, the bad commit remains there, but it no longer affects the the current master and any future commits on top of it.

git revert {commit_id}

About History Rewriting

Delete the last commit

Deleting the last commit is the easiest case. Let's say we have a remote origin with branch master that currently points to commit dd61ab32. We want to remove the top commit. Translated to git terminology, we want to force the master branch of the origin remote repository to the parent of dd61ab32:

@JonathonReinhart
JonathonReinhart / SConstruct
Last active January 6, 2024 06:42
mkdir -p implemented in C
env = Environment(
CCFLAGS = ['-Wall', '-Werror'],
)
env.Program('mkdir_p_test', ['mkdir_p.c', 'test.c'])