Adding a second command/executable

Is it possible to install a second command/executable with a snap package? Eg. this is the repository for my snap package. It installs nsm but I want to install a duplicate as nift too. The makefile compiles both nsm and nift but I’m having trouble getting snap to install nift properly.

I tried adding nift to the snapcraft.yaml file as an app/command, but that didn’t seem to work. Does anyone have any suggestions?

Just add a second stanza under apps: for your nift command.

Since the app name doesn’t match the snap name, it will be exposed as nsm.nift by default. It is possible to create an alias to the shorter nift name using snap alias as discussed here:

That documentation also explains how you can request this alias be installed automatically with your package.

That seems to do the trick, thanks, and have put in a request for an alias in the forums.