I am trying to use script command for logging a bash session.
The script command is executed from withing a bash script but as soon as it i
Your bash script is still running, but it has spawned a new interactive shell. The bash script is waiting for script to complete, which will only happen when the interactive shell is terminated (either by being killed, or by the user typing exit).
To make the command after script be logged by script, do it like this:
script build_log -c 'echo -e "* This line should appear inside the /"build_log/" log file..."'
However, script will stop running after running that command.
To run multiple commands inside script, put those commands inside another bash script and specify that bash script as the command to run to the -c option.