![]() You can read the original how-to at hints, or below, where I've posted the updated version that no longer uses growlnotify. I've also modified it a bit, as I no longer use growlnotify for the onscreen display of the copied IP address. I originally wrote this up for Mac OS X Hints a few years back, but thought I'd post it here (given the changes at Macworld, I'm not sure how long the hints site may be around). This is a big timesaver, obviously, and it makes the process about as easy as it could be. Press a key combo, wait about a second, then press Command-V Switch to browser, open new tab, load the DynDNS check IP page, drag mouse to select IP address, press Command-C to copy, switch back to destination app, press Command-V to paste OK, so that's two things, but they're very closely related.Ĭlearly this isn't something I need to do often, but when I do, the script changes this… It's also a very simple-minded script, as it does just one thing: it copies my public IP address to the clipboard and shows it in a pop-up message, as seen at right. But when I do need it, it's a wonderful little script. Today I had the opportunity to use my favorite one-which is rare, as I only need it a couple times a year. LaunchAgent=/Library/LaunchAgents/ have a large number of small shell scripts I've either written or collected over the years. =/Library/Application Support/Bloomberg//.app Initially I was getting /bin/launchctl bsexec "$") have a similar issue, I ended up using asuser for my 10.10 and 10.11 machines, but I'm having problems getting bsexec to work for my 10.9 and older. So far testing is going well! Seems to be working like a charm via policy and I can assign parameters for the title, message, use -active (or -open) and a click-back action. Once I understood that, I was able to make the necessary adjustments without needing to double escape the path to the app or use a symlink. It was getting tripped up somewhere along there because of that. I mistakenly did not enclose the line in quotes, but I had the variables for title and message quoted. I was attempting to use variables for the -title and -message rather than being hardcoded in, among other things, so it can be flexible. See, I didn't realize that the whole line after the sudo -iu including the path to terminal-notifier was one command enclosed in quotes being passed in. ![]() ![]() Your tips helped, but it actually turned out to be my ignorance in how the script was actually telling terminal-notifier to do its thing. Been playing with it, and I figured out what I was doing wrong. Thanks for the quick response and help on this. Using other paths with spaces and other methods of escaping all yield the same type of error. Launchctl bsexec failed: No such file or directory Here is what the policy log states (only the relevant error lines): -bash: /Library/Application: No such file or directory Must be something with the bsexec function that I just don't understand. Usually one of the above methods gets around space issues, but not this time. it still fails every time saying it doesn't exist. I've tried setting up the path as a variable and placing it later in the script with quotes, without quotes, curly bracing it, quoting AND curly bracing it and finally just putting the path directly in the script line with spaces escaped. Any time its located in a path with spaces, no matter what I've tried, it fails, claiming no such file or directory. I tried out your script and unfortuantely it seems the only way it has worked is if the terminal-notifier app is in a path WITHOUT spaces. ![]() I'm very interested in getting terminal-notifier to work with a regular script downloaded from the JSS and not using the LaunchAgent method I came up. For posting your version of a script for this.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |