#!/bin/bash
#
# Source this file then call: p4st
#
# Create the .p4ignore file in your home directly with
# a single line entry like:
#
# \.pyc$|~$|\.tgz$|\.rpm$|*egg-info/*|\.pyo$
#
# This exludes any file ending in .pyc, .tgz, etc.
# Please send suggested improvements to oisin dot mulvihill at gmail dot com -thanks.
#
# Oisin Mulvihill, 2010-10-05, Released under BSD license.
#
function p4st() {
   EXCLUDES=`cat ~/.p4ignore`
   find . -type f -print0 | xargs -0 p4 fstat >/dev/null 2> /tmp/o && \
   cat /tmp/o | awk "{print \$1}" | grep -vE "$EXCLUDES"
}


