#! /usr/bin/env haze script #! haze shell pgsql s3 echo 'test' | occ file:put '-' /admin/files/test.txt FILE_ID=$(occ info:file /admin/files/test.txt | grep fileid: | grep -oE '[0-9]+') OBJECT_CONTENTS=$(occ file:object:get urn:oid:$FILE_ID -) if [ "$OBJECT_CONTENTS" == 'test' ]; then echo "object contains expected contents" else echo "object does not contains expected contents!" fi