Reputation: 419
I'm using nwjs 0.14.7, and ubuntu 32bit. I recently updated from 0.12.2, and now the build process seems to be different or doesn't work.
I've added my files to package.nw and then appended to nw via:
cat nw app.nw > app && chmod +x app
Then in the docs it says "On Linux, you need to create proper .desktop file." But there aren't any directions specific for this case, If I try running nw, it says "There is no application installed for "shared library" files. Do you want to search for an application to open this file?"
So I'm assuming the .desktop file would fix this? It says you can create it via a text editor, but I have no idea what I should put inside it. For 0.12.2 the .desktop step wasn't necessary so I'm a bit lost now.
Upvotes: 1
Views: 1178
Reputation: 31
I know I am using ubuntu 14.04 and what I did worked for me so this is how I did it.
Create a .desktop file for your app by:
1.press right click on mouse then 'New Document => Empty Document'.
2.inside the document insert the following text:
[Desktop Entry]
Version=1.0 (this is the version of the .desktop file and not your app version)
Type=Application
Terminal=false
Exec=/home/artechs/projects/copa-linux-x64/nw (this is the full path for the executable file)
Name=copa (this will show up on the menu)
Comment=secure sharing files application (this will show up if you right click on the app)
Icon=/home/artechs/projects/copa-linux-x64/package.nw/app/styles/COPA LOGO RGB-01.png (for the icon of this file and also the icon that will show up on the share applications)
Categories=Utility;Application;
3.press on the menu bar 'File => Save As...' and give it a name with .desktop extension for example copa.desktop
4.go to Terminal and to your app folder where this file is located and type: chmod +x <nameOFDesktopFile>.desktop
5.now you need to copy this file to share applications folder by type: cp <nameOFDesktopFile>.desktop /usr/share/applications
After doing this steps I could run my app through this desktop file or through the search by searching the name of my app.
Hope it will work for you as it worked for me.
Upvotes: 2