Your English is fine.
The issue is that you're sending this a background process with the ampersand ("&"). The nohup just tells it not to hang up when the terminal goes away so doesn't really have anything to do with backgrounding it.
By definition any process started with "&" will give the shell that started it a return code of 0 (success) because the "&" has told the starting shell not to wait for return status.
What you could do is have a another script that executes test.sh and then records its return code. Within that script you would NOT background test.sh. However you WOULD background that new script.
It would be simpler though to just incorporate whatever action you want to take within test.sh itself at the point it is doing its return code. If you just want to know what it did you can just have it output the return code to a file then check that file manually. You could even have it redirect its output to your live terminal but if you're doing that you shouldn't do "nohup" as it will have issues if it tries to output to the terminal and you've logged out and closed the terminal.
Last edited by MensaWater; 10-12-2005 at 01:23 PM.