dotfiles

config files and scripts at HOME.
git clone git://git.ricketyspace.net/dotfiles.git
Log | Files | Refs

commit 95d638256492861705d336286d1aab5aba43b70f
parent 462fd39ce270ae0ef61e407f8a7b0c912fb4f9fb
Author: rsiddharth <s@ricketyspace.net>
Date:   Sun, 15 Apr 2018 15:03:41 +0000

.bin: Remove m-lo.

Diffstat:
.bin/m-lo | 44--------------------------------------------
1 file changed, 0 insertions(+), 44 deletions(-)

diff --git a/.bin/m-lo b/.bin/m-lo @@ -1,44 +0,0 @@ -#!/usr/bin/zsh -# -# Copyright (C) 2016 rsiddharth <s@ricketyspace.net> -# -# This program is free software: you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation, either version 3 of the -# License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program (see COPYING). If not, see -# <http://www.gnu.org/licenses/>. - -# mount file as a loop back device encrypted with cryptsetup -LO_NAME=$1 -LO_FILE_PATH=$2 - -[[ -z $LO_NAME ]] && - echo 'ERROR: Name for lo device not given!' && - exit 1 - - -[[ -z $LO_FILE_PATH || ! -f $LO_FILE_PATH ]] && - echo 'ERROR: File path got fucked!' && - exit 1 - -# get a unused loop device -LO_DEV=$(losetup -f) - -# map file to loop device -losetup $LO_DEV $LO_FILE_PATH - -# open loop back device with cryptsetup -cryptsetup open $LO_DEV $LO_NAME - -# mount it -mkdir -p $HOME/.mnt/$LO_NAME -mnt /dev/mapper/$LO_NAME $HOME/.mnt/$LO_NAME -