This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# 12.5.25 | |
# Add borders to your JPEG images | |
# This script automatically recognizes orientation, and exports square images with white borders | |
# Arguments: | |
# --input <input folder> | |
# --output <output folder> | |
# --size <size of images> (optional) | |
# --border <border size> | |
import os |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This script adds or deletes a folder note containing a waypoint to every folder in the root | |
import os | |
# Define the relative path to the root folder from the script's location | |
RELATIVE_ROOT_PATH = "../../" | |
ROOT_FOLDER = os.path.abspath(os.path.join(os.path.dirname(__file__), RELATIVE_ROOT_PATH)) | |
def manage_folder_notes(action): | |
""" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# 27.1.25 | |
# This script allows you to easily change Johnny.Decimal folder numbers. It assumes a structure where areas are multiples of 10 (i.e., all folder elligible for changing start with a two-digit number) | |
# It also changes folder notes, if there are any | |
# NOTE: this currently only works for categories, not for areas (multiples of 10), since that would require a different renaming protocol | |
import os | |
import shutil | |
# Define the relative path to the root folder from the script's location | |
RELATIVE_ROOT_PATH = "../../" | |
ROOT_FOLDER = os.path.abspath(os.path.join(os.path.dirname(__file__), RELATIVE_ROOT_PATH)) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import os | |
import sys | |
def kill_node_on_port(port): | |
print(port) | |
print("Finding PID...") | |
lsof = os.popen(f'lsof -i tcp:{port}').read() | |
lsof_arr = lsof.split() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export NVM_DIR="$HOME/.nvm" | |
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm | |
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion | |
# Setting PATH for Python 3.6 | |
# The original version is saved in .bash_profile.pysave | |
PATH="/Library/Frameworks/Python.framework/Versions/3.6/bin:${PATH}" | |
export PATH | |
tab() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
" Vundle | |
set nocompatible " be iMproved, required | |
filetype off " required | |
set rtp+=~/.vim/bundle/Vundle.vim | |
call vundle#begin() | |
" let Vundle manage Vundle, required | |
Plugin 'VundleVim/Vundle.vim' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# 0 is too far from ` ;) | |
set -g base-index 1 | |
# Automatically set window title | |
set-window-option -g automatic-rename on | |
set-option -g set-titles on | |
#set -g default-terminal screen-256color | |
set -g status-keys vi | |
set -g history-limit 10000 |