Step 1: Completing the square
The denominator can be rewritten by completing the square:
\[
x^2 + x + 1 = \left( x + \frac{1}{2} \right)^2 + \frac{3}{4}.
\]
Let \( u = x^2 + x + 1 \), then:
\[
du = (2x+1) dx.
\]
Step 2: Splitting the integral
Rewriting the given integral,
\[
I = \int \frac{x+1}{\sqrt{x^2+x+1}} dx.
\]
Using substitution \( u = x^2 + x + 1 \), and separating terms,
\[
I = \int \frac{(2x+1)}{2\sqrt{u}} dx + \int \frac{dx}{\sqrt{u}}.
\]
The first integral simplifies to \( \sqrt{u} \), and the second integral is evaluated using inverse hyperbolic functions:
\[
\int \frac{dx}{\sqrt{x^2 + x + 1}} = \sinh^{-1} \left(\frac{2x+1}{\sqrt{3}}\right).
\]
Step 3: Final expression
Thus, the final integral evaluates to:
\[
I = \sqrt{x^2+x+1} + \frac{1}{2} \sinh^{-1} \left(\frac{2x+1}{\sqrt{3}}\right) + C.
\]