#!/bin/bash

echo "test" > foo.txt
if [ ! -L foo.txt ]; then
  echo foo.txt is not symbolic link
else
  echo foo.txt is symbolic link
fi

ln -s foo.txt bar.txt

if [ -L bar.txt ]; then
  echo bar.txt is symbolic link
else
  echo foo.txt is not symbolic link
fi

rm bar.txt foo.txt
  
