First of all, the expression can be simplified, since a factor #(x+2)# appears in both numerator and denominator. So, we have
#\frac{(x-1)cancel((x+2))(x+5)}{2xcancel((x+2))} = \frac{(x-1)(x+5)}{2x}#
From here, we can expand the numerator:
#\frac{(x-1)(x+5)}{2x} = \frac{x^2+4x-5}{2x}#
To study the end behavior, simply factor our the highest power in both numerator and denominator:
# \frac{x^2+4x-5}{2x} = \frac{x^2(1+4/x-5/x^2)}{2x} = \frac{x(1+4/x-5/x^2)}{2}#
Now, as #x\to\pm\infty#, you have that #4/x# and #-5/x^2# tend to zero. So, the whole expression has the same behaviour as #x/2# (which again is the same behaviour as #x#).
So, since #\lim_{x\to\pm\infty} x = \pm\infty#, this will also be the behaviour of your expression.