<p>This would probably be better as an rpmlint check, except then it might be ignored.</p>
<p>Certainly from RPM's perspective, having a %pretrans scriptlet written in shell or anything else is perfectly valid.  Only a distro like Fedora which cares about every package being installable into an empty filesystem would want to reject it, and it would still be OK for someone building their own packages.  So even if an option/flag/magic macro existed, Fedora would have to think twice about setting it by default (though I think in the end we would want to do so, even if it means anyone building custom packages that doesn't care would have to turn it off manually).</p>
<p>Is there any part of the rpm-build process where a distro could hook in basic checks on scriptlets?  Would it be reasonable to have one?</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/rpm-software-management/rpm/issues/714?email_source=notifications&email_token=ADLPZU3LJ7JBS3244Q2YWVLP66RT3A5CNFSM4HPWMFP2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODZYBTIA#issuecomment-510663072">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/ADLPZU7N2I7ERYTX4MZS5WTP66RT3ANCNFSM4HPWMFPQ">mute the thread</a>.<img src="https://github.com/notifications/beacon/ADLPZUZUIUIGNZWZSFI2SRLP66RT3A5CNFSM4HPWMFP2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODZYBTIA.gif" height="1" width="1" alt="" /></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/rpm-software-management/rpm/issues/714?email_source=notifications\u0026email_token=ADLPZU3LJ7JBS3244Q2YWVLP66RT3A5CNFSM4HPWMFP2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODZYBTIA#issuecomment-510663072",
"url": "https://github.com/rpm-software-management/rpm/issues/714?email_source=notifications\u0026email_token=ADLPZU3LJ7JBS3244Q2YWVLP66RT3A5CNFSM4HPWMFP2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODZYBTIA#issuecomment-510663072",
"name": "View Issue"
},
"description": "View this Issue on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>