Hi,
Is it possible? Yes.
Is it advisable? No.
Unless you're talking about a localhost instance of SonarQube (why?) then what you're describing is a scenario where you update the global perspective on your project's quality to reflect code changes that
* no one else can see or is even aware of
* you may or may not ever actually check in
I suspect you're after the legendary "pre-commit analysis". For that we have
SonarLint, which will raise issues as you type in your favorite IDE.
HTH,
Ann