Function return string in a shell script - Programming On Unix

Users browsing this thread: 1 Guest(s)
venam
Administrators
Surprisingly, while quite old, according to "Google Console" this thread is very popular.
It is about returning values from shell functions, or from running a third party program and storing the result. It touches how to not pollute stdout which is going to be the result of the function. The limitation of only manipulating text.
It shows how shell scripting, when staying POSIX compliant, can be quite a hassle.

Do you use a technique that wasn't mentioned in this thread? Or a comment about shell scripting limitation regarding standard inputs and outputs.


Messages In This Thread
RE: Function return string in a shell script - by venam - 01-09-2020, 06:04 AM