fetch-pack: move write_fetch_command_and_capabilities() to connect.c
In a subsequent commit write_fetch_command_and_capabilities() will be
refactored to a more general-purpose function, making it more accessible
to additional commands in the future.
Move write_fetch_command_and_capabilities() to 'connect.c', where
there are similar purpose functions.
Because string_list is only used as a pointer, use a forward
declaration [1].
Helped-by: Jonathan Tan <redacted> Helped-by: Christian Couder <redacted> Signed-off-by: Calvin Wan <redacted> Signed-off-by: Eric Ju <redacted> Signed-off-by: Pablo Sabater <redacted> Signed-off-by: Junio C Hamano <redacted>