osx/*: update page (#7665)

feature/windows-fix-syntax-2
Emily Grace Seville 2022-02-14 03:21:43 -08:00 committed by GitHub
parent b1326296cd
commit 692469016e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
78 changed files with 151 additions and 107 deletions

16
pages/common/oathtool.md Normal file
View File

@ -0,0 +1,16 @@
# oathtool
> OATH one-time password tool.
> More information: <https://www.nongnu.org/oath-toolkit/oathtool.1.html>.
- Generate TOTP token (behaves like Google Authenticator):
`oathtool --totp --base32 "{{secret}}"`
- Generate a TOTP token for a specific time:
`oathtool --totp --now "{{2004-02-29 16:21:42}}" --base32 "{{secret}}"`
- Validate a TOTP token:
`oathtool --totp --base32 "{{secret}}" "{{token}}"`

View File

@ -1,6 +1,7 @@
# rubocop
> Lint Ruby files.
> More information: <https://docs.rubocop.org/rubocop/usage/basic_usage.html>.
- Check all files in the current directory (including subdirectories):

View File

@ -10,15 +10,15 @@
- Print a one line description of the audio file:
`afinfo -b {{path/to/file}}`
`afinfo --brief {{path/to/file}}`
- Print metadata info and contents of the audio file's InfoDictionary:
`afinfo -i {{path/to/file}}`
`afinfo --info {{path/to/file}}`
- Print output in XML format:
`afinfo -x {{path/to/file}}`
`afinfo --xml {{path/to/file}}`
- Print warnings for the audio file if any:
@ -26,4 +26,4 @@
- Display help for full usage:
`afinfo -h`
`afinfo --help`

View File

@ -5,7 +5,7 @@
- Show current wireless status information:
`airport -I`
`airport --getinfo`
- Sniff wireless traffic on channel 1:
@ -13,8 +13,8 @@
- Scan for available wireless networks:
`airport -s`
`airport --scan`
- Disassociate from current airport network:
`sudo airport -z`
`sudo airport --disassociate`

View File

@ -2,6 +2,7 @@
> Provides app sleep services.
> It should not be invoked manually.
> More information: <https://keith.github.io/xcode-man-pages/appsleepd.8.html>.
- Start the daemon:

View File

@ -10,4 +10,4 @@
- Run a command using x86_64:
`arch -x86_64 {{command}}`
`arch -x86_64 "{{command}}"`

View File

@ -2,6 +2,7 @@
> A service for managing Audio Video Bridging (AVB) devices.
> It should not be invoked manually.
> More information: <https://www.manpagez.com/man/1/avbdeviced/>.
- Start the daemon:

View File

@ -13,7 +13,7 @@
- Encode from stdin:
`echo -n {{plain_text}} | base64`
`echo -n "{{plain_text}}" | base64`
- Decode from stdin:

View File

@ -2,6 +2,7 @@
> This supports the syncing of iCloud and iCloud Drive.
> It should not be invoked manually.
> More information: <https://www.unix.com/man-page/mojave/8/bird/>.
- Start the daemon:

View File

@ -5,11 +5,11 @@
- Bless a volume with only Mac OS X or Darwin, and create the BootX and `boot.efi` files as needed:
`bless --folder "{{/Volumes/Mac OS X/System/Library/CoreServices}}" --bootinfo --bootefi`
`bless --folder {{/Volumes/Mac OS X/System/Library/CoreServices}} --bootinfo --bootefi`
- Set a volume containing either Mac OS 9 and Mac OS X to be the active volume:
`bless --mount "{{/Volumes/Mac OS}}" --setBoot`
`bless --mount {{/Volumes/Mac OS}} --setBoot`
- Set the system to NetBoot and broadcast for an available server:

View File

@ -2,6 +2,7 @@
> A service that handles all Bluetooth network connections.
> It should not be invoked manually.
> More information: <https://www.unix.com/man-page/osx/8/bnepd/>.
- Start the daemon:

View File

@ -1,6 +1,7 @@
# brightness
> Get and set the brightness level of all internal and certain external displays.
> More information: <https://github.com/nriley/brightness>.
- Show current brightness:

View File

@ -9,7 +9,7 @@
- Prevent from sleeping until a command completes:
`caffeinate -s {{command}}`
`caffeinate -s "{{command}}"`
- Prevent from sleeping until you type Ctrl-C:

View File

@ -2,6 +2,7 @@
> Provides preferences services (`CFPreferences`, `NSUserDefaults`).
> It should not be invoked manually.
> More information: <https://www.unix.com/man-page/osx/8/cfprefsd/>.
- Start the daemon:

View File

@ -2,6 +2,7 @@
> This synchronizes iCloud Photos.
> It should not be invoked manually.
> More information: <https://www.manpagez.com/man/8/cloudphotosd/>.
- Start the daemon:

View File

@ -5,8 +5,8 @@
- Sign an application with a certificate:
`codesign -s "{{My Company Name}}" {{path/to/App.app}}`
`codesign --sign "{{My Company Name}}" {{path/to/App.app}}`
- Verify the certificate of an application:
`codesign -v {{path/to/App.app}}`
`codesign --verify {{path/to/App.app}}`

View File

@ -9,7 +9,7 @@
- Connect to multiple hosts with a given SSH key:
`csshX {{user@hostname1}} {{user@hostname2}} '--ssh_args' '-i {{path/to/ssh_key.pem}}'`
`csshX {{user@hostname1}} {{user@hostname2}} --ssh_args "-i {{path/to/ssh_key.pem}}"`
- Connect to a pre-defined cluster from `/etc/clusters`:

View File

@ -5,11 +5,11 @@
- Display the current date using the default locale's format:
`date +"%c"`
`date +%c`
- Display the current date in UTC and ISO 8601 format:
`date -u +"%Y-%m-%dT%H:%M:%SZ"`
`date -u +%Y-%m-%dT%H:%M:%SZ`
- Display the current date as a Unix timestamp (seconds since the Unix epoch):

View File

@ -5,19 +5,19 @@
- Read system defaults for an application option:
`defaults read {{application}} {{option}}`
`defaults read "{{application}}" "{{option}}"`
- Read default values for an application option:
`defaults read -app {{application}} {{option}}`
`defaults read -app "{{application}}" "{{option}}"`
- Search for a keyword in domain names, keys, and values:
`defaults find {{keyword}}`
`defaults find "{{keyword}}"`
- Write the default value of an application option:
`defaults write {{application}} {{option}} {{-type}} {{value}}`
`defaults write "{{application}}" "{{option}}" {{-type}} {{value}}`
- Speed up Mission Control animations:
@ -25,4 +25,4 @@
- Delete all defaults of an application:
`defaults delete {{application}}`
`defaults delete "{{application}}"`

View File

@ -2,6 +2,7 @@
> Provides distributed notification services.
> It should not be invoked manually.
> More information: <https://www.manpagez.com/man/8/distnoted/>.
- Start the daemon:

View File

@ -1,6 +1,7 @@
# dmesg
> Write the kernel messages to standard output.
> More information: <https://www.manpagez.com/man/8/dmesg/>.
- Show kernel messages:

View File

@ -13,7 +13,7 @@
- Set Finder as the default handler for the ftp:// URL scheme:
`duti -s {{com.apple.Finder}} {{ftp}}`
`duti -s {{com.apple.Finder}} "{{ftp}}"`
- Display information about the default application for a given extension:

View File

@ -2,7 +2,7 @@
> Event Monitor service that accepts events from various services, runs them through a simple rules engine, and takes action.
> The actions can run commands, send email, or SMS messages.
> More information: <https://www.xorrior.com/emond-persistence/>.
> More information: <https://www.manpagez.com/man/8/emond/>.
- Start the daemon:

View File

@ -1,7 +1,7 @@
# fdesetup
> Set and retrieve FileVault related information.
> Main information: <https://www.unix.com/man-page/mojave/8/fdesetup/>.
> More information: <https://www.unix.com/man-page/mojave/8/fdesetup/>.
- List current FileVault enabled users:

View File

@ -2,6 +2,7 @@
> Coordinates access to files by multiple processes (`NSFileCoordinator`, `NSFilePresenter`).
> It should not be invoked manually.
> More information: <https://www.unix.com/man-page/osx/8/filecoordinationd/>.
- Start the daemon:

View File

@ -17,8 +17,8 @@
- Show tasks for a specified number of days:
`icalBuddy -n tasksDueBefore:today+{{days}}`
`icalBuddy -n "tasksDueBefore:today+{{days}}"`
- Show events in a time range:
`icalBuddy eventsFrom:'{{start_date}}' to:'{{end_date}}'`
`icalBuddy eventsFrom:{{start_date}} to:{{end_date}}`

View File

@ -1,11 +1,11 @@
# lldb
> The LLVM Low-Level Debugger.
> More information: <https://lldb.llvm.org>.
> More information: <https://lldb.llvm.org/man/lldb.html>.
- Debug an executable:
`lldb {{executable}}`
`lldb "{{executable}}"`
- Attach `lldb` to a running process with a given PID:
@ -13,4 +13,4 @@
- Wait for a new process to launch with a given name, and attach to it:
`lldb -w -n {{process_name}}`
`lldb -w -n "{{process_name}}"`

View File

@ -5,7 +5,7 @@
- Look for pattern in the database. Note: the database is recomputed periodically (usually weekly or daily):
`locate {{pattern}}`
`locate "{{pattern}}"`
- Look for a file by its exact filename (a pattern containing no globbing characters is interpreted as `*pattern*`):

View File

@ -9,4 +9,4 @@
- Look for lines ignoring case:
`look -f {{prefix}} {{file}}`
`look --ignore-case {{prefix}} {{file}}`

View File

@ -5,7 +5,7 @@
- Sign into the Mac App Store for the first time:
`mas signin {{user@example.com}}`
`mas signin "{{user@example.com}}"`
- Show all installed applications and their product identifiers:
@ -13,7 +13,7 @@
- Search for an application, displaying the price alongside the results:
`mas search {{application}} --price`
`mas search "{{application}}" --price`
- Install or update an application:

View File

@ -17,4 +17,4 @@
- Print a checksum of the given string:
`md5 -s {{string}}`
`md5 -s "{{string}}"`

View File

@ -9,8 +9,8 @@
- Find a file by its content:
`mdfind {{query}}`
`mdfind "{{query}}"`
- Find a file containing a string, in a given directory:
`mdfind -onlyin {{directory}} {{query}}`
`mdfind -onlyin {{directory}} "{{query}}"`

View File

@ -1,6 +1,7 @@
# nettop
> Display updated information about the network.
> More information: <https://www.manpagez.com/man/1/nettop/>.
- Monitor TCP and UDP sockets from all interfaces:
@ -12,7 +13,7 @@
- Monitor a specific process:
`nettop -p {{process_id|process_name}}`
`nettop -p "{{process_id|process_name}}"`
- Display a per-process summary:

View File

@ -17,4 +17,4 @@
- Connect to a particular Wi-Fi network:
`networksetup -setairportnetwork {{en0}} "{{Airport Network SSID}}" {{password}}`
`networksetup -setairportnetwork {{en0}} {{Airport Network SSID}} {{password}}`

View File

@ -2,6 +2,7 @@
> Notification server.
> It should not be invoked manually.
> More information: <https://www.manpagez.com/man/8/notifyd/>.
- Start the daemon:

View File

@ -1,15 +0,0 @@
# oathtool
> OATH one-time password tool.
- Generate TOTP token (behaves like Google Authenticator):
`oathtool --totp --base32 {{secret}}`
- Generate a TOTP token for a specific time:
`oathtool --totp --now {{2004-02-29 16:21:42}} --base32 {{secret}}`
- Validate a TOTP token:
`oathtool --totp --base32 {{secret}} {{token}}`

View File

@ -2,6 +2,7 @@
> This retrieves and caches Certificate Revocation Lists (CRLs) and Online Certificate Status Protocol (OCSP) responses for certificate verification.
> It should not be invoked manually.
> More information: <https://www.manpagez.com/man/1/ocspd/>.
- Start the daemon:

View File

@ -1,6 +1,7 @@
# open
> Opens files, directories and applications.
> More information: <https://ss64.com/osx/open.html>.
- Open a file with the associated application:
@ -8,7 +9,7 @@
- Run a graphical macOS application:
`open -a {{Application}}`
`open -a "{{Application}}"`
- Run a graphical macOS app based on the bundle identifier (refer to `osascript` for an easy way to get this):

View File

@ -1,6 +1,7 @@
# opensnoop
> Tool that tracks file opens on your system.
> More information: <https://ss64.com/osx/opensnoop.html>.
- Print all file opens as they occur:
@ -8,7 +9,7 @@
- Track all file opens by a process by name:
`sudo opensnoop -n {{process_name}}`
`sudo opensnoop -n "{{process_name}}"`
- Track all file opens by a process by PID:

View File

@ -5,11 +5,11 @@
- Run an AppleScript command:
`osascript -e '{{say "Hello world"}}'`
`osascript -e "{{say 'Hello world'}}"`
- Run multiple AppleScript commands:
`osascript -e '{{say "Hello"}}' -e '{{say "world"}}'`
`osascript -e "{{say 'Hello'}}" -e "{{say 'world'}}"`
- Run a compiled (`*.scpt`), bundled (`*.scptd`), or plaintext (`*.applescript`) AppleScript file:
@ -21,7 +21,7 @@
- Run a JavaScript command:
`osascript -l JavaScript -e '{{console.log("Hello world");}}'`
`osascript -l JavaScript -e "{{console.log('Hello world');}}"`
- Run a JavaScript file:

View File

@ -1,6 +1,7 @@
# pbcopy
> Place standard output in the clipboard.
> More information: <https://ss64.com/osx/pbcopy.html>.
- Place the contents of a file in the clipboard:

View File

@ -1,6 +1,7 @@
# pbpaste
> Send the contents of the clipboard to standard output.
> More information: <https://ss64.com/osx/pbpaste.html>.
- Write the contents of the clipboard to a file:

View File

@ -2,6 +2,7 @@
> This analyzes photo libraries for Memories, People, and scene or object based search.
> It should not be invoked manually.
> More information: <https://www.manpagez.com/man/8/photoanalysisd/>.
- Start the daemon:

View File

@ -2,6 +2,7 @@
> This handles all photo library requests.
> It should not be invoked manually.
> More information: <https://www.manpagez.com/man/8/photolibraryd/>.
- Start the daemon:

View File

@ -1,27 +1,28 @@
# ping
> Send ICMP ECHO_REQUEST packets to network hosts.
> More information: <https://ss64.com/osx/ping.html>.
- Ping the specified host:
`ping {{host}}`
`ping "{{hostname}}"`
- Ping a host a specific number of times:
`ping -c {{count}} {{host}}`
`ping -c {{count}} "{{host}}"`
- Ping `host`, specifying the interval in `seconds` between requests (default is 1 second):
`ping -i {{seconds}} {{host}}`
`ping -i {{seconds}} "{{host}}"`
- Ping `host` without trying to lookup symbolic names for addresses:
`ping -n {{host}}`
`ping -n "{{host}}"`
- Ping `host` and ring the bell when a packet is received (if your terminal supports it):
`ping -a {{host}}`
`ping -a "{{host}}"`
- Ping `host` and prints the time a packet was received (this option is an Apple addition):
`ping --apple-time {{host}}`
`ping --apple-time "{{host}}"`

View File

@ -1,6 +1,7 @@
# pkgutil
> Query and manipulate Mac OS X Installer packages and receipts.
> More information: <https://ss64.com/osx/pkgutil.html>.
- List package IDs for all installed packages:

View File

@ -1,6 +1,7 @@
# plutil
> View, convert, validate, or edit property list ("plist") files.
> More information: <https://www.manpagez.com/man/1/plutil/>.
- Display the contents of one or more plist files in human-readable format:

View File

@ -1,6 +1,7 @@
# pod
> Dependency manager for Swift and Objective-C Cocoa projects.
> More information: <https://guides.cocoapods.org/terminal/commands.html>.
- Create a Podfile for the current project with the default contents:

View File

@ -1,6 +1,7 @@
# qlmanage
> QuickLook server tool.
> More information: <https://ss64.com/osx/qlmanage.html>.
- Display QuickLook for one or multiple files:

View File

@ -1,6 +1,7 @@
# reboot
> Reboot the system.
> More information: <https://ss64.com/osx/reboot.html>.
- Reboot immediately:

View File

@ -1,6 +1,7 @@
# rename
> Rename a file or group of files with a regular expression.
> More information: <https://www.manpagez.com/man/2/rename/>.
- Replace `from` with `to` in the filenames of the specified files:

View File

@ -2,18 +2,19 @@
> Manually manipulate the routing tables.
> Necessitates to be root.
> More information: <https://www.manpagez.com/man/8/route/>.
- Add a route to a destination through a gateway:
`sudo route add {{dest_ip_address}} {{gateway_address}}`
`sudo route add "{{destination_ip_address}}" "{{gateway_address}}"`
- Add a route to a /24 subnet through a gateway:
`sudo route add {{subnet_ip_address}}/24 {{gateway_address}}`
`sudo route add "{{subnet_ip_address}}/24" "{{gateway_address}}"`
- Run in test mode (does not do anything, just print):
`sudo route -t add {{dest_ip_address}}/24 {{gateway_address}}`
`sudo route -t add "{{destination_ip_address}}/24" "{{gateway_address}}"`
- Remove all routes:
@ -21,8 +22,8 @@
- Delete a specific route:
`sudo route delete {{dest_ip_address}}/24`
`sudo route delete "{{destination_ip_address}}/24"`
- Lookup and display the route for a destination (hostname or IP address):
`sudo route get {{destination}}`
`sudo route get "{{destination}}"`

View File

@ -1,7 +1,7 @@
# SafeEjectGPU
> Eject a GPU safely.
> Visit the man page for more info.
> More information: <https://www.unix.com/man-page/mojave/8/safeejectgpu>.
- Eject all GPUs:

View File

@ -9,16 +9,16 @@
- Read a file aloud:
`say -f {{filename.txt}}`
`say --input-file={{filename.txt}}`
- Say a phrase with a custom voice and speech rate:
`say -v {{voice}} -r {{words_per_minute}} "{{I'm sorry Dave, I can't let you do that.}}"`
`say --voice={{voice}} --rate={{words_per_minute}} "{{I'm sorry Dave, I can't let you do that.}}"`
- List the available voices:
`say -v "?"`
`say --voice="?"`
- Create an audio file of the spoken text:
`say -o {{filename.aiff}} "{{Here's to the Crazy Ones.}}"`
`say --output-file={{filename.aiff}} "{{Here's to the Crazy Ones.}}"`

View File

@ -2,6 +2,7 @@
> Controls access to and modification of keychain items.
> It should not be invoked manually.
> More information: <https://www.unix.com/man-page/mojave/8/secd>.
- Start the daemon:

View File

@ -3,6 +3,7 @@
> This manages security contexts and cryptographic operations.
> Works with secd for keychain access.
> It should not be invoked manually.
> More information: <https://www.unix.com/man-page/osx/1/securityd/>.
- Start the daemon:

View File

@ -1,6 +1,7 @@
# shuf
> Generate random permutations.
> More information: <https://www.unix.com/man-page/linux/1/shuf/>.
- Randomize the order of lines in a file and output the result:
@ -8,12 +9,12 @@
- Only output the first 5 entries of the result:
`shuf -n {{5}} {{filename}}`
`shuf --head-count={{5}} {{filename}}`
- Write output to another file:
`shuf {{filename}} -o {{output_filename}}`
`shuf {{filename}} --output={{output_filename}}`
- Generate random numbers in range 1-10:
`shuf -i {{1-10}}`
`shuf --input-range={{1-10}}`

View File

@ -17,7 +17,7 @@
- Reboot in 5 minutes:
`shutdown -r +{{5}}`
`shutdown -r "+{{5}}"`
- Power off (halt) at 1:00 pm (Uses 24h clock):

View File

@ -2,6 +2,7 @@
> Apple Scriptable Image Processing System.
> Raster/Query images and ColorSync ICC Profiles.
> More information: <https://ss64.com/osx/sips.html>.
- Specify an output directory so that originals do not get modified:
@ -9,11 +10,11 @@
- Resample image at specified size, Image aspect ratio may be altered:
`sips -z {{1920}} {{300}} {{image.ext}}`
`sips --resampleHeightWidth {{1920}} {{300}} {{image.ext}}`
- Resample image so height and width aren't greater than specified size (notice the capital Z):
`sips -Z {{1920}} {{300}} {{image.ext}}`
`sips --resampleHeightWidthMax {{1920}} {{300}} {{image.ext}}`
- Resample all images in a directory to fit a width of 960px (honoring aspect ratio):
@ -21,8 +22,8 @@
- Convert an image from CMYK to RGB:
`sips --matchTo '/System/Library/ColorSync/Profiles/Generic RGB Profile.icc' {{path/to/image.ext}} {{path/to/out_dir}}`
`sips --matchTo "/System/Library/ColorSync/Profiles/Generic RGB Profile.icc" {{path/to/image.ext}} {{path/to/out_dir}}`
- Remove ColorSync ICC profile from an image:
`sips -d profile --deleteColorManagementProperties {{path/to/image.ext}}`
`sips --deleteProperty profile --deleteColorManagementProperties {{path/to/image.ext}}`

View File

@ -2,6 +2,7 @@
> An SNTP server.
> It should not be invoked manually.
> More information: <https://linux.die.net/man/8/snmpd>.
- Start the daemon:

View File

@ -1,19 +1,20 @@
# softwareupdate
> A tool for updating macOS App Store apps via the command-line.
> More information: <https://ss64.com/osx/softwareupdate.html>.
- List all available updates:
`softwareupdate -l`
`softwareupdate --list`
- Download and install all updates:
`softwareupdate -ia`
`softwareupdate --install --all`
- Download and install all recommended updates:
`softwareupdate -ir`
`softwareupdate --install --req`
- Download and install a specific app:
`softwareupdate -i {{update_name}}`
`softwareupdate --install {{update_name}}`

View File

@ -10,7 +10,7 @@
- Add a rule to allow an application to run (labeling of rule is optional):
`spctl --add --label "{{rule_name}}" {{path/to/file}}`
`spctl --add --label {{rule_name}} {{path/to/file}}`
- Turn on Gatekeeper:

View File

@ -1,6 +1,7 @@
# split
> Split a file into pieces.
> More information: <https://ss64.com/osx/split.html>.
- Split a file, each split having 10 lines (except the last split):

View File

@ -13,4 +13,4 @@
- Print the system serial number:
`system_profiler SPHardwareDataType|grep "Serial Number (system)" |awk '{print $4}'`
`system_profiler SPHardwareDataType|grep "Serial Number (system)" | awk '{ print $4 }'`

View File

@ -9,7 +9,7 @@
- Specify timezone, NTP Server and enable network time:
`systemsetup -settimezone {{US/Pacific}} -setnetworktimeserver {{us.pool.ntp.org}} -setusingnetworktime on`
`systemsetup -settimezone "{{US/Pacific}}" -setnetworktimeserver {{us.pool.ntp.org}} -setusingnetworktime on`
- Make the machine never sleep and automatically restart on power failure or kernel panic:

View File

@ -9,7 +9,7 @@
- Set an APF share or SMB share as the backup destination:
`sudo tmutil setdestination {{protocol://user[:password]@host/share}}`
`sudo tmutil setdestination "{{protocol://user[:password]@host/share}}"`
- Append the given destination to the list of destinations:

View File

@ -2,6 +2,7 @@
> Provides universal access services.
> It should not be invoked manually.
> More information: <https://www.manpagez.com/man/8/universalaccessd/>.
- Start the daemon:

View File

@ -1,6 +1,7 @@
# uptime
> Tell how long the system has been running and other information.
> More information: <https://ss64.com/osx/uptime.html>.
- Print current time, uptime, number of logged-in users and other information:

View File

@ -2,6 +2,7 @@
> Provides notification services.
> It should not be invoked manually.
> More information: <https://www.unix.com/man-page/mojave/8/usernoted>.
- Start the daemon:

View File

@ -2,6 +2,7 @@
> Listens for incoming VPN connections.
> It should not be invoked manually.
> More information: <https://www.unix.com/man-page/osx/8/vpnd/>.
- Start the daemon:

View File

@ -9,11 +9,11 @@
- Record a video:
`wacaw --video {{filename}} -D {{duration_in_seconds}}`
`wacaw --video {{filename}} --duration {{duration_in_seconds}}`
- Take a picture with custom resolution:
`wacaw -x {{width}} -y {{height}} {{filename}}`
`wacaw --width {{width}} --height {{height}} {{filename}}`
- Copy image just taken to clipboard:
@ -21,4 +21,4 @@
- List the devices available:
`wacaw -L`
`wacaw --list-devices`

View File

@ -1,7 +1,7 @@
# wc
> Count lines, words, or bytes.
> More information: <https://www.gnu.org/software/coreutils/wc>.
> More information: <https://ss64.com/osx/wc.html>.
- Count lines in file:

View File

@ -1,23 +1,24 @@
# whence
> A zsh builtin to indicate how a given command would be interpreted.
> More information: <https://www.unix.com/man-page/OpenSolaris/1/whence/>.
- Interpret {{command}}, with expansion if defined as an `alias` (similar to the `command -v` builtin):
`whence {{command}}`
`whence "{{command}}"`
- Display type of {{command}}, with location if defined as a function, or binary (equivalent to the `type` and `command -V` builtins):
`whence -v {{command}}`
`whence -v "{{command}}"`
- Same as above, except display content of shell functions instead of location (equivalent to `which` builtin):
`whence -c {{command}}`
`whence -c "{{command}}"`
- Same as above, but show all occurrences on command path (equivalent to the `where` builtin):
`whence -ca {{command}}`
`whence -ca "{{command}}"`
- Search only the `PATH` for {{command}}, ignoring builtins, aliases or shell functions (equivalent to the `where` command):
`whence -p {{command}}`
`whence -p "{{command}}"`

View File

@ -10,16 +10,16 @@
- Select a given path as the active developer directory:
`xcode-select -s {{path/to/Xcode.app/Contents/Developer}}`
`xcode-select --switch {{path/to/Xcode.app/Contents/Developer}}`
- Select a given Xcode instance and use its developer directory as the active one:
`xcode-select -s {{path/to/Xcode.app}}`
`xcode-select --switch {{path/to/Xcode.app}}`
- Print the currently selected developer directory:
`xcode-select -p`
`xcode-select --print-path`
- Discard any user-specified developer directory so that it will be found via the default search mechanism:
`sudo xcode-select -r`
`sudo xcode-select --reset`

View File

@ -1,6 +1,7 @@
# xed
> Opens files for editing in Xcode.
> More information: <https://www.manpagez.com/man/1/xed/>.
- Open file in Xcode:
@ -8,8 +9,8 @@
- Open file(s) in Xcode, create if it doesn't exist:
`xed -c {{filename1}}`
`xed --create {{filename1}}`
- Open a file in Xcode and jump to line number 75:
`xed -l 75 {{filename}}`
`xed --line 75 {{filename}}`

View File

@ -2,6 +2,7 @@
> Create or expand compressed files in a secure xip archive.
> Only archives signed by Apple are trusted, so this tool should not be used to create archives.
> More information: <https://www.manpagez.com/man/1/xip/>.
- Expand the archive into the current working directory:

View File

@ -9,4 +9,4 @@
- Pass a value to a parameter in the stylesheet:
`xsltproc --output {{output.html}} --stringparam {{name}} {{value}} {{stylesheet.xslt}} {{xmlfile.xml}}`
`xsltproc --output {{output.html}} --stringparam "{{name}}" "{{value}}" {{stylesheet.xslt}} {{xmlfile.xml}}`

View File

@ -1,6 +1,7 @@
# yaa
> Create and manipulate YAA archives.
> More information: <https://www.manpagez.com/man/1/yaa/>.
- Create an archive from a directory: