Bash Scripts

From In The Wings
Jump to navigation Jump to search

University of Florida High Performance Computing Center

Shell Tricks

To get the name of the script sans the path: Explanation

SCRIPT=${0##*/}

Tar Tricks

Copy files from one location to another using tar:

tar cf - . | (cd /somewhere ; tar xvfBp -)