Use an integrating factor.
Rewrite to get into proper form:
\(\displaystyle \frac{dy}{dx}+y=-e^{-x}sin(x)\)
Using the coefficient of y, which is just 1, the integrating factor is \(\displaystyle e^{\int dx}=e^{x}\)
Use integrating factor:
\(\displaystyle \frac{d}{dx}[e^{x}y]=-e^{x}\cdot e^{-x}sin(x)=-sin(x)\)
Integrate:
\(\displaystyle e^{x}y=cos(x)+C\)
Solve for y:
\(\displaystyle \boxed{y=e^{-x}(cos(x)+C)}\)