Self-made app will not open I have created a Java application and wanted to run it as a standard application bundle. Here is the directory tree:  

Snake.app
  Contents
    MacOS
      Snake
      Snake.jar
    Resources
      AppIcon.icns
    Info.plist


The Snake file just says cd $(dirname $0) then java -jar Snake.jar. Here is the Info.plist file:

&lt;?xml version="1.0" encoding="UTF-8"?&gt;
&lt;!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"&gt;
&lt;plist version="1.0"&gt;
&lt;dict&gt;
    &lt;key&gt;CFBundleExecutable&lt;/key&gt;
    &lt;string&gt;Snake&lt;/string&gt;
    &lt;key&gt;CFBundleIconFile&lt;/key&gt;
    &lt;string&gt;AppIcon&lt;/string&gt;
    &lt;key&gt;CFBundleIconName&lt;/key&gt;
    &lt;string&gt;AppIcon&lt;/string&gt;
    &lt;key&gt;CFBundleIdentifier&lt;/key&gt;
    &lt;string&gt;com.mosu.SnakeGame&lt;/string&gt;
    &lt;key&gt;CFBundleName&lt;/key&gt;
    &lt;string&gt;Snake&lt;/string&gt;
    &lt;key&gt;CFBundlePackageType&lt;/key&gt;
    &lt;string&gt;APPL&lt;/string&gt;
    &lt;key&gt;CFBundleShortVersionString&lt;/key&gt;
    &lt;string&gt;1.2.2&lt;/string&gt;
    &lt;key&gt;LSApplicationCategoryType&lt;/key&gt;
    &lt;string&gt;public.app-category.games&lt;/string&gt;
    &lt;key&gt;LSMinimumSystemVersion&lt;/key&gt;
    &lt;string&gt;10.6&lt;/string&gt;
    &lt;key&gt;NSHumanReadableCopyright&lt;/key&gt;
    &lt;string&gt;Copyright © 2020 Sebastian Swistak &amp;quot;mOSU_&amp;quot;&lt;/string&gt;
&lt;/plist&gt;


What am I doing wrong?
You should run the Snake.app/Contents/MacOS/Snake executable in Terminal to see if there's an error launching. 
Just Drag and drop it in Terminal and hit enter. If it launches, it's probably gatekeeper.

You can also check its permissions by running spctl -vv -a /path/to/app. If it is rejected, run 

spctl --add --label "LabelForMySnakeApp" /path/to/app
spctl --enable --label "LabelForMySnakeApp"



Block Specific Apps on macOS


Also see this question for some troubleshoot about codesign:


Gatekeeper refuses validly signed application