I know this is true but strangely can't find references.
Also, consider the trivial $n$-bundle over any connected compact manifold, does Liouville imply that all holomorphic sections are constant?
Consider the tautological bundle over a Grassmanian manifold. Does Liouville imply that the only holomorphic section is the zero section?
Let $f: X \to \mathbb C$ an holomorphic map, non-constant
Then $f$ is open (standard argument using Maximum principle for example). But $f(X)$ is compact and open, and non-empty. Contradiction.
Conclusion : $f$ is a constant map.