<s>[INST] $\bigg(\frac{-2}{p}\bigg)= \begin{cases} 1 & \text{ if $p\equiv 1$ or $3 \mod 8$} \\ -1 & \text{ if $p\equiv 5$ or $7 \mod 8$} \\\end{cases}$ Show that
$$\bigg(\frac{-2}{p}\bigg)=
\begin{cases} 
1 & \text{ if $p\equiv 1$ or $3 \mod 8$} \\
-1 & \text{ if $p\equiv 5$ or $7 \mod 8$} \\\end{cases}$$
$\textbf{Proof:}$
\begin{equation*}
\begin{aligned}
\bigg(\frac{-2}{p}\bigg) &=\bigg(\frac{-1}{p}\bigg)\bigg(\frac{2}{p}\bigg)
=(-1)^\frac{p-1}{2}(-1)^\frac{p^2-1}{8}
=(-1)^\frac{4(p-1)+p^2-1}{8} \\
& =(-1)^\frac{p^2+4p-5}{8} 
=(-1)^\frac{(p-1)(p+5)}{8}
\end{aligned}
\end{equation*}
$\textbf{Case $1$:}$ \begin{equation*}
\begin{aligned}
(-1)^\frac{(p-1)(p+5)}{8}=1 & \iff \frac{(p-1)(p+5)}{8} \text{ is even}  \\
& \iff \frac{(p-1)(p+5)}{8}=2k \text{ for $k\in \mathbb{Z}$}
\iff (p-1)(p+5)=16k \\
& \iff p-1=16k \text{ or } p+5=16k
\iff p=16k+1 \text{ or } p=16k-5 \\
& \iff p\equiv 1 \mod 8 \text{ or } p\equiv -5\equiv 3 mod 8
\end{aligned}
\end{equation*}
$\textbf{Case $2$:}$ \begin{equation*}
\begin{aligned}
(-1)^\frac{(p-1)(p+5)}{8}=-1 & \iff \frac{(p-1)(p+5)}{8} \text{ is odd}  \\
& \iff \frac{(p-1)(p+5)}{8}=2k+1 \text{ for $k\in \mathbb{Z}$}
\iff (p-1)(p+5)=16k+8 \\
& \iff p-1=16k+8 \text{ or } p+5=16k+8
\iff p=16k+9 \text{ or } p=16k+3 \\
& \iff p\equiv 1 \mod 8 \text{ or } p\equiv 3 \mod 8
\end{aligned}
\end{equation*}
Am I right so far? If so how can I finish case 1? Note I am using Jacobi symbols.
 [/INST] 1) Recall that if $p$ is an odd prime, then $2$ is a QR of $p$ if $p\equiv  1$ or $7 \pmod{8}$, and $2$ is an NR of $p$ if $p\equiv 3$ or $5\pmod{8}$.
2) Also, $-1$ is a QR of $p$ if $p\equiv 1\pmod{4}$ and is an NR of $p$ if $p\equiv 3\pmod{4}$.  This can be restated as $-1$ is a QR of $p$ if $p\equiv  1$ or $5 \pmod{8}$, and is an NR of $p$ if $p\equiv 3$ or $7\pmod{8}$.
Looking at 1) and 2), we see that $2$ and $-1$ are both QR of $p$ if $p\equiv 1\pmod{8}$, and they are both NR of $p$ if $q\equiv 3\pmod{8}$. 
Thus $-2$ is a QR of $p$ if and only if $p\equiv 1$ or $3\pmod{8}$. 
Remark: In the OP as revised, you have reduced the problem to finding out when $(p-1)(p+5)$ is divisible by $16$. 
If $p=8k+1$, then $p-1$ is divisible by $8$, and $p+5$ is even, so $(p-1)(p+5)$ is divisible by $16$.
If $p=8k+3$, then $p+5$ is divisible by $8$, and $p-1$ is even, so $(p-1)(p+5)$ is divisible by $16$.
If $p=8k+5$, then $(p-1)(p+5)=(8k+4)(8k+10)$. The highest power of $2$ that divides $8k+4$ is $4$, and the highest power of $2$ that divides $8k+10$ is $2$, so the highest power of $2$ that divides the product is $(4)(2)=8$. It follows that the exponent $\frac{(p-1)(p+5)}{8}$ is odd. 
The case $p=8k+7$ goes along lines similar to the case $8k+5$.
Note that your current arguments are incorrect. It is not true that $(p-1)(p+5)$ is divisible by $16$ if and only if $p-1$ is divisible by $16$ or $p+5$ is divisible by $16$. For each of $p-1$ and $p+5$ is even, so each makes a contribution to divisibility by powers of $2$.
</s>