Jump to content

Need an app to move file to user folder


5 posts in this topic

Recommended Posts

I'm setting up multitple workstation with Final Cut Pro 7 and I want to make a self contained application that moves the preference file I made to the user's library. For practical puposes, I want the preference file to be contained in the application.

 

I can get it done easily with a shell script :

cp Final\ Cut\ Pro\ 7.0\ Prefs.fcset ~/Library/Preferences/Final\ Cut\ Pro\ User\ Data/Final\ Cut\ Pro\ 7.0\ Prefs.fcset

but as I said, I want the pref file to be contained within the app so it doesn't get deleted or anything (it's also prettier :))

 

I've been using Automator in my attemps and I'd like to cotinue to do so. Xcode is excluded. The workstations are running Mac OS X 10.8.5.

 

EDIT : I want other people to use this app just by double clicking it. No terminal involved.

 

Thanks for your help.

Edited by dear hefbe
  • Like 1
Link to comment
Share on other sites

So... I moved the preference file inside the app and cd'ed to it using an absolute path, then, cp'ed the file where I want it. It works. To be clear, here's the code :

cd /Users/dearhefbe/Desktop/RegPrefs.app/Contents/MacOS #This is where is stored my pref file, obviously 
cp FinalCutPro7.0Prefs.fcset ~/Library/Preferences/Final\ Cut\ Pro\ User\ Data/FinalCutPro7.0Prefs.fcset.fcset

Now, how can I use a relative path so the app can be moved across computers and still work?

  • Like 1
Link to comment
Share on other sites

two options 

 

1. ssh (enable remote access)

 

google scp

 

scp dearhefbe@machine.local(enter ip):~/Desktop/RegPrefs.app/Contents/MacOS/FinalCutPro7.0Prefs.fcset ~/Library/Preferences/FinalCutProUserData

 

it will ask for password.

 

2.

(enable file sharing)

cp FinalCutPro7.0Prefs.fcset /Volumes/sharedRemoteUser/Library/Preferences/Final\ Cut\ Pro\ User\ Data/FinalCutPro7.0Prefs.fcset.fcset

Link to comment
Share on other sites

  • 8 months later...

 

two options 

 

1. ssh (enable remote access)

 

google scp

 

scp dearhefbe@machine.local(enter ip):~/Desktop/RegPrefs.app/Contents/MacOS/FinalCutPro7.0Prefs.fcset ~/Library/Preferences/FinalCutProUserData

 

it will ask for password.

 

2. Transfer app

The app is capable of moving content from one device to another. The program is built on C++ with QT embedded.

 

3.

(enable file sharing)

cp FinalCutPro7.0Prefs.fcset /Volumes/sharedRemoteUser/Library/Preferences/FinalCutProUserData/FinalCutPro7.0Prefs.fcset.fcset

 

 

that's cool. Second vote on SCP

Link to comment
Share on other sites

 Share

×
×
  • Create New...