Skip to content

Instantly share code, notes, and snippets.

@p3t3r67x0
p3t3r67x0 / tensorflow2.3_build_error.md
Last active September 13, 2020 07:05
A short story how I did build Tensorflow 2.3 from source on Ubuntu 20.4.1 LTS with CUDA 11.0.207

Building Tensorflow 2.3 from source on Ubuntu 20.4.1 LTS

GPU

ASUS ROG Strix GeForce GTX 1070 Ti 8GB

System

@p3t3r67x0
p3t3r67x0 / terminator.config
Created August 28, 2020 05:10
My Terminator config
[global_config]
window_state = fullscreen
borderless = True
extra_styling = False
title_transmit_fg_color = "#729fcf"
title_transmit_bg_color = "#002b36"
title_receive_fg_color = "#eeeeec"
title_inactive_bg_color = "#002b36"
[keybindings]
[profiles]

convert_svg_matrix

def delta_transform_point(matrix, point):
    dx = point['x'] * matrix['a'] + point['y'] * matrix['c'] + 0
    dy = point['x'] * matrix['b'] + point['y'] * matrix['d'] + 0

    return {'x': dx, 'y': dy}
@p3t3r67x0
p3t3r67x0 / convert_truetype.md
Last active November 26, 2023 16:54
Create a svg from truetype font with freetype and svgpathtools in python

Create a svg from truetype font in python

I am trying to create a svg file from a truetype font with freetype-py and svgpathtools. I have a working python code which generates the svg file but unfortunately there are some corners and edges where instead should be smooth curves. Here in this example I try to render an special char which does not look good at all.

Question

What do I need to change in order to get curve symbols redered correctly?

Prerequisites

@p3t3r67x0
p3t3r67x0 / rejson-for-ubuntu.md
Created December 24, 2019 00:25 — forked from lmj0011/rejson-for-ubuntu.md
Building and Loading the ReJSON Module on Linux Ubuntu 16.04 for Redis

make sure you have at least redis v4.0+

redis-server --version

redis-cli --version

install the build-essential package

apt-get install build-essential

@p3t3r67x0
p3t3r67x0 / iptables.sh
Created December 14, 2019 06:33 — forked from thomasfr/iptables.sh
iptable rules to allow outgoing DNS lookups, outgoing icmp (ping) requests, outgoing connections to configured package servers, outgoing connections to all ips on port 22, all incoming connections to port 22, 80 and 443 and everything on localhost
#!/bin/bash
IPT="/sbin/iptables"
# Server IP
SERVER_IP="$(ip addr show eth0 | grep 'inet ' | cut -f2 | awk '{ print $2}')"
# Your DNS servers you use: cat /etc/resolv.conf
DNS_SERVER="8.8.4.4 8.8.8.8"
# Allow connections to this package servers
@p3t3r67x0
p3t3r67x0 / ssh_banner.md
Created December 10, 2019 01:58
This is a list I extracted from https://purplepee.co/dns

LibreELEC

Set wifi password by ssh connection

connmanctl
agent on
scan wifi
services
connect wifi_blah <= tab autocomplete works here
@p3t3r67x0
p3t3r67x0 / README.md
Last active March 20, 2019 18:02
Simple programm to encrypt or decrypt a vigenere cipher text. See README.md how to run this programm.

vigenere.py

usage: vigenere.py [-h] [-d, --decrypt] [-e, --encrypt] -k, --key KEY
                   [-i, --in [INPUT]] [-o, --out [OUTPUT]]

Encrypt or decrypt a vigenere cipher text

optional arguments:
@p3t3r67x0
p3t3r67x0 / sshd_deattack_exploit.md
Created March 2, 2019 02:07
SSHD deattack exploit. By Dvorak with Code from teso (http://www.team-teso.net)

SSHD deattack exploit

First you need to download it from here. Then you must extract it.

tar zxvf 349.tgz
cd ssh