Skip to main content
added 16 characters in body
Source Link
Naomi
  • 259
  • 2
  • 5

Reviving this question because strace is an overkill here.

Execute bash and carve it out of the output. -li is login interactively, -x prints out what bash is doing internally, and -c exit tells bash to terminate immediately. Using sed to filter out the source command printoutor the . alias.

/bin/bash -lixc exit 2>&1 | sed -n 's/^+* source\(source\|\.\) //p'

Reviving this question because strace is an overkill here.

Execute bash and carve it out of the output. -li is login interactively, -x prints out what bash is doing internally, and -c exit tells bash to terminate immediately. Using sed to filter out the source command printout.

/bin/bash -lixc exit 2>&1 | sed -n 's/^+* source //p'

Reviving this question because strace is an overkill here.

Execute bash and carve it out of the output. -li is login interactively, -x prints out what bash is doing internally, and -c exit tells bash to terminate immediately. Using sed to filter out the source command or the . alias.

/bin/bash -lixc exit 2>&1 | sed -n 's/^+* \(source\|\.\) //p'
added 62 characters in body
Source Link
Naomi
  • 259
  • 2
  • 5

Reviving this question because strace is an overkill here.

Execute bash and carve it out of the output. -li is login interactively, -x prints out what bash is doing internally, and -c exit just tells bash to terminate immediately. Using sed to filter out the source command printout.

/bin/bash -lixc exit 2>&1 | sed -n 's/^[+++]*^+* source //p'

Execute bash and carve it out of the output. -li is login interactively, -x prints out what bash is doing internally, and -c exit just tells bash to terminate immediately. Using sed to filter out the source command.

/bin/bash -lixc exit 2>&1 | sed -n 's/^[+++]* source //p'

Reviving this question because strace is an overkill here.

Execute bash and carve it out of the output. -li is login interactively, -x prints out what bash is doing internally, and -c exit tells bash to terminate immediately. Using sed to filter out the source command printout.

/bin/bash -lixc exit 2>&1 | sed -n 's/^+* source //p'
Source Link
Naomi
  • 259
  • 2
  • 5

Execute bash and carve it out of the output. -li is login interactively, -x prints out what bash is doing internally, and -c exit just tells bash to terminate immediately. Using sed to filter out the source command.

/bin/bash -lixc exit 2>&1 | sed -n 's/^[+++]* source //p'