This is what I ended up with: (edit based on comment)
DECLARE @ISSYSADMIN INT SET @ISSYSADMIN = (SELECT COUNT(1) FROM sys.syslogins WHERE sysadmin = 1 AND loginname = '$(ContentAccount)')
$ (ContentAccount) is, of course, a parameterization that has a domain and username!
This solves my problem because when we deploy a new database we assign permissions manually. But in development environments where the user we are trying to add is already sysadmin, they fail. Therefore, if we check sysadmin membership, which is enough to cover the dev server script.
Then I do this to verify ownership:
IF (@ISSYSADMIN = 0) BEGIN -- Add authority END
source share