you are viewing a single comment's thread
view the rest of the comments
[–] 3 points 10 months ago (2 children)

How does this even work? I get the redirection part, but how is the command executed in a detached state?

  • source
  • parent
  • hideshow 2 child comments
  • [–] 4 points 10 months ago

    () creates a subshell, and & runs the command in background. The $@ means everything after the first argument, so the <command> is executed like a normal command. I am not sure why this works, but it has worked more consistently than nohup, disown, and it's a lot shorter than most other solutions.

  • source
  • parent