Secretary of Defense James Mattis praised a group of sailors last week by telling them they'll never regret military service because it's a sign they're 'not some p--y sitting on the sidelines.'

The Pentagon's official transcript of Mattis' August 9 remarks includes the line, which went unnoticed at the time.

'Thanks for sticking with the Navy,' he said at the Naval Base Kitsap in the state of Washington, adding that the experience would change them 'for the better for the rest of your life.'

'So you'll never regret, but you will have some of the best days of your life and some of the worst days of your life in the U.S. Navy, you know what I mean? That says – that means you're living. That means you're living.'

'That means you're not some p***y sitting on the sidelines, you know what I mean, kind of sitting there saying, "Well, I should have done something with my life",' he said.

'You're not some p***y sitting on the sidelines!' Secretary of Defense James Mattis praised the crew of a nuclear submarine last week in his typical salty language

'Because of what you're doing now, you're not going to be laying on a shrink's couch when you're 45 years old, say "What the hell did I do with my life?" Why? Because you served others; you served something bigger than you.'

It's unclear if any women were among the sailors in Mattis' audience, who were all crew serving on the USS Kentucky nuclear missile submarine.

The U.S. Navy has allowed females to serve on submarines since 2010. A Pentagon spokesman did not have information available about whether any women are among the sub's crew members.

Mattis referred to his audience last week as 'guys' and 'fine young men.'

The retired Marine Corps general, is known for his salty language.

In a quotation widely attributed to him, he supposedly advised servicemen about how to handle anti-military activists on American soil.

'When you men get home and face an anti-war protester, look at him in the eyes and shake his hand,' Mattis reportedly said. 'Then, wink at his girlfriend because she knows she's dating a p***y.'

And Mattis once recalled telling Iraqi military leaders in 2003 that 'I come in peace. I didn't bring artillery. But I'm pleading with you, with tears in my eyes: If you fuck with me, I’ll kill you all.'

His latest invocation of the 'p' word comes at a time when America's military is puffing out its chest in a standoff with North Korea, and with gender politics occupying some headlines.

President Donald Trump said last month that he would ban transgender Americans from serving in uniform.

But on Monday Mattis said the issue was far from decided.

'We are going to study the issue,' he told reporters at the Pentagon. 'The policy is going to address whether or not transgenders can serve under what conditions, what medical support they require, how much time would they be perhaps non-deployable, leaving others to pick up their share of everything.'

'There's a host of issues and I'm learning more about this than I ever thought I would and it's obviously very complex to include the privacy issues which we respect.'