I want to pass the PASSED or FAILED value from a script. If the script is successfully triggered, then I want to pass the PASSED value. And if it is not successfully triggered, then I want to pass the FAILED value. And these PASSED or FAILED values needs to be stored in a variable in another script.
Asked
Active
Viewed 194 times
0
-
what did you try? – OznOg Feb 01 '22 at 18:47
-
1The standard, canonical way of signaling success vs failure is via the script's [exit code](https://stackoverflow.com/questions/36837149/get-exit-status-of-a-process-in-bash) – that other guy Feb 01 '22 at 18:50
-
If I run a script successfully, then I want to get the PASSED value to be passed and get stored in a variable inside a script. – ANISHA S Feb 01 '22 at 19:24
-
1This might help: [How do I set a variable to the output of a command in Bash?](https://stackoverflow.com/q/4651437/3776858) – Cyrus Feb 01 '22 at 19:59
-
How can we get the automated values like PASSED if the script runs successfully and FAILED if the script didn't runs successfully? – ANISHA S Feb 01 '22 at 20:18
-
1We encourage questioners to show what they have tried so far to solve the problem themselves. – Cyrus Feb 01 '22 at 20:42