Skip to content

Instantly share code, notes, and snippets.

View influx6's full-sized avatar
🎯
Focusing

Ewetumo Alexander influx6

🎯
Focusing
View GitHub Profile
@influx6
influx6 / jquery.qDefer.min.js
Created August 22, 2022 14:06 — forked from RonnyO/jquery.qDefer.min.js
Simply mimic the 'defer' attribute for inline scripts across all browsers (jQuery helper)
// http://bit.ly/qDefer
$(function(){$('script[type="text/javascript/defer"]').each(function(){$(this).clone().attr('type','').insertAfter(this)})});
@influx6
influx6 / libyjpagent_logfiles.txt
Created July 30, 2022 08:35 — forked from tjibbevanderlaan/libyjpagent_logfiles.txt
Log files of libyjpagent.so for YourKit profiler
#
# 12.0.6 ARMv5 sf
#
$ java -agentpath:/home/pi/yourkit/yjp-12.0.6/bin/linux-armv5-sf/libyjpagent.so
Error occurred during initialization of VM
Could not find agent library /home/pi/yourkit/yjp-12.0.6/bin/linux-armv5-sf/libyjpagent.so in absolute path, with error: /home/pi/yourkit/yjp-12.0.6/bin/linux-armv5-sf/libyjpagent.so: cannot open shared object file: No such file or directory
$ file /home/pi/yourkit/yjp-12.0.6/bin/linux-armv5-sf/libyjpagent.so
/home/pi/yourkit/yjp-12.0.6/bin/linux-armv5-sf/libyjpagent.so: ELF 32-bit LSB shared object, ARM, EABI5 version 1 (SYSV), dynamically linked, stripped
@influx6
influx6 / i3.config
Created July 11, 2022 11:42 — forked from Seanmatthews/i3.config
Config file for i3 window manager using apple keyboard
# This file has been auto-generated by i3-config-wizard(1).
# It will not be overwritten, so edit it as you like.
#
# Should you change your keyboard layout some time, delete
# this file and re-run i3-config-wizard(1).
#
# i3 config file (v4)
#
# Please see http://i3wm.org/docs/userguide.html for a complete reference!
@influx6
influx6 / alpine-virtual-desktop.sh
Created July 3, 2022 07:38 — forked from misterunknown/alpine-virtual-desktop.sh
Alpine Linux: Virtual Desktop installation
#!/bin/sh
#
# This script installs a virtual desktop using Xvfb, x11vnc, mate-desktop,
# mate-session-manager and Apache Guacamole. It runs on Alpine Linux Edge.
#
# See also:
# https://www.reddit.com/r/selfhosted/comments/b6k8go/poc_a_desktop_in_a_container_on_a_server/
# This is the user, under which the MATE desktop will run
# Notice: For several reasons this shouldn't be root
@influx6
influx6 / unbond.conf
Created April 27, 2022 04:46 — forked from MatthewVance/unbond.conf
Example of how to configure Unbound as a local forwarder using DNS-over-TLS to forward queries.
server:
###########################################################################
# BASIC SETTINGS
###########################################################################
# Time to live maximum for RRsets and messages in the cache. If the maximum
# kicks in, responses to clients still get decrementing TTLs based on the
# original (larger) values. When the internal TTL expires, the cache item
# has expired. Can be set lower to force the resolver to query for data
# often, and not trust (very large) TTL values.
cache-max-ttl: 86400
@influx6
influx6 / mount-devpts.yaml
Created April 17, 2022 00:29 — forked from Kickimanjaro/mount-devpts.yaml
I am having trouble making the mount command here idempotent. I think it should work the way I've written it, but it isn't.
---
# I want to verify that /dev/pts is mounted, and if not, mount it.
# Manually, this is simply: mount devpts /dev/pts -t devpts
# I want the resulting playbook to be idempotent and support the --check flag
- hosts: test
remote_user: testroot
tasks:
# The simple "command" way to do this.
@influx6
influx6 / k0s-source-attempt.nix
Created March 7, 2022 15:15
k0s source build attempt
{
pkgs ? import <nixpkgs> {}
}:
pkgs.stdenv.mkDerivation rec {
pname = "k0s-src";
version = "v1.23.3";
# src = builtins.fetchTarball {
# url = "https://github.com/k0sproject/k0s/archive/1a5afc71a0d4f6975e15b842aa1a934bc0986d7a.tar.gz";
@influx6
influx6 / configuration.nix
Created March 7, 2022 08:56 — forked from LnL7/configuration.nix
NixOS configuration overlays
{ config, pkgs, ... }:
let
# Import unstable channel.
# sudo nix-channel --add http://nixos.org/channels/nixpkgs-unstable nixpkgs-unstable
# sudo nix-channel --update nixpkgs-unstable
unstable = import <nixpkgs-unstable> {};
in
{
@influx6
influx6 / k0s-binary.nix
Created March 6, 2022 05:24
Create k0s binary builder in NIX
{
pkgs ? import (fetchTarball "https://github.com/NixOS/nixpkgs-channels/archive/a7ecde854aee5c4c7cd6177f54a99d2c1ff28a31.tar.gz") {}
}:
with pkgs;
{
k0s = stdenv.mkDerivation rec {
pname = "k0s";
version = "v1.23.3+k0s.1-amd64";
@influx6
influx6 / init.el
Created December 22, 2021 04:43 — forked from rksm/init.el
shackle
(defun rk/open-compilation-buffer (&optional buffer-or-name shackle-alist shackle-plist)
"Helper for selecting window for opening *compilation* buffers."
;; find existing compilation window left of the current window or left-most window
(let ((win (or (loop for win = (if win (window-left win) (get-buffer-window))
when (or (not (window-left win))
(string-prefix-p "*compilation" (buffer-name (window-buffer win))))
return win)
(get-buffer-window))))
;; if the window is dedicated to a non-compilation buffer, use the current one instead
(when (window-dedicated-p win)