It's the exact same idea as older version of OpenGL. You set up a model view matrix and you multiply all your vertex positions by it. The only difference is instead of setting up the matrix with OpenGL function calls, you do it in the shader code.
xerzi just meant the fragment shader is irrelevant to your goal here. The vertex shader is the only thing you need to involve in order to perform this transformation.