Autorun for Mac? - macos

I've got a Flash projector which I plan to distribute on CD. I'm making a projector for Mac and Windows. I know how to do Autorun on Windows, but I want to do so on Mac as well.
How does that work?

It doesn't. Mac OS 7–9 had a similar system but Mac OS X has nothing of the sort.
Your best bet is to make a nice Finder window design that makes it clear what to do. DropDMG may be useful.

There is no autorun in OSX anymore.

You can't set an application to autorun for security reasons. However you can set a Finder window to auto open on insert. I've seen a lot of CDs do this then have a "Click here to start" icon.
This is the terminal command to set it up on your diskimage before burning. discName should be the name of your disk image.
sudo bless -folder "/Volumes/discName" -openfolder "/Volumes/discName"
More info here

There is an easy way to do it. Just right-click the icon in the dock, chose "Options", then "Open at Login"
Then the selected app will launch every time OSX boots.

Related

Disable OSX Mavericks' "Do you want to try to reopen its windows again?" popup

I'm using OSX's launchctrl functionality to automatically relaunch an app after it crashes.
Unfortunately, when the app relaunches, it launches together with an action window that reads:
"The last time you opened MyAppName, it unexpectedly quit while reopening windows. Do you want to try to reopen its windows again?"
I tried to suppress it by calling NSQuitAlwaysKeepWindows
defaults write -app /Path/to/app/MyAppName.app NSQuitAlwaysKeepsWindows -bool false
But this only works some of the time - I'd say that the popup window launches 50% of the time.
This window requires action and blocks the app from jumping into a full screen mode.
I'm on OSX 10.8.4
Thanks for any ideas ...
Jeremy
Open the folder "~/Library/Saved Application State" and look for a file like "some.url.MyAppName.savedState".
Deleting this file might probably solve the problem, at least it worked for me.
I was able to fix mine by deleting the Envelope Index file(All the files with the name "Envelope Index") under /Library/Mail/V2/MailData folder.
Then restart the mac.

How to make a Disk auto-run both in Windows and MAC OS X

I have develop two tiny utility applications for both Windows and MAC OS X. I know how to make this disk auto-run by Window. But for MAC OS X, I've no idea how to.
Any one know about how to achieve this? Can I make ONE disk auto-run by both Windows and MAC OS X? And of cause, different OS should run different apps designed for themselves. For example, Window may run "util_Win.exe", while MAC OS X "util_MAC.app".
You can customize the background of a window by opening the window and choosing "Show View Options" from the "View" menu in the Finder. Once displayed, you can set the "Background" setting to "Picture" and then choose the picture you want.
See here for an example.

Disable Script Prompt on Mac OSX Lion?

I was wondering...
Is it possible to disable the prompt on Mac OSX Lion that says.
Are you sure you want to run this script? [Yes, Cancel]
I added this script to the "Login Items" File to start automatically when I login, but the prompt still pops up. Any Ideas?
Thanks.
When an Applescript is saved as an application so that it can be run independently of Script Editor with a double-click, there is an option to have a "startup screen" which, in Snow Leopard and before (I don't have Lion), offers a choice between "Run" (the default) or "Quit". I imagine you might have enabled that feature without realizing, or maybe in Lion it is now activated by default.

Unable to install Xcode on Mac OS X Lion (10.7) [duplicate]

I am trying to install Xcode 4.1 GM on my Lion mac but it's not working. When it is almost finished, I get the popup to quit iTunes even though it is already quit. So the only option I have is to quit iTunes helper or alert in activity monitor, then it finishes the install. However then Xcode crashes on launch. Any ideas?
You can go into Activity Monitor and Quit the iTunes helper. That will also get Xcode to finish.
Looks like you've solved the install problem. It's not a solution per se, but setting Xcode to run in 32-bit mode fixed the crashing problem for me.
It's too early to say what the trade-off is (if any), but whatever it is, it's bound to be better than not being able to use it at all.
On a side note: please accept Phil's answer since he gave the correct solution to your original problem. C:
if you boot into single user mode (Press S when starting up), the installation works as it should. Xcode will then function without switching it to 32-bit mode.
Open "Activity Monitor" (press Command+Space to bring up spotlight, or find it in Applications.)
Sort by Process Name and find the process called "iTunesHelper".
From the "View" menu choose "Quit Process".
Then click on the "Force Quit" button. Xcode installation should continue now.
Try to use the xCode through the Finder after you get this problem. It happened to me, but I can still run the xCode.
I think it's something to do with your version of itunes is more updated than your Mac Os version.

Mac OS X Services: enable without user interaction?

I wrote a simple Mac 'Service' for Finder, that executes a command.
Basically: this adds a ContextMenu in Finder.
If I right-click a file in Finder, a menu item pops up. If the user clicks it, it executes my script. (kind of like 'Send to Bluetooth device, ...')
In OS X Leopard (10.5) and earlier, all services are enabled.
In 10.6 (Snow Leopard), Apple changed the behavior, services now have preferences, and can be enabled or disabled by the user. (which is a good thing)
However, I wrote the service, but there seems to be no way to enable it automatically (in our installer).
I tried doing it with Applescript, going to the System Preferences and ticking the checkbox that way, but it requires some accessibility features to be turned on. (off by default).
Is it possible? If so, how?
Or do I need something else to provide Context Menus in Finder.
I tracked File changes on my filesystem while changing the preferences and discovered there was a plist file:
~/Library/Prefrences/pbs.plist
which contains what I need.
If I edit that manually, it seems to work. So, problem solved :)

Resources