Green’s Dictionary of Slang

be good! excl.

a joc. phr. used on parting; often ext. to if you can’t be good, be careful!, which in itself can be ext. to if you can’t be careful, buy a pram!

[US]S.E. White Riverman 29: Well, good-bye, boys [...] Be good!
[Aus]Bulletin (Sydney) 8 Aug. 15: Force of Habit. / Visiting Parson: ‘And now, my dear young friend, I must leave you.’ / Young Lag (cheerily): ‘All right. Be good.’.
[UK]W.L. George Making of an Englishman III 304: ‘Ta-ta. Be good,’ she said, and ran up the stairs.
[US]Dos Passos Manhattan Transfer 213: Good night Miss Oglethorpe [...] and if you can’t be good be careful.
[UK](con. 1914–18) Brophy & Partridge Songs and Sl. of the British Soldier 97: Be Good. — An almost nonsensical exclamation, used in parting company, chiefly by officers. Meant facetiously. Sometimes given in full — ‘Be good. And if you can’t be good, be careful.’.
[US]P. Thomas Down These Mean Streets (1970) 140: ‘Later, turkey. Be good.’ ‘Yeah, baby, take it slow.’.
[US]W.B. Lindley ‘Jocelyn Elders My Hero’ 🌐 She supported condoms. ‘Be good; if you can’t be good, be careful; if you can’t be careful, name it after me.’.
[US]Scott Perry 🎵 Be good. If you can’t be good, be careful. If you can’t be careful then please don’t hurt anybody!