  We study the thermodynamics of open systems weakly driven out-of-equilibrium
by nonconservative and time-dependent forces using the linear regime of
stochastic thermodynamics. We make use of conservation laws to identify the
potential and nonconservative components of the forces. This allows us to
formulate a unified near-equilibrium thermodynamics. For nonequilibrium steady
states, we obtain an Onsager theory ensuring nonsingular response matrices that
is consistent with phenomenological linear irreversible thermodynamics. For
time-dependent driving protocols that do not produce nonconservative forces, we
identify the equilibrium ensemble from which Green-Kubo relations are
recovered. For arbitrary periodic drivings, the averaged entropy production
(EP) is expressed as an independent sum over each driving frequency of
non-negative contributions. These contributions are bilinear in the
nonconservative and conservative forces and involve a novel generalized Onsager
matrix that is symmetric. In the most general case of arbitrary time-dependent
drivings, we advance a novel decomposition of the EP rate into two non-negative
contributions - one solely due to nonconservative forces and the other solely
due to deviation from the instantaneous steady-state - directly implying a
minimum entropy production principle close to equilibrium. This setting reveals
the geometric structure of near-equilibrium thermodynamics and generalizes
previous approaches to cases with nonconservative forces.
