summaryrefslogtreecommitdiff
path: root/contrib
diff options
context:
space:
mode:
Diffstat (limited to 'contrib')
-rw-r--r--contrib/osx-ramdisk.patch36
1 files changed, 36 insertions, 0 deletions
diff --git a/contrib/osx-ramdisk.patch b/contrib/osx-ramdisk.patch
new file mode 100644
index 0000000..b1738b0
--- /dev/null
+++ b/contrib/osx-ramdisk.patch
@@ -0,0 +1,36 @@
+From 9f640573906bf7f98133006d09cb2bddca5ec5ae Mon Sep 17 00:00:00 2001
+From: "Jason A. Donenfeld" <Jason@zx2c4.com>
+Date: Wed, 12 Sep 2012 21:08:56 +0200
+Subject: [PATCH] Use ramdisk for volatile storage in OSX.
+
+---
+ src/password-store.sh | 13 +++++++++++++
+ 1 file changed, 13 insertions(+)
+
+diff --git a/src/password-store.sh b/src/password-store.sh
+index c736d7b..33a0e97 100755
+--- a/src/password-store.sh
++++ b/src/password-store.sh
+@@ -239,6 +239,19 @@ case "$command" in
+
+ if [[ -d /dev/shm && -w /dev/shm && -x /dev/shm ]]; then
+ tmp_dir="$(TMPDIR=/dev/shm mktemp -t $template -d)"
++ elif [[ $(uname) = "Darwin" ]]; then
++ cleanup_tmp() {
++ [[ -d $tmp_dir ]] || return
++ rm -rf "$tmp_file" "$tmp_dir" 2>/dev/null
++ umount "$tmp_dir"
++ diskutil quiet eject "$ramdisk_dev"
++ rmdir "$tmp_dir"
++ }
++ trap cleanup_tmp INT TERM EXIT
++ tmp_dir="$(mktemp -t $template -d)"
++ ramdisk_dev="$(hdid -drivekey system-image=yes -nomount 'ram://32768' | cut -d ' ' -f 1)" # 32768 sectors = 16 mb
++ newfs_hfs -M 700 "$ramdisk_dev" &>/dev/null || exit 1
++ mount -t hfs -o noatime -o nobrowse "$ramdisk_dev" "$tmp_dir" || exit 1
+ else
+ prompt=$(echo "Your system does not have /dev/shm, which means that it may"
+ echo "be difficult to entirely erase the temporary non-encrypted"
+--
+1.7.12
+
7Remove urxvt wgetpaste extensionRené 'Necoro' Neumann2-30/+1 2020-02-17[i3] Wifi: Include frequenceRené 'Necoro' Neumann1-1/+1 2020-02-17Put ssh-agent into the i3 environment.René 'Necoro' Neumann1-0/+1 2020-02-17Update cci: stgit now uses python3René 'Necoro' Neumann1-1/+1 2020-02-17Revert "Local Changes"René 'Necoro' Neumann2-5/+3 2020-02-17Update vundleRené 'Necoro' Neumann1-0/+0 2020-02-17Enable secondary screen in urxvtRené 'Necoro' Neumann1-0/+1 2020-02-17Local ChangesRené 'Necoro' Neumann2-3/+5 2018-06-10[i3] Replace icons by font awesomeRené 'Necoro' Neumann24-149/+13 2018-06-10[i3] Remove obsolete pidgin stuffRené 'Necoro' Neumann2-36/+0 2018-06-10[zsh] Remove obsolete isabelle functionsRené 'Necoro' Neumann2-112/+0 2018-06-10Misc changesRené 'Necoro' Neumann3-0/+7 2018-06-10[git] Update email addressRené 'Necoro' Neumann1-1/+1 2018-06-10Enhance cci scriptRené 'Necoro' Neumann1-15/+12 2017-11-18Some windows setupRené 'Necoro' Neumann2-1/+6 2017-10-08[zsh] Use zcalc instead of bcRené 'Necoro' Neumann1-5/+4 2017-10-08[zsh] CalculatorRené 'Necoro' Neumann1-0/+8 2017-10-08Some vim changes.René 'Necoro' Neumann4-28/+17 2017-10-08Delete old stuff.René 'Necoro' Neumann5-71/+1