Skip to content

Instantly share code, notes, and snippets.

View JerryPreissler's full-sized avatar

Jerry Preissler JerryPreissler

View GitHub Profile
@x42en
x42en / fsencrypt.sh
Created January 3, 2020 16:33
Bash script used to setup home directory encryption on Ubuntu 18.04 LTS using fscrypt
#!/bin/bash
# Script based on tutorial
# http://tlbdk.github.io/ubuntu/2018/10/22/fscrypt.html
if [[ "$EUID" -ne 0 ]]; then
echo "[!] Sorry this script need to be run as root."
exit 1
fi
@rob-murray
rob-murray / add_intellij_launcer
Last active October 21, 2024 14:30
Add Intellij launcher shortcut and icon for ubuntu
// create file:
sudo vim /usr/share/applications/intellij.desktop
// add the following
[Desktop Entry]
Version=13.0
Type=Application
Terminal=false
Icon[en_US]=/home/rob/.intellij-13/bin/idea.png
Name[en_US]=IntelliJ
@daveshah
daveshah / ExtensionMethodsTest.xtend
Created March 14, 2012 02:20
Example of Extension Methods on Strings in Xtend
import junit.framework.Assert
import org.junit.Test
class ExtensionMethodsTest {
@Test
def shouldBeNull() {
var String myTestString = null;
Assert::assertTrue(myTestString.isEmptyOrNull());
}
@mitchellh
mitchellh / gist:1277049
Created October 11, 2011 01:30
Configure Vagrant VM to use Host DNS for VPN
Vagrant::Config.run do |config|
# ...
config.vm.customize ["modifyvm", :id, "--natdnshostresolver1", "on"]
end