HostOS: Migrate from OSX to macOS

Apple started calling their operating system macOS, rather than OSX a while ago,
and as such, we should follow suit. This introduces `::hostos::MACOS`, and makes
`::OSX` an alias of it.

All internal users were updated to refer to `::hostos::MACOS`, but the `::OSX`
alias is being kept indefinitely.

Signed-off-by: Gergely Nagy <algernon@keyboard.io>
pull/1068/head
Gergely Nagy 4 years ago
parent 36938bb57b
commit 8328bd7be2
No known key found for this signature in database
GPG Key ID: AC1E90BAC433F68F

@ -25,8 +25,8 @@ void someFunction(void) {
if (HostOS.os() == kaleidoscope::hostos::LINUX) {
// do something linux-y
}
if (HostOS.os() == kaleidoscope::hostos::OSX) {
// do something OSX-y
if (HostOS.os() == kaleidoscope::hostos::MACOS) {
// do something macOS-y
}
}
@ -55,10 +55,13 @@ The extension provides the following methods on the `HostOS` singleton:
The OS type (i.e. the return type of `.os()` and the arguments to `.os(type)`) will be one of the following:
- `kaleidoscope::hostos::LINUX`
- `kaleidoscope::hostos::OSX`
- `kaleidoscope::hostos::MACOS`
- `kaleidoscope::hostos::WINDOWS`
- `kaleidoscope::hostos::OTHER`
For compability reasons, `kaleidoscope::hostos::OSX` is an alias to
`kaleidoscope::hostos::MACOS`.
## Focus commands
The plugin provides the `FocusHostOSCommand` object, which, when enabled,

@ -1,6 +1,6 @@
/* -*- mode: c++ -*-
* Kaleidoscope-HostOS -- Host OS detection and tracking for Kaleidoscope
* Copyright (C) 2016, 2017, 2018 Keyboard.io, Inc
* Copyright (C) 2016-2021 Keyboard.io, Inc
*
* This program is free software: you can redistribute it and/or modify it under
* the terms of the GNU General Public License as published by the Free Software
@ -25,7 +25,8 @@ namespace hostos {
typedef enum {
LINUX,
OSX,
MACOS,
OSX = MACOS,
WINDOWS,
OTHER,

Loading…
Cancel
Save