Skip to content

Instantly share code, notes, and snippets.

View falloutphil's full-sized avatar

falloutphil

  • UK
View GitHub Profile
@jmickela
jmickela / gist:7c383c78af66a37a2446fe7eb733b157
Last active August 14, 2020 14:34
Trying to get PhpStorm to use git in Bash on Ubuntu on Windows (Windows Subsystem for Linux)
There's a problem that you run into right away: you can't put a command line command, with arguments,
into the path to git executable box.
So putting something like bash.exe -c "git %*" isn't going to work. I wrote a small shell script that
fixes this, for both 32-bit and 64-bit systems.
@echo off
If %PROCESSOR_ARCHITECTURE% == x86 (
"C:\Windows\sysnative\bash.exe" -c "git %*"
) Else (
@IgnoredAmbience
IgnoredAmbience / 99-noto-mono-color-emoji.conf
Last active March 27, 2024 03:39
Noto Emoji Color fontconfig for Konsole
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<!--
Noto Mono + Color Emoji Font Configuration.
Currently the only Terminal Emulator I'm aware that supports colour fonts is Konsole.
Usage:
0. Ensure that the Noto fonts are installed on your machine.
1. Install this file to ~/.config/fontconfig/conf.d/99-noto-mono-color-emoji.conf
@ipbastola
ipbastola / clean-up-boot-partition-ubuntu.md
Last active May 2, 2024 01:27
Safest way to clean up boot partition - Ubuntu 14.04LTS-x64, Ubuntu 16.04LTS-x64

Safest way to clean up boot partition - Ubuntu 14.04LTS-x64, Ubuntu 16.04LTS-x64

Reference

Case I: if /boot is not 100% full and apt is working

1. Check the current kernel version

$ uname -r 
@13Cubed
13Cubed / update_dnsbl.sh
Last active October 23, 2020 06:55
Download DNS adware and malware blacklists in BIND format and add them to a blacklist zone file. This is a modified version of the script from Paul's Security Weekly (http://wiki.securityweekly.com/wiki/index.php/Episode472).
#!/bin/bash
HOME=/var/named
ADLISTURL="https://pgl.yoyo.org/adservers/serverlist.php?hostformat=bindconfig;showintro=0;mimetype=plaintext"
MWLISTURL="http://mirror1.malwaredomains.com/files/spywaredomains.zones"
ADLISTFILE=/tmp/adlistfile
MWLISTFILE=/tmp/mwlistfile
# Download newest blacklists
curl -s -o $ADLISTFILE $ADLISTURL
@jdevoo
jdevoo / tg2p.st
Last active February 19, 2024 22:12
Not so Terse Guide to Pharo
"**************************************************************************
* Allowable characters: *
* - a-z *
* - A-Z *
* - 0-9 *
* - .+/\*~<>@%|&? *
* - blank, tab, cr, ff, lf *
* *
* Variables: *
* - variables must be declared before use *
@atweiden
atweiden / guix-notes.md
Created March 14, 2016 19:26
Guix notes

guix notes

overview

  • guix is pronounced geeks
  • guix wants linux-libre kernel for containerization
  • changing any input to a guix package definition results in a different hash on disk (different directory)
@tvieira
tvieira / myweechat.md
Created February 24, 2016 15:46 — forked from pascalpoitras/config.md
My always up-to-date WeeChat configuration (weechat-dev)

WeeChat Screenshot

Encrypted password in sec.conf

/secure passphrase <pass>
/secure set bncpass <pass>
/secure set relaypass <pass>
@jdkane3
jdkane3 / XslTransform.groovy
Created January 28, 2016 13:50
Simple groovy XSLT code
import javax.xml.transform.TransformerFactory
import javax.xml.transform.stream.StreamResult
import javax.xml.transform.stream.StreamSource
// Load xslt
def xslt= new File("MyTrasform.xsl").getText()
// Create transformer
def transformer = TransformerFactory.newInstance().newTransformer(new StreamSource(new StringReader(xslt)))
@meskarune
meskarune / weechat relay
Created September 14, 2015 18:05
weechat relay with ssl
mkdir ~/.weechat/ssl-cert
cd ~/.weechat/ssl-cert
openssl req -nodes -newkey rsa:2048 -keyout relay.pem -x509 -out relay.pem
In weechat:
/set relay.network.ssl_cert_key "/home/username/.weechat/ssl-cert/relay.pem"
/relay add ssl.weechat 9001
@gregsexton
gregsexton / gist:dd2d6c304d06fc3e6833
Created July 11, 2015 17:50
Company backend for completing eshell history
(defun company-eshell-history (command &optional arg &rest ignored)
(interactive (list 'interactive))
(cl-case command
(interactive (company-begin-backend 'company-eshell-history))
(prefix (and (eq major-mode 'eshell-mode)
(let ((word (company-grab-word)))
(save-excursion
(eshell-bol)
(and (looking-at-p (s-concat word "$")) word)))))
(candidates (remove-duplicates