[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4668: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3815)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4670: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3815)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4671: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3815)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4672: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3815)
Tao Effect Forums • View topic - Lock all folders via Terminal

Lock all folders via Terminal

General discussion about Espionage 2.

Lock all folders via Terminal

Postby lnealan » Sat Apr 10, 2010 10:13 am

Espionage doesn't seem to have an applescript dictionary and I'd like to be able to automate "lock all folders". Is there a way to invoke this behavior via the terminal?
lnealan
 
Posts: 2
Joined: Sat Apr 10, 2010 10:10 am

Re: Lock all folders via Terminal

Postby greg » Tue Apr 13, 2010 9:05 pm

Last edited by greg on Tue Apr 13, 2010 9:11 pm, edited 1 time in total.
Follow for news!
greg
Tao Effect Support
 
Posts: 564
Joined: Thu Apr 02, 2009 3:14 am
Location: Tao Effect

Re: Lock all folders via Terminal

Postby lnealan » Tue Apr 13, 2010 9:10 pm

Thanks for your reply and pointer! I did realize that for now hdiutil is the only way to go. Since I'm trying to trigger a backup I first run an applescript that quits all the running applications that I have associated with any Espionage folders. Then I run this:

# Lock all folders
mount | grep EspionageMounts | cut -d' ' -f 3- | cut -d'(' -f 1 | xargs -I {} diskutil unmount {} &>/dev/null
lnealan
 
Posts: 2
Joined: Sat Apr 10, 2010 10:10 am

Re: Lock all folders via Terminal

Postby greg » Tue Apr 13, 2010 9:18 pm

Ah neat. I assume you're using some third-party tool for the backup? (Just as an FYI, though you probably already know, Espionage's built-in backups will properly backup the folders regardless of whether they're locked or unlocked.)

One other tip I'd give is to make sure to wait a little bit after all the applications have quit before running that command. Espionage will wait 3 seconds after it detects that an application is no longer running before locking the folder, this is so that application auto-updaters (which quickly quit and relaunch an application) work properly.
Follow for news!
greg
Tao Effect Support
 
Posts: 564
Joined: Thu Apr 02, 2009 3:14 am
Location: Tao Effect

Re: Lock all folders via Terminal

Postby TomEck » Sat Jun 05, 2010 10:57 am

Interesting discussion but a bit over my head or better coding experiences. Is there a simple apple script or terminal code that would allow me to unlock or lock a specific folder or all folders? I would like to use Launchbar to unlock and lock folders. Perhaps it would be possible to tell the Espionage helper via a apple script to lock/unlock a folder? Or could I even assign a keyboard shortcut?

Thanks,
Thomas
TomEck
 
Posts: 7
Joined: Fri Apr 23, 2010 12:41 pm

Re: Lock all folders via Terminal

Postby greg » Sun Jun 06, 2010 3:00 am

Follow for news!
greg
Tao Effect Support
 
Posts: 564
Joined: Thu Apr 02, 2009 3:14 am
Location: Tao Effect

Re: Lock all folders via Terminal

Postby TomEck » Mon Jun 07, 2010 9:11 am

Of course I can open the folder and bring up the password prompt but that means I have to open a Finder window. What I want to do is to access the folders inside LB and that only works when the folder is unlocked. LB is whitelisted for the reason that I don't want a password prompt any time LB want to index the folder or the folder is part of a search result in LB (for the same reason I don't use Application Association). That means I can look through LB into a locked folder but I see only the three folders "This folder contains encrypted data...". Is there a way to unlock a folder other than to open the folder via LB through the Finder?

LB shows me locked and unlocked folders (most of the time; the mentioned problem with symbolic links still exists...) but a unlocked folder seems not properly recognized as a volume even it is listed under volumes. I am not able to eject such a volume.
TomEck
 
Posts: 7
Joined: Fri Apr 23, 2010 12:41 pm

Re: Lock all folders via Terminal

Postby greg » Mon Jun 07, 2010 6:50 pm

Thanks Thomas, we see what you're seeing as well, for some reason LaunchBar can't eject Espionage's volumes (I'm not sure why, this is a question you'll want to ask its developers). We'll look to see what we can do to improve Espionage's compatibility with LaunchBar. In the future you'll probably be able to use Espionage's "Lock Folder" service to lock unlocked folders from LB. Unlocking a folder from LB might take longer though.
Follow for news!
greg
Tao Effect Support
 
Posts: 564
Joined: Thu Apr 02, 2009 3:14 am
Location: Tao Effect

Re: Lock all folders via Terminal

Postby TomEck » Tue Jun 08, 2010 8:38 am

Thanks for the response, Greg. I am glad that you will take a closer look. I have posted a similar information in the . Thanks again!
TomEck
 
Posts: 7
Joined: Fri Apr 23, 2010 12:41 pm


Return to Espionage 2

Who is online

Users browsing this forum: No registered users and 28 guests