Get or set the desktop wallpaper
Works on OS X, Linux and Windows.
$ npm install --global wallpaper
$ wallpaper --help
Usage
$ wallpaper [file]
Example
$ wallpaper unicorn.jpg
$ wallpaper
/Users/sindresorhus/unicorn.jpg
$ npm install --save wallpaper
var wallpaper = require('wallpaper');
wallpaper.set('unicorn.jpg', function (err) {
console.log('done');
});
wallpaper.get(function (err, imagePath) {
console.log(imagePath);
//=> '/Users/sindresorhus/unicorn.jpg'
});
Required
Type: function
Type: string
Path to the current desktop wallpaper image.
Required
Type: string
Path to the image to set as the desktop wallpaper.
MIT © Sindre Sorhus