Set Desktop Wallpaper from Command Line on Mac
Whenever I need to accomplish a basic task that typically calls for interacting with a UI, I challenge myself to complete the task from command line. After all, most UIs are simply a mask over basic commands, especially when it comes to the operating system. Suddenly I feel like an automation or systems engineer!
One task I can imagine an IT administrator would need to automate is setting the desktop wallpaper via a script, remotely, or simply by providing the command to do so:
osascript -e 'tell application "Finder" to set desktop picture to POSIX file "/Users/davidwalsh/Downloads/pubg-background.jpg"'
It's important to note that you must provide the absolute path to the image, and not a path that begins with a user path (i.e. ~/Downloads/my-image.jpg)
Beyond the general nerdiness of knowing how to change desktop wallpaper via command line, it could be useful to change your background based on a service being down or other event.
I challenge you to think more like a remote IT administrator or automator when you need to accomplish your next simple task!
![Responsive Images: The Ultimate Guide]()
Chances are that any Web designers using our Ghostlab browser testing app, which allows seamless testing across all devices simultaneously, will have worked with responsive design in some shape or form. And as today's websites and devices become ever more varied, a plethora of responsive images...
![Introducing MooTools Templated]()
One major problem with creating UI components with the MooTools JavaScript framework is that there isn't a great way of allowing customization of template and ease of node creation. As of today, there are two ways of creating:
new Element Madness
The first way to create UI-driven...
![Truly Responsive Images with responsive-images.js]()
Responsive web design is something you hear a lot about these days. The moment I really started to get into responsive design was a few months ago when I started to realise that 'responsive' is not just about scaling your websites to the size of your...
![Spatial Navigation]()
Spatial navigation is the ability to navigate to focusable elements based on their position in a given space. Spatial navigation is a must when your site or app must respond to arrow keys, a perfect example being a television with directional pad remote. Firefox OS TV apps are simply...