• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Running cmd as logged in user from admin script
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Running cmd as logged in user from admin script


  • Subject: Re: Running cmd as logged in user from admin script
  • From: Fritz Anderson <email@hidden>
  • Date: Fri, 7 Mar 2008 09:37:10 -0600

On 7 Mar 2008, at 9:31 AM, Alexander Cohen wrote:

I have an installer that has a script that runs after the install. The installer is run with admin privileges. From the script, i need to run a cmd as the currently logged in user. Is there a way to do that ?

su $USER -c "/path/to/command"

If it's an application:

su $USER -c "open /Applications/MyApplication.app"

	— F

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Installer-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: Running cmd as logged in user from admin script
      • From: Alexander Cohen <email@hidden>
References: 
 >Running cmd as logged in user from admin script (From: Alexander Cohen <email@hidden>)

  • Prev by Date: Running cmd as logged in user from admin script
  • Next by Date: Re: Running cmd as logged in user from admin script
  • Previous by thread: Running cmd as logged in user from admin script
  • Next by thread: Re: Running cmd as logged in user from admin script
  • Index(es):
    • Date
    • Thread