Passing a concrete resolver on the command-line correctly overrides the resolver found in the stack.yaml, but passing an abstract resolver does not.
Example:
$ stack new --bare --resolver lts-4.1 foo
$ stack --nix --resolver lts-2.22 build
...
Compared to:
$ stack --nix --resolver lts-2 build
Selected resolver: lts-2.22
Compiler version mismatched, found ghc-7.10.2 (x86_64), but expected minor version match with ghc-7.8.4 (x86_64) (based on resolver setting in /tmp/foo/stack.yaml).