Skip to content

Instantly share code, notes, and snippets.

View jcf's full-sized avatar
❤️

James Conroy-Finn jcf

❤️
View GitHub Profile
@jcf
jcf / AAA-README.md
Created August 15, 2021 18:02 — forked from jackrusher/AAA-README.md
Clojure + FUSE

Meld

A minimal example of creating a (mostly) working FUSE filesystem using Clojure. NOTE: I have only tested this with OSX, and it assumes you have already installed libfuse.

Trying it out

Create an empty directory at /tmp/meld to serve as your mount point, put these files in a directory called meld, then:

= Arch Linux step-by-step installation =
= http://blog.fabio.mancinelli.me/2012/12/28/Arch_Linux_on_BTRFS.html =
== Boot the installation CD ==
== Create partition ==
cfdisk /dev/sda
* Create a partition with code 8300 (Linux)
@jcf
jcf / gist:141cba67d8df2457aac7c68d80272cc0
Created December 22, 2016 14:26 — forked from mfilippov/gist:10009192
Netty multicast demo.
package me.filippov.netty_demo;
import io.netty.bootstrap.Bootstrap;
import io.netty.bootstrap.ChannelFactory;
import io.netty.channel.*;
import io.netty.channel.nio.NioEventLoopGroup;
import io.netty.channel.socket.DatagramPacket;
import io.netty.channel.socket.InternetProtocolFamily;
import io.netty.channel.socket.nio.NioDatagramChannel;
@jcf
jcf / VAAPI-hwaccel-encode-Linux-Ffmpeg&Libav-setup.md
Created November 6, 2016 19:53 — forked from Brainiarc7/VAAPI-hwaccel-encode-Linux-Ffmpeg&Libav-setup.md
This gist contains instructions on setting up FFmpeg and Libav to use VAAPI-based hardware accelerated encoding (on supported platforms) for H.264 (and H.265 on supported hardware) video formats.

Using VAAPI's hardware accelerated video encoding on Linux with Intel's hardware on FFmpeg and libav

Hello, brethren :-)

As it turns out, the current version of FFmpeg (version 3.1 released earlier today) and libav (master branch) supports full H.264 and HEVC encode in VAAPI on supported hardware that works reliably well to be termed "production-ready".

@jcf
jcf / duckduckgo.el
Created November 1, 2016 19:29
Function to search from Emacs using DuckDuckGo.
; DuckDuckGo
(defun duckduckgo-search (text)
"Search DuckDuckGo from Emacs."
(interactive "sSearch: ")
(browse-url
(concat "https://duckduckgo.com/?q="
(replace-regexp-in-string " " "+" text))))
@jcf
jcf / uefisetup.sh
Created October 1, 2016 15:32 — forked from Apsu/uefisetup.sh
Arch Linux UEFI Setup
# **************** READ THIS FIRST ******************
#
# This is not a script for you to run. I repeat, do not download and run this!
#
# This is only a guide to show the required steps for successful UEFI + GRUB2 installation
# Many of the choices are examples or assumptions; don't blindly type shit into your machine
# until/unless you at least read the comments around each command
#
# These steps assume you've booted in UEFI mode by preparing your USB stick per these instructions:
# https://wiki.archlinux.org/index.php/UEFI#Archiso
@jcf
jcf / Install
Created October 1, 2016 15:32 — forked from jasonwryan/Install
Arch Linux installation procedure for LVM on LUKS: UEFI EFISTUB boot with gumiboot on a Samsung Series 9 laptop.
# Notes for installing on Samsung Series 9
# UEFI boot: LVM on LUKS
#
# See the full blog post:
# http://jasonwryan.com/blog/2013/01/25/uefi/
# check you are booted in uefi
modprobe efivars
ls /sys/firmware/efi/vars
@jcf
jcf / checkpoint.sh
Last active March 4, 2024 18:38 — forked from bubenkoff/checkpoint.sh
Endpoint Security VPN FULL start/stop script for Mac OS X
#!/bin/bash
# Toggle Checkpoint VPN firewall and VPN client
#
# http://git.io/vWAPU
set -e
APP='/Applications/Endpoint Security VPN.app'
KEXT='/System/Library/Extensions/cpfw.kext'
PLIST='/Library/LaunchDaemons/com.checkpoint.epc.service.plist'
SERVICE='com.checkpoint.epc.service'
(require '[datomic.api :as d])
(def uri "datomic:mem://test")
(d/create-database uri)
(def conn (d/connect uri))
(d/transact conn [{:db/id #db/id [:db.part/db]
:db/ident :enum/ns
:db/valueType :db.type/string
:db/cardinality :db.cardinality/one
:db/doc "Enum's namespace. Help enforce fk constraints on :db.type/ref enum references"
@jcf
jcf / log.txt
Last active October 11, 2015 13:28 — forked from mislav/log.txt
Analyze shell history; zsh edition + alias expansion
686 git commit -v
365 git commit -av
169 git checkout -b
160 git push -u
111 nocorrect mkdir -p
102 nocorrect rm -rf
89 nocorrect rm -r
88 git push -f
79 git branch -D
71 git push origin