Super duuuuper necro post, but for anyone who finds themselves here after trying the srgExtra line, it's been changed in newer versions of gradle (2.2-SNAPSHOT I know, but maybe even earlier).
Now instead of doing:
minecraft {
...
srgExtra "PK: ..."
}
You have to do:
reobf {
jar {
extraLine "PK: ..."
}
}
Relevant XKCD: https://xkcd.com/979/