Skip to content

Instantly share code, notes, and snippets.

@lukebrandonfarrell
lukebrandonfarrell / ExifData.swift
Created June 8, 2022 16:10
A Swift class for extracting exif data from URL, UIImage or Data types 🔭
//
// ExifData.swift
// Qeepsake
//
// Created by Luke Farrell on 26/05/2022.
//
import Foundation
import ImageIO
version: '3'
services:
traefik:
image: traefik:v2.0
container_name: traefik
restart: unless-stopped
security_opt:
- no-new-privileges:true
networks:
@dragonfire1119
dragonfire1119 / TTS HomeAssistant
Last active May 6, 2024 13:45
Home Assistant TTS to homepods
service: tts.cloud_say
data:
entity_id: media_player.christophers_homepod
cache: true
language: en-US
message: This is Christopher's HomePod Playing on Nabacasa
enabled: true
@willurd
willurd / web-servers.md
Last active May 6, 2024 13:43
Big list of http static server one-liners

Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.

Discussion on reddit.

Python 2.x

$ python -m SimpleHTTPServer 8000
@bryc
bryc / YamahaFM.md
Last active May 6, 2024 13:43
Collecting info on Yamaha FM soundchips
@eutobias
eutobias / index.lua
Last active May 6, 2024 13:42
Hammerspoon config for horizontal scroll on mouse middle button click
-- Bases in some codes i found on internet
-- but i din't find the links again
-- HANDLE SCROLLING
local scrollmultHorizontal = 2
local scrollmultVertical = 2 -- not used if use only horizontal scroll
local middleMouseEventButtonNumber = 2
hs.eventtap.new(
{"all"},
@FilipaBarros
FilipaBarros / Sysadmin_Interview_Questions.md
Last active May 6, 2024 13:42
Sysadmin Interview Questions

Top Questions for Sysadmin Interview:

Disclaimer: These questions and answers aren't at all mine. These were scavanged around in the web. I hope it helps.

Basic:
  1. What is Linux and also explain the basic components of Linux?

    Answer: Linux is the most commonly used operating system that is open source and free. For any computer, the operating system acts as the backbone, and it is most important software that is required for any computer.

@111000101
111000101 / xmapp-replace-mariadb-with-mysql.md
Created October 14, 2017 03:03 — forked from odan/xmapp-replacing-mariadb-with-mysql.md
XAMPP - Replace MariaDB with MySQL

XAMPP - Replace MariaDB with MySQL

Since XAMPP 5.5.30 and 5.6.14, XAMPP ships MariaDB instead of MySQL. MariaDB is not 100% compatible with MySQL and can be replaced with the "orginal" MySQL server.

Backup

  • Backup the old database into a sql dump file
  • Stop the MariaDB service
  • Rename the folder: c:\xampp\mysql to c:\xampp\mariadb
@chipx86
chipx86 / evil.py.c
Created September 19, 2021 03:39
Evil Python/C cross-language code generator
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#define __file__ __FILE__
#define import void*
#define def int
import codecs;
import os;
@TimoA200
TimoA200 / caddy-reload.sh
Created March 27, 2020 11:05
trigger a graceful reload in caddy docker container
#!/bin/sh
# This script graceful reloads the Caddy server inside the docker container. Graceful means that caddy reloads its configuration with zero downtime.
# Warning: Only works on Linux
caddy_container_id=$(docker ps | grep caddy | awk '{print $1;}')
docker exec $caddy_container_id caddy reload --config /etc/caddy/Caddyfile --adapter caddyfile