mkdir isobuild && cd isobuild
sudo dnf install rpm-ostree lorax -y
git clone -b f33 https://pagure.io/workstation-ostree-config
git clone -b f33 https://pagure.io/fedora-lorax-templates.git
mkdir repo
ostree init --repo=repo
rpm-ostree compose tree --repo=$(pwd)/repo \
$(pwd)/workstation-ostree-config/fedora-silverblue.yaml
#!/usr/bin/env bash | |
# This is a script to download patch/fix the setup and config so you can use | |
# chrome-remote-desktop via https://remotedesktop.google.com/headless | |
# | |
# crd = chrome-remote-desktop where convenient (like binary names) | |
# | |
# There are a few issues that need fixing: | |
# 1. the oauth onboard via the above link requires Google's binaries (i.e. the ones in the .deb) | |
# 2. paths don't match - fedora installs in /usr/lib64/chrome-remote-desktop instead of /opt/google/chrome-remote-desktop |
I think I’ve figured out most parts of the cubical type theory papers; I’m going to take a shot to explain it informally in the format of Q&As. I prefer using syntax or terminologies that fit better rather than the more standard ones.
Q: What is cubical type theory?
A: It’s a type theory giving homotopy type theory its computational meaning.
Q: What is homotopy type theory then?
A: It’s traditional type theory (which refers to Martin-Löf type theory in this Q&A) augmented with higher inductive types and the univalence axiom.
#!/bin/bash | |
# Give the usual warning. | |
clear; | |
echo "[INFO] Automated Android root script started.\n\n[WARN] Exploit requires sdk module \"NDK\".\nFor more information, visit the installation guide @ https://goo.gl/E2nmLF\n[INFO] Press Ctrl+C to stop the script if you need to install the NDK module. Waiting 10 seconds..."; | |
sleep 10; | |
clear; | |
# Download and extract exploit files. | |
echo "[INFO] Downloading exploit files from GitHub..."; |
It's now here, in The Programmer's Compendium. The content is the same as before, but being part of the compendium means that it's actively maintained.
import binascii | |
import struct | |
class Punk(object): | |
_END_CHUNK_TYPE = 'IEND' | |
_PUNK_CHUNK_TYPE = 'puNk' | |
_MAX_BYTES = 2147483647 | |
_chunks = dict() |
There is sometimes a situation in which one needs to get the relative offset of a structure field, common examples of this include serialization frameworks which aid to serialize objects, vertex attributes for rendering (D3D, GL.), etc.
The most common technique for getting this information is through the offsetof
macro defined in stddef.h
. Unfortunately using the macro in C++ comes with a
new set of restrictions that prevent some (subjectively valid) uses of it.
eval$x=%q(eval(%w(s="]k<<k7@k9 | |
9k@,7&]-7k.@61y?c<c@9k.?isu:,e | |
y<?2k_i]61 o@3i>k@_]9_g36o1@ | |
i4k?w/r?1o ?i=i?yoy65kok95 | |
qw6?ci_:<ye g'=ok?;g'n/g?o | |
i2?.(]{8{)- u8c@4>]u8c-u@ | |
gq7?@4]0;g? ;|g|;]*qkbk0e | |
g,_@eqqeqqg @>'] a<<0e4e5 | |
oi{25>|>?@ c8 &7*3986 | |
@a;;0+>*@2 _i m{@{+_( |
macro for(expr) | |
{{raise "invalid syntax. use for e in c." unless expr.args.first.name.stringify == "in"}} | |
{{expr.args.first.args.first}}.each do |{{expr.name.id}}| | |
{{expr.args.first.block.body}} | |
end | |
end | |
for e in 1..5 do | |
puts e | |
end |