Skip to content

Instantly share code, notes, and snippets.

View braytac's full-sized avatar

braytac braytac

View GitHub Profile

Setup with TinyCore Linux (RAM only OS) on Raspberry Pi Zero W on Windows

These are the steps taken to setup piCore 14 on a Raspberry Pi with only Wi-Fi (no ethernet)
Newer version might work as well (or maybe even better), but have not been tested.

Set up piCore

  1. Download the piCore image
  2. Unpack the .zip file and write the .img file to the SD-Card (using Raspberry Pi Imager for example)
  3. Move the SD-Card to the Pi, plug in a keyboard and a screen, plug in the power source
  4. Execute backup shell command after the first boot to save generated unique SSH keys which will be used during next boots.
@probonopd
probonopd / Wayland.md
Last active January 12, 2026 21:47
Think twice about Wayland. It breaks everything!

Think twice before abandoning X11. Wayland breaks everything!

tl;dr: Wayland is not "the future", it is merely an incompatible alternative to the established standard with a different set of priorities and goals.

Wayland breaks everything! It is binary incompatible, provides no clear transition path with 1:1 replacements for everything in X11, and is even philosophically incompatible with X11. Hence, if you are interested in existing applications to "just work" without the need for adjustments, then you may be better off avoiding Wayland.

Wayland solves no issues I have but breaks almost everything I need. Even the most basic, most simple things (like xkill) - in this case with no obvious replacement. And usually it stays broken, because the Wayland folks mostly seem to care about Automotive, Gnome, maybe KDE - and alienating e

@Gnzlt
Gnzlt / gourcevideo.sh
Created March 6, 2019 13:25
Gource video export command
#!/bin/bash
gource \
-s .03 \
-1280x720 \
--auto-skip-seconds .1 \
--multi-sampling \
--stop-at-end \
--key \
--highlight-users \
@ojgarciab
ojgarciab / gist:32d085858d0a469f6842ee78b82a4666
Last active November 17, 2021 10:47 — forked from ealbinu/gist:3080619
Correo con PHP utilizando mail() codificado en UTF-8
<?php
$correo_destinatario = "";
$nombre_remitente = "";
$correo_remitente = "";
$asunto = "";
$mensaje = "";
/* Hacemos uso de mb_encode_mimeheader para codificar correctamente caracteres especiales */
$headers = 'From: "' . mb_encode_mimeheader($nombre_remitente) . '" <' . $correo_remitente . ">\r\n"
. 'Reply-To: ' . $correo_remitente . "\r\n"
@braytac
braytac / speed_boot
Last active September 26, 2019 14:32
Cosas que no suelo necesitar en el arranque de manjaro/arch
# EN GRUB: desactivar mitigaciones si no me interesan (+perf. Intel)
noibrs noibpb nopti nospectre_v2 nospectre_v1 l1tf=off nospec_store_bypass_disable no_stf_barrier mds=off mitigations=off
pacman -Rsc plymouth
pacman -Rsc mlocate
pacman -Rsc ntp
pacman -Rsc tlp
pacman -Rsc accountsservice
systemctl mask updatedb.service
@daymwk
daymwk / VideoStream.php
Last active September 26, 2019 14:32 — forked from ranacseruet/VideoStream.php
PHP VideoStream class for HTML5 video streaming
<?php
/**
* Description of VideoStream
*
* @author Rana
* Customized by Daym for remote videos
* @link http://codesamplez.com/programming/php-html5-video-streaming-tutorial
*/
class VideoStream
{
@joseluisq
joseluisq / mysql_query_log.md
Last active November 27, 2025 09:34
How to enable the MySQL/MariaDB general query logs

How to enable the MySQL/MariaDB general query logs

  1. Enter to MySQL/MariaDB server command-line tool (change root with your username and password):
mysql -u root -proot
  1. Set the general log file path:
SET GLOBAL general_log_file='/var/log/mysql/mycustom.log';
@micc83
micc83 / mysqldump.php
Created June 5, 2017 13:17
Simple PHP script to dump a MySql database
<?php
ini_set('display_errors', 1);
ini_set('display_startup_errors', 1);
error_reporting(E_ALL);
$database = 'db';
$user = 'user';
$pass = 'pass';
$host = 'localhost';
@tayvano
tayvano / gist:6e2d456a9897f55025e25035478a3a50
Created February 19, 2017 05:29
complete list of ffmpeg flags / commands
Originall From: Posted 2015-05-29 http://ubwg.net/b/full-list-of-ffmpeg-flags-and-options
This is the complete list that’s outputted by ffmpeg when running ffmpeg -h full.
usage: ffmpeg [options] [[infile options] -i infile]… {[outfile options] outfile}…
Getting help:
-h — print basic options
-h long — print more options
-h full — print all options (including all format and codec specific options, very long)
@bitsgalore
bitsgalore / loggingGUI.py
Created January 31, 2017 13:43
Minimal threaded GUI application with logging to both text file and ScrolledText widget
#! /usr/bin/env python
import time
import threading
import logging
try:
import tkinter as tk # Python 3.x
import tkinter.scrolledtext as ScrolledText
except ImportError:
import Tkinter as tk # Python 2.x
import ScrolledText