Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Function or Alias - Does it matter?



Is there any practical difference between making an alias or a
function if they do the same thing?

For example, these are (as far as I know) functionally identical:

         function timestamp_r { strftime "%Y/%m/%d at %-I:%M:%S %p"
"$EPOCHSECONDS" }

         alias timestamp_r='strftime "%Y/%m/%d at %-I:%M:%S %p" "$EPOCHSECONDS"'

Is there any reason to prefer one or the other?

Tj



Messages sorted by: Reverse Date, Date, Thread, Author