#!/bin/sh
#
# Copyright (c) 2008 by Bruce Blinn
#
# NAME
#	pcommand - print the command line executed by a process
#
# SYNOPSIS
#	pcommand processID
#
# DESCRIPTION
#	Print the command line (command name and parameters) being
#	executed by the specified process.
#
# RETURN VALUE
#	0	Successful completion.
#	1	Error - see the message written to standard error.
#
####################################################################
CMDNAME=$(basename $0)
USAGE="Usage: $CMDNAME processID"
export UNIX95=		# For POSIX version of ps command on HP-UX.

if [ $# -ne 1 ]; then
	echo "$USAGE" 1>&2
	exit 1
fi

ps -p $1 -o "args="
