Skip to content

Instantly share code, notes, and snippets.

hacking sophia

Philipp Piwo thepiwo

hacking sophia
View GitHub Profile
hkoba / sched-reboot.service
Last active Sep 29, 2021
systemd service and timer for scheduled reboot.
View sched-reboot.service
Description=Scheduled Reboot
ExecStart=/usr/bin/systemctl --force reboot
himalay /
Created Feb 26, 2017
Color emoji on Arch Linux.
# create folders if does not exist
mkdir -p ~/.fonts
mkdir -p ~/.config/fontconfig/
# download noto color emoji font from
# extract NotoColorEmoji.ttf file into ~/.fonts/
# create font config file
cat << 'EOF' > ~/.config/fontconfig/fonts.conf
<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE fontconfig SYSTEM "fonts.dtd">
alekseykulikov /
Last active Aug 8, 2020
Principles we use to write CSS for modern browsers

Recently CSS has got a lot of negativity. But I would like to defend it and show, that with good naming convention CSS works pretty well.

My 3 developers team has just developed React.js application with 7668 lines of CSS (and just 2 !important). During one year of development we had 0 issues with CSS. No refactoring typos, no style leaks, no performance problems, possibly, it is the most stable part of our application.

Here are main principles we use to write CSS for modern (IE11+) browsers:

lummie / gist:732b8cb0b478966b91a7f9244c7aeac7
Last active Apr 23, 2020
Change exif timezone with exiftool -8 hour
View gist:732b8cb0b478966b91a7f9244c7aeac7
// I'm forever forgetting to adjust the time zone on my camera when taking pictures on vacation
// this uses the linux exiftool to adjust the timezone -8 hours for all images in a directory
exiftool "-DateTimeOriginal-=0:0:0 8:0:0" *
set -e
[ $# -eq 0 ] && { echo "Usage: sudo $0 \$(/usr/libexec/java_home -v '1.8*')" ; exit 1; }
andreparames /
Last active Apr 9, 2016
Store strings on the very useful
import requests
def frombits(s):
bts = (int(s[i:i+8], 2) for i in range(0, len(s), 8))
return str(bytearray(bts))
def tobits(s):
return ''.join(bin(b)[2:].zfill(8) for b in bytearray(s))
def storebit(bit):
w0rldart /
Last active Jan 31, 2018
Installing MongoDB on Ubuntu 15.04
## Bash install script for mongo 3.2 for Ubuntu 15.04, because of
## the replacement of upstart with systemd
## - AUTHOR: Alexandru Budurovici <>
## - VERSION: 1.0
celoyd /
Last active Jul 12, 2021
A way to make Himawari-8 animations

Himawari-8 animation tutorial

Here’s how to make animations like this one. It requires intermediate Unix command-line knowledge, to install some tools and to debug if they don’t work. You’ll need these utilities:

  • curl (or you can translate to wget)
  • convert and montage, part of ImageMagick
  • ffmpeg, plus whatever codecs
  • parallel, for iteration that’s nicer than shell for loops or xargs
  • run everything in zsh for leading 0s in numerical ranges to work
atcuno / gist:3425484ac5cce5298932
Last active Sep 14, 2021
HowTo: Privacy & Security Conscious Browsing
View gist:3425484ac5cce5298932

The purpose of this document is to make recommendations on how to browse in a privacy and security conscious manner. This information is compiled from a number of sources, which are referenced throughout the document, as well as my own experiences with the described technologies.

I welcome contributions and comments on the information contained. Please see the How to Contribute section for information on contributing your own knowledge.

Table of Contents