Toggle Dark Mode
A variation of this has been around since the first beta, but what the heck:
tell application "System Events"
tell appearance preferences
set dark mode to not dark mode
end tell
end tell
Save it in Script Editor named "Toggle DM" (or whatever) and select "Application" as the File Format, which makes it activate by clicking on it in the Finder. I recommend putting it in the Dock or Finder window toolbar for quick access.
Updates for Mojave
As I mentioned last week, I have been updating scripts and apps for Mojave on a piecemeal basis. There are a good forty or so scripts now ready for Mojave Monday and the apps Dupin v2.14.2, M3Unify v1.11.1 and Join Together v7.8.2 have received initial updates for Mojave.
Mojave-ready scripts will explicitly state that they have been updated for Mojave. Otherwise, most scripts that can run on macOS 10.10 and later will likely be fine in 10.14. Except for being ignorant of your Dark Mode settings. And perhaps other very minor and benign incompatibilities.
Also, as I mentioned, the first time you run any apps or scripts of mine in Mojave you will be asked to "OK" access to iTunes.

If you click on "Don't Allow", you will need to visit System Preferences / Security & Privacy / Privacy and re-authorize the script.
I will continue to be cranking out updates over the coming days and weeks.
What About Dark Mode?

I wasn't rooting for a Dark Mode, the new low-light display preference in macOS 10.14 Mojave. And after working in it I don't particularly care for it. But I get that many people will find it compelling. So I'm guessing that there are a few "Dark Power" users who will expect that the scripts they download from this site will work in Dark Mode.
Well, they won't. Not all yet, anyway. In order for AppleScript apps and scripts to respond to Dark Mode they have to be built in Mojave. Anything built in prior operating systems won't know about Dark Mode. Now, other than updating the scripts just for Dark Mode, there aren't enough compatibility issues that necessitates a script to be updated yet (new security features, notwithstanding). Most all have been testing fine under the macOS 10.14 betas. So, in my opinion, there's no rush.
That said, there are some scripts and apps I will be updating for Mojave sooner than later, and these will include some of the more popular shareware apps and scripts. And then, eventually, as more scripts require regular maintenance they will be updated as a matter of course.
Mojave Security
Most apps from this site are 1) saved as read-only to inhibit malicious code injection, 2) codesigned with my authorized developer ID so that they will break if they are so edited and 3) packaged in a disk image that is also codesigned with my developer ID so that the disk image will not open if its contents doesn't check out. You—the user—also have Gatekeeper security options to allow just Mac App Store and/or developer signed apps.
Additionally, I would hope that my own personal reputation as a "good dude", cultivated over almost twenty years as an AppleScript developer, would also attest to the safety of my scripts. But that won't be the case for bad actors attempting to hijack processes on your Mac.
Apple is introducing a new level of security in Mojave called "AppleEvent Sandboxing". It effects how AppleScript is or isn't permitted to access certain locations and processes on your Mac.
When you launch an AppleScript of mine for the first time on macOS 10.14 Mojave you'll see something like this:

This message will appear before the app or script starts runniing or it may appear a little later into the launch, if and when it actually attempts to access iTunes. AppleScripts that work with multiple apps will display an alert for each of those apps.
(Personally, I think that "OK" button should say "Allow", but, whatevs.)
This is a new layer of protection that attempts to prevent AppleScripts, and other apps that use AppleScript, from controling apps and accessing data without you knowing about it. When you click "OK", you've acknowledged to the system that you indeed intend to use the script with said application. Once so acknowledged, you shouldn't see the dialog(s) again for that particular script.
Users of scripts that have targeted "System Events" may be familiar with this process when Accessibility requires a similar acknowledgement. This is a little different since it falls under the purview of Security & Privacy. In fact, if you go to System Preferences > Security & Privacy > Privacy > Automation, you will see the list of apps that use automation and which apps they target:

The list of apps on my machine is way longer than appear here.
If necessary, you can uncheck an app if you suspect the listed AppleScript is up to some funny business. Or, if you clicked on "Don't Allow" when first asked, you can enable access for a particular app.
Felix Schwartz has posted some first looks at AppleEvent Sandboxing and it's worth a read until Mojave is officially released and Apple tells us more.
Airport Express Firmware Update
I use three Airport Express base stations each hooked up to class-D amp/speakers so we can have music around the house. And this past week Apple—surprisingly—released a firmware update for these discontinued devices that gives them support for AirPlay 2. AirPlay 2 eliminates any audio latency between devices that may be playing simultaneiously (such as a pair of HomePods used in stereo). While this wasn't much of a problem at my house before the update—minimal latency was detectable occasionally and wasn't too distracting—I can attest that there is zero detectable latency now.
The Airport Express is a great option for creating an AirPlay audio network and you can still find them being sold as refurbs, used on eBay and elsewhere. They aren't exactly using modern WiFi or security protocols, but if this isn't an issue at your house it may be an inexpensive way to wirelessly extend your audio system.

The "Kitchen Express" on top of our refrigerator.
Dupin v2.14
I'm happy to announce the release of Dupin v2.14, which adds a couple of navigation features I found myself wanting.

In case you don't know, Dupin works with iTunes to discover, manage and even remove duplicate tracks and files. But Dupin allows you a way to establish exactly what properties of tracks make them duplicates and to choose which single track of a "Dupe Group" of tracks is the "Keeper" and which are the "non-Keeper(s)". The latter Filtering can be done automatically or manually by scrolling through the Dupe Groups.
Dupin is available to try in Demo Mode, whereby some features are limited. A registration code to unlock the Demo Mode is $15.00.
Dupin turns eleven years old this year and wouldn't have stayed alive so long without such a great group of users. So thanks!
iTunes 12.8 Available
Apple has released iTunes 12.8 (build 12.8.0.150). Other than initial support for AirPlay 2, I haven't encountered any other significant changes. (ICYDK, the betas of macOS 10.14 install iTunes 12.9.)
Apple also released macOS 10.13.6 with AirPlay 2 support among the changes.
macOS 10.14 Mojave Betas
Apple has released the first Mojave beta for enrollees of its Public Beta program. Developers have had access to two versions of the beta to date.
Like most developers, I'll be spending a lot of my Summer digging in to make sure my scripts and apps for iTunes are compatible and/or take advantage of new macOS features. And, as I caution around this time every year, if you are using the betas:
Don't count on current scripts and apps having complete compatibility this early. In my nominal testing so far, I haven't run into any serious issues with current versions of my software. But unless a script or app specifically states that it's macOS 10.14 Mojave-compatible, assume that it isn't—at least until the final release of Mojave later this year.
Early betas are simply not stable and can't be depended on for "mission-critical" work. If a script or app doesn't work like it used to it could be because the OS isn't fully-baked yet.
Report a problem! The whole point of the beta program is to expose problems. It's a good thing! If you have an issue with my software running under the Mojave beta, please let me know the details by emailing support AT dougscripts DOT com.
Thanks for your support and help!
UPDATED: M3Unify v1.10.0
M3Unify is a flexible file exporter and M3U playlist creator that will allow you to sensibly off-load copies of your iTunes songs to a user-chosen location—separate folder, external drive, USB thumb drive, SD card and so on—the way you and your audio player want.

M3Unify can archive playlists and audio files to a folder, volume or portable media and includes options to create Artist/Album sub-folders, rename files, convert to lossy formats, export album artwork, and more.
Watch the video demonstration.
M3Unify v1.10.0 adds these new features:
- Adds ability to open/drag-and-drop an M3U playlist file to "add" the accessible files it references
- Adds "Export M3U Using Relative Paths" option to create M3U playlist based on relative paths of files already in established locations
- Adds feature to remove duplicated entries
- Adds "Kind" column for better sorting of different audio types
- Adds option to show the Finder Information Window for a file
M3Unify is easy to configure and use. Try the nearly-full-featured demo for yourself. A license to make M3Unify fully-full-featured is $5.00. This update is free for registered users—who are the greatest!
iTunes 12.7.5 is Available
I'm late with posting this, but, for the record, Apple released iTunes 12.7.5 (build 12.7.5.9) on May 29. Probably contains changes for AirPlay 2. And the usual app fixes and improvements.

