#!/bin/sh -e

if command -v gstat >/dev/null 2>&1; then
  gstat -c'%A %h %U %G %s c%.19z m%.19y a%.19x %n' "$@"
  exit 0
elif command -v stat >/dev/null 2>&1; then
  stat -c'%A %h %U %G %s c%.19z m%.19y a%.19x %n' "$@"
  exit 0
fi

while [ -n "$1" ]; do
  printf '%s' "ctime "
  ls -Fcld "$1"
  printf '%s' "mtime "
  ls -Ftld "$1"
  printf '%s' "atime "
  ls -Fuld "$1"
  shift
done
