# Making a plugin commandlet

**URL:** <https://forums.unrealengine.com/t/making-a-plugin-commandlet/347697>\
**Category:** C++\
**Tags:** commandlet, unreal-engine, editor, question, CPP\
**Created:** [February 16, 2016, 11:19pm UTC](https://forums.unrealengine.com/t/making-a-plugin-commandlet/347697 "2016-02-16T23:19:30Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![anonymous\_user\_598164a8](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_598164a8](https://forums.unrealengine.com/u/anonymous_user_598164a8)\
**Post date:** [February 16, 2016, 11:19pm UTC](https://forums.unrealengine.com/t/making-a-plugin-commandlet/347697/1 "2016-02-16T23:19:30Z")

</div>

I’m trying to create a commandlet in a plugin, which seems to be possible according to [this answer](https://answers.unrealengine.com/questions/90171/console-commands-vs-commandlets.html). \

I’ve got a plugin which contains a `UCommandlet` derived class with a static `main()` However I can’t fire it off from the command line – I always get `UAssetTestCommandlet looked like a commandlet, but we could not find the class` when I try to invoke it. I looked a a few of the commandlets in the source (for example `AudioTestCommandlet.h`) and that’s all that appears to be needed – but no dice. Is there some kind of registration or instantiaion I need to do beyond deriving from `UCommandlet`?

---

<div class="post-metadata">

**Author:** ![BobWhite](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@BobWhite](https://forums.unrealengine.com/u/BobWhite)\
**Post date:** [August 17, 2016, 4:09pm UTC](https://forums.unrealengine.com/t/making-a-plugin-commandlet/347697/2 "2016-08-17T16:09:06Z")

</div>

Just spent yesterday moving a commandlet into a plugin, so it seems to be working on 4.12.

.uplugin file:

```
{
	"FileVersion": 3,
	"Version": 1,
	"VersionName": "1.0",
	"FriendlyName": "ContentAuditTools",
	"Description": "",
	"Category": "Other",
	"CreatedBy": "",
	"CreatedByURL": "",
	"DocsURL": "",
	"MarketplaceURL": "",
	"SupportURL": "",
	"EnabledByDefault": false,
	"CanContainContent": false,
	"IsBetaVersion": false,
	"Installed": false,
	"Modules": [
		{
			"Name": "ContentAuditTools",
			"Type": "Editor",
			"LoadingPhase": "Default"
		}
	]
}

```

You do need to make sure the plugin is enabled, otherwise it won’t be available when you try to actually run the commandlet.

So make sure something like this is in your .uproject file.

```
"Plugins": [
		{
			"Name": "ContentAuditTools",
			"Enabled": true
		}
	]
```

---

<div class="post-metadata">

**Author:** ![Engene\_Hsuan](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/engene_hsuan/32/706297_2.png) [@Engene\_Hsuan](https://forums.unrealengine.com/u/Engene_Hsuan)\
**Post date:** [June 14, 2023, 9:44am UTC](https://forums.unrealengine.com/t/making-a-plugin-commandlet/347697/3 "2023-06-14T09:44:26Z")

</div>

you code help me.  
my Modulus “LoadingPhase” is not “Default”; Thanks
