Skip to content

Instantly share code, notes, and snippets.

@opatry
Last active December 19, 2015 17:19
Show Gist options
  • Save opatry/5990803 to your computer and use it in GitHub Desktop.
Save opatry/5990803 to your computer and use it in GitHub Desktop.
X11 Desktop Entry Getting Started.
var desktop_entry = require('desktop-entry');
desktopEntry.load({
entry:'./myfile.desktop',
onSuccess:function(model){
// model is a JSON representation of the Desktop Entry file
// where sections are roots of JSON object
// each root contains a list of {key:value} objects.
console.log(model["Desktop Entry"].Version);
},
onError:function(errorMessage){
// handle error here
}
});
@opatry
Copy link
Author

opatry commented Jul 13, 2013

X11 Desktop Entry Getting Started.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment