Skip to content

Instantly share code, notes, and snippets.

View ilg-ul's full-sized avatar

Liviu Ionescu ilg-ul

View GitHub Profile
@ilg-ul
ilg-ul / generic.mac.command
Last active September 10, 2017 20:35
macOS Finder command that calls the peer name.sh script from the same folder
#!/usr/bin/env bash
# -----------------------------------------------------------------------------
# Safety settings (see https://gist.github.com/ilg-ul/383869cbb01f61a51c4d).
if [[ ! -z ${DEBUG} ]]
then
set -x # Activate the expand mode if DEBUG is anything but empty.
fi
@ilg-ul
ilg-ul / script-cwd.sh
Last active September 10, 2017 20:32
Sequence to set the current folder.
# Include this part after the bash-init.sh part
script_path="$0"
if [[ "${script_path}" != /* ]]
then
# Make relative path absolute.
script_path="$(pwd)/$0"
fi
@ilg-ul
ilg-ul / short-license-mit-c-header-xpack.txt
Last active March 18, 2023 09:37
MIT license text for xPack files
/*
* This file is part of the xPack project (http://xpack.github.io).
* Copyright (c) 2022 Liviu Ionescu. All rights reserved.
*
* Permission to use, copy, modify, and/or distribute this software
* for any purpose is hereby granted, under the terms of the MIT license.
*
* If a copy of the license was not distributed with this file, it can
* be obtained from https://opensource.org/licenses/mit/.
*/