install updates
This commit is contained in:
@@ -0,0 +1,38 @@
|
|||||||
|
# Processing Scripts
|
||||||
|
|
||||||
|
A collection of personal command-line utilities.
|
||||||
|
Mostly for processing, organizing, and managing (media) files.
|
||||||
|
While created for my own use, they are shared here in case others find them useful.
|
||||||
|
|
||||||
|
## Scripts
|
||||||
|
|
||||||
|
- **av1**: (DEPRECATED - use vcmp instead) Recursively compresses video files to AV1/MP4 format with reduced quality/size
|
||||||
|
- **indeel**: File organization tool that watches a directory and sorts incoming files based on content hashes
|
||||||
|
- **mover**: Monitors a source directory and moves files with specified extensions to a destination directory
|
||||||
|
- **pushover**: Sends push notifications via Pushover API
|
||||||
|
- **vc**: Video converter using ffmpeg and youtube-dl for local files or YouTube URLs
|
||||||
|
- **vcmp**: Advanced video compression utility with progress tracking and logging
|
||||||
|
|
||||||
|
## Installation
|
||||||
|
|
||||||
|
1. Configure environment variables:
|
||||||
|
```bash
|
||||||
|
cp example.env .env
|
||||||
|
```
|
||||||
|
|
||||||
|
2. Add the scripts to your PATH and load environment variables by adding this line to your shell's RC file (~/.bashrc, ~/.zshrc, etc.):
|
||||||
|
```bash
|
||||||
|
source /path/to/repo/scripts/install.sh
|
||||||
|
```
|
||||||
|
|
||||||
|
## Requirements
|
||||||
|
|
||||||
|
- ffmpeg
|
||||||
|
- imagemagick
|
||||||
|
- youtube-dl
|
||||||
|
- pushover API tokens
|
||||||
|
- Whatever the relevant script errors about
|
||||||
|
|
||||||
|
## Usage
|
||||||
|
|
||||||
|
Each script includes help documentation accessible via `-h` or `--help` flag. See individual script headers for detailed usage instructions.
|
||||||
+11
-2
@@ -1,13 +1,22 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# This script adds the bin directory to PATH
|
# This script adds the bin directory to PATH and loads environment variables from .env
|
||||||
#
|
#
|
||||||
# Usage:
|
# Usage:
|
||||||
# Source this script in your rc:
|
# Source this script in your rc:
|
||||||
# source /path/to/here/install.sh
|
# source /path/to/here/install.sh
|
||||||
|
|
||||||
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
SCRIPT_DIR="$(dirname "$(realpath "$0")")"
|
||||||
BIN_DIR="$SCRIPT_DIR/bin"
|
BIN_DIR="$SCRIPT_DIR/bin"
|
||||||
|
ENV_FILE="$SCRIPT_DIR/.env"
|
||||||
|
|
||||||
if [ -d "$BIN_DIR" ] && [[ ":$PATH:" != *":$BIN_DIR:"* ]]; then
|
if [ -d "$BIN_DIR" ] && [[ ":$PATH:" != *":$BIN_DIR:"* ]]; then
|
||||||
export PATH="$PATH:$BIN_DIR"
|
export PATH="$PATH:$BIN_DIR"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [ -f "$ENV_FILE" ]; then
|
||||||
|
while IFS='=' read -r key value; do
|
||||||
|
if [ -n "$key" ] && [ -n "$value" ] && [[ ! "$key" =~ ^# ]]; then
|
||||||
|
export "$key=$value"
|
||||||
|
fi
|
||||||
|
done < "$ENV_FILE"
|
||||||
|
fi
|
||||||
|
|||||||
Reference in New Issue
Block a user