Egyszerű kis AppleScript a Microsoft Entourage X felhasználóinak: átmásolja az e-maileket, aláírásokat, és egyéb kacatokat az Entourage tárolókönyvtárából (alapbeállítás: a user könyvtáradban Documents:Microsoft User Data:Office X Identities:Main Identity) egy szabadon, Finder böngészőablakból kiválasztott (vagy ízlés szerint a scriptben pontosan megadott) könyvtárba, azon belül is egy, az adott napi dátum alapján elnevezett alkönyvtárba.
Ez elég bonyolultan hangzott… Magyarul létrehozunk egy alkönyvtárat (pl. 2003-06-24) a választott folderben (imígyen a pontos helye Júzer HD:Users:juzer:Desktop:2003-06-24), majd átmásoljuk az emileket, satöbbit. Nnna.
Íme a script:
copy ((offset of (the month of (current date)) in “jan feb mar apr may jun jul aug sep oct nov dec “) + 3) / 4 as integer to mo
if mo copy day of (current date) to da
if (day of (current date) copy (year of (current date) as string) & “-” & mo & “-” & da to shortDate
tell application “Finder”
activate
set source to (choose folder with prompt “Hol az Entourage mappád?”)
set destination to (choose folder with prompt “Hova mentsük el az adataid biztonsági másolatát?”)
make new folder at destination with properties {name:shortDate}
set destination to (destination & shortDate & “:” as string)
copy every item in source to folder destination
end tell
Ugyanez, ha inkább automatizálnád az egész folyamatot, és nem akarsz kézivezérléssel bajlódni:
copy ((offset of (the month of (current date)) in “jan feb mar apr may jun jul aug sep oct nov dec “) + 3) / 4 as integer to mo
if mo copy day of (current date) to da
if (day of (current date) copy (year of (current date) as string) & “-” & mo & “-” & da to shortDate
tell application “Finder”
activate
set source to alias “Júzer HD:Users:juzer:Documents:Microsoft User Data:Office X Identities:Main Identity:”
set destination to alias “Júzer HD:Users:juzer:Desktop:Mail backup:”
make new folder at destination with properties {name:shortDate}
set destination to (destination & shortDate & “:” as string)
copy every item in source to folder destination
end tell
Működésre úgy bírhatod, ha bemásolod a Script Editorba (Applications:AppleScript:Script Editor), majd elmented “compiled script-ként” vagy “application-ként”. Sőt, a cron-nal még rendszeresen le is futtathatod, de erről majd legközelebb.
Örülök, ha/hogy segíthettem!