This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>Label</key> | |
<string>com.scriptingosx.setdesktop</string> | |
<key>ProgramArguments</key> | |
<array> | |
<string>/usr/local/bin/desktoppr</string> | |
<string>/Library/Desktop Pictures/BoringBlueDesktop.png</string> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
export PATH=/usr/bin:/bin:/usr/sbin:/sbin | |
# checkusers | |
# | |
# written by Armin Briegel, Scripting OS X, 2018 | |
# | |
# code is provided as is, with no guarantees that it will work etc. | |
# adapt and use as you will |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
PATH=/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/munki export PATH | |
# this will run as a munki install_check script | |
# exit status of 0 means install needs to run | |
# exit status not 0 means no installation necessary | |
# adapted scripts from here: https://jamfnation.jamfsoftware.com/discussion.html?id=1989 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
export PATH=/usr/bin:/bin:/usr/sbin:/sbin | |
installerBuildVersion() { # $1 path to the installer app | |
installerApp=${1:?"no path for installer"} | |
# echo "inspecting: $installerApp" | |
if [[ -d "$installerApp" ]]; then | |
identifier=$(/usr/libexec/PlistBuddy -c "print CFBundleIdentifier" "$installerApp/Contents/Info.plist") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# modify the system.preferences right | |
/usr/bin/security authorizationdb write system.preferences <<EndOfPlist | |
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>allow-root</key> | |
<true/> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
global linkText | |
on run | |
set linkText to "" | |
tell application "Safari" | |
activate | |
set w to window 1 | |
set n to 0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>PayloadContent</key> | |
<array> | |
<dict> | |
<key>PayloadDisplayName</key> | |
<string>Desktop</string> | |
<key>PayloadEnabled</key> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
property defaultAccountName : "iCloud" | |
property defaultFolderName : "Saved iCloud Tabs" | |
global html | |
global processedURLs | |
on appendLineWithURLItem(urlItem) | |
my appendHTML(" <li>") | |
my appendHTML("<a href=\"" & |url| of urlItem & "\">") | |
my appendHTML(|Title| of urlItem) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/osascript | |
on run arguments | |
tell application "Finder" | |
-- no argument: get frontmost window or desktop | |
if (count of arguments) is 0 then | |
if (count of windows) is 0 then | |
set dir to (desktop as alias) | |
else | |
set dir to ((target of Finder window 1) as alias) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ENVIRONMENT VARIABLES | |
# add my ~/bin dir to path | |
PATH=${PATH}:~/bin | |
export PATH | |
# simple prompt | |
# default macOS prompt is: \h:\W \u\$ | |
export PS1="\W \$ " |