ntrogers
9/12/2017 - 5:32 PM

[macOS - Useful Commands] #macOS

[macOS - Useful Commands] #macOS

# Disable print sharing
cupsctl --no-share-printers

# Location of generic printer driver
/System/Library/Frameworks/ApplicationServices.framework/Versions/A/Frameworks/PrintCore.framework/Versions/A/Resources/Generic.ppd

# List all print drivers installed on a system
lpinfo -m -h 127.0.0.1:631

# Reset the printing system
lpstat -p | cut -d' ' -f2 | xargs -I{} lpadmin -x {} 
# View Package Contents
pkgutil –-expand thePackage.pkg /destination

# Get application bundle identifier
defaults read /Applications/Safari.app/Contents/Info.plist CFBundleIdentifier
# Mount network drive
osascript -e 'mount volume "smb://username:password@server/SMCSD Server"'