I have already successfully found a proof of the equality $$V_{a}^{b}(f) = \int_{a}^{b} |f'(x)| \, dx$$ where $f$ is a continuously differentiable function on $(a,b)$ and continuous on $[a,b]$ as well as being of bounded variation. I tried to prove a similar statement: $$V_{0}^{2\pi}(f) = |f(0^+) - f(0^-)| + \sum\limits_{i = 1}^{n} |f(x_j^+) - f(x_j^{-})| + \int_{0}^{2\pi} |f'(x)| \, dx$$ where $f$ is piecewise continuously differentiable with jump discontinuities $(x_j)_{j=1,\ldots,n}$, $2\pi$-periodic on $[0,2\pi]$ and we impose that $f(x) = \frac{1}{2}(f(x^{+})-f(x^{-}))$ for left ($x^-$) and right ($x^{+}$) limits in $x \in [0,2\pi)$ respectively.
This showed up in an example to show that every such periodic function is of bounded variation. I tried to use the above proof of the continuously differentiable case and force it into the subintervals where $f$ is continuously differentiable, but things like the FTC and MVT break down at the boundary points, leaving me a bit in the dark how to progress.
I maybe have found a way to prove this using a contrived system of nested finite sums, but I think they would just clutter up this post if I type them up. Thus, I would like to ask if there was a more elegant way to prove this than by sheer brute force of the naive approach.
A hint or literature reference on how to get this would be enough, but I'm not upset if you put in the effort!