View Makefile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ifeq ($(MAKECMDGOALS),me a sandwich) | |
.PHONY: me a sandwich | |
me a: | |
@true | |
sandwich: | |
@if [[ $$(id -u) == "0" ]]; then \ | |
echo "Okay."; \ | |
else \ | |
echo "What? Make it yourself."; \ | |
false; \ |
View dmesg.out
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ 0.000000] random: get_random_bytes called from start_kernel+0x42/0x4b7 with crng_init=0 | |
[ 0.000000] Linux version 4.13.5-1-ARCH (builduser@tobias) (gcc version 7.2.0 (GCC)) #1 SMP PREEMPT Fri Oct 6 09:58:47 CEST 2017 | |
[ 0.000000] Command line: initrd=\initramfs-linux.img root=PARTUUID=4a405e71-b7a3-416e-8f15-a15debbfebfa rw | |
[ 0.000000] x86/fpu: Supporting XSAVE feature 0x001: 'x87 floating point registers' | |
[ 0.000000] x86/fpu: Supporting XSAVE feature 0x002: 'SSE registers' | |
[ 0.000000] x86/fpu: Supporting XSAVE feature 0x004: 'AVX registers' | |
[ 0.000000] x86/fpu: xstate_offset[2]: 576, xstate_sizes[2]: 256 | |
[ 0.000000] x86/fpu: Enabled xstate features 0x7, context size is 832 bytes, using 'standard' format. | |
[ 0.000000] e820: BIOS-provided physical RAM map: | |
[ 0.000000] BIOS-e820: [mem 0x0000000000000000-0x0000000000086fff] usable |
View alakajam.service
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Usage: | |
# - Put this content into /etc/systemd/system/alakajam.service | |
# - systemctl enable alakajam | |
# - systemctl start alakajam (or systemctl restart apache) | |
[Unit] | |
Description=Alakajam server | |
Requires=network.target | |
After=network.target |
View gist:681431d36450f5dc8f284d8e287c233b
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
typedef enum{ | |
response, | |
animation, | |
idle, | |
load | |
} phase_state; | |
struct AI_gov_info{ | |
phase_state phase; | |
phase_state prev_phase; |
View PhysicsTests.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Test | |
fun forceMovesObject() = physicsTest { | |
- " " | |
- " A " | |
- " " | |
A isPushed right | |
A shouldMove right |
View gist:566042fc1f8f64fe6957beeb2f4db960
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
+--+--+ + | |
| | | | | |
| | | | | |
+--+--+ + | |
| | | | | |
| | | | | |
+--+--+ + | |
View sorceress.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python3 | |
class Piece: | |
def __init__(self, mask): | |
self.up = bool(mask & 1) | |
self.down = bool(mask & 2) | |
self.left = bool(mask & 4) | |
self.right = bool(mask & 8) |
View sorceress.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python3 | |
class Piece: | |
def __init__(self, mask): | |
self.up = bool(mask & 1) | |
self.down = bool(mask & 2) | |
self.left = bool(mask & 4) | |
self.right = bool(mask & 8) |
View BaseSettings.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.frozenfractal; | |
import com.badlogic.gdx.Preferences; | |
import com.badlogic.gdx.utils.Json; | |
import java.util.Locale; | |
public class BaseSettings { | |
protected final Preferences prefs; |
View gist:96e8896f944a097785caa0394f3e17dc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
addListener(new InputListener() { | |
@Override | |
public boolean touchDown(InputEvent event, float x, float y, int pointer, int button) { | |
if (event.getTarget() == DefaultDialog.this && x < 0 || y < 0 || x > getWidth() || y > getHeight()) { | |
hide(); | |
return true; | |
} | |
return false; | |
} |