Let $X$ be a compact connected Riemann surface, equipped with its complex orientation, and let $L \to X$ be a holomorphic line bundle with a Hermitian metric $h$. Let $F_h \in \Omega^2(X;i\mathbb{R})$ denote the curvature two-form of the Chern connection of $(L,h)$, with the convention that the closed real two-form $\frac{i}{2\pi}F_h$ represents the first Chern class $c_1(L) \in H^2(X;\mathbb{R})$. Let $[X] \in H_2(X;\mathbb{Z})$ denote the fundamental class determined by the complex orientation, and write $\int_X \omega$ for the de Rham pairing $\langle [\omega],[X]\rangle$ of a closed real two-form $\omega \in \Omega^2(X;\mathbb{R})$ with $[X]$. Then
\begin{align*}
\deg L = \int_X \frac{i}{2\pi}F_h.
\end{align*}
Moreover, if $D = \sum_{p \in X} m_p p$ is a divisor on $X$ with all but finitely many integers $m_p$ equal to zero and $L \cong \mathcal{O}(D)$ as holomorphic line bundles, then
\begin{align*}
\deg L = \sum_{p \in X} m_p.
\end{align*}