Skip to content

Instantly share code, notes, and snippets.

@mallendeo
mallendeo / .initramfs_profile
Last active April 10, 2023 02:42 — forked from tavianator/remote
Remote unlock encrypted LUKS disk using Tailscale on Archlinux (mkinitcpio hook)
## /home/YOUR_HOME_DIRECTORY/.initramfs_profile
## ssh root@TAILSCALE_IP
## ~ # unlock
alias unlock="systemctl start cryptsetup.target"
@mallendeo
mallendeo / README.md
Last active November 16, 2022 17:29
Mount encrypted ZFS on Ubuntu
sudo apt install zfsutils-linux
export ZFS_DISK=usb-Realtek_RTL_012345679039-0\:0-part2
export ZFS_POOL=backup
export ZFS_DATASET=some_dataset

sudo zpool import -d $ZFS_DISK $ZFS_POOL
@mallendeo
mallendeo / README.md
Last active August 21, 2023 03:32
Run Synergy / Barrier on Ubuntu 22.04

Run Synergy on Ubuntu 22.04

Disable Wayland since it's not supported

On /etc/gdm3/custom.conf, uncomment WaylandEnable=false

Also, add this line on the [daemon] section:

DefaultSession=gnome-xorg.desktop

{
if (!_) {
const res = await fetch('https://cdn.jsdelivr.net/npm/lodash')
const text = await res.text()
eval(text) // load lodash
}
window.unmatchedMovies = new Set([])
const checkMovies = () => {
@mallendeo
mallendeo / README.md
Last active April 8, 2022 16:40
Home Assistant remote control script template

Usage:

TV example:

- service: script.lg_tv_remote
  data:
    cmd: power
@mallendeo
mallendeo / heiman_HS1RCEF_blueprint.yaml
Created March 14, 2022 21:28
Heiman HS1RC-EF Home Assistant blueprint (Zigbee2MQTT)
blueprint:
name: Heiman 4 button remote [Zigbee2MQTT]
description: Automate Heiman remote via Zigbee2MQTT.
domain: automation
input:
action_sensor:
name: Action Sensor
description: Zigbee2mqtt action sensor
selector:
entity:
@mallendeo
mallendeo / .devcontainer.json
Last active October 26, 2021 16:47
Node development environment using Visual Studio Code dev containers
{
"name": "vscode-app-dev",
"build": {
"dockerfile": "Dockerfile",
"args": {
"VARIANT": "16-bullseye"
}
},
"forwardPorts": [
3000
@mallendeo
mallendeo / .zshrc
Last active November 14, 2023 18:48
Debian server init
source $HOME/.antigen.zsh
# Load the oh-my-zsh's library.
antigen use oh-my-zsh
antigen bundle git
antigen bundle bash
antigen bundle command-not-found
antigen bundle zsh-users/zsh-syntax-highlighting
@mallendeo
mallendeo / hosts.txt
Last active November 2, 2021 16:12
Personal DNS block list
# LG TV update
0.0.0.0 su.lge.com
0.0.0.0 snu.lge.com
0.0.0.0 snu.lge.com.usgcac.cdnetworks.net
0.0.0.0 snu.lge.com.cdngc.net
@mallendeo
mallendeo / index.mjs
Created October 18, 2021 19:54
Remote control UI maker script (tasmota-ir & lovelace)
// npm i yaml
import YAML from 'yaml'
const codes = {
up: '0x20DF02FD',
down: '0x20DF827D',
left: '0x20DFE01F',
right: '0x20DF609F',
config: '0x20DFC23D',