Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the '10.7: Quickly unhide the User Library improved' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
10.7: Quickly unhide the User Library improved
Authored by: robJ on Oct 20, '11 09:29:41AM

I run this AppleScript from the FastScripts menu but it could easily be run by other script runners. It will toggle the visibility of ~/Library. I rarely have Terminal running so this is much quicker for me.

set lib_folder to path to library folder from user domain
set lib_visible to (visible of (info for lib_folder))

if lib_visible is false then
do shell script "chflags nohidden ~/Library/"
else
do shell script "chflags hidden ~/Library/"
end if

try
tell application "Finder" to update front window
end try



[ Reply to This | # ]
10.7: Quickly unhide the User Library improved
Authored by: Zettt on Oct 23, '11 02:35:38AM

I’ve changed this script slightly, because the AppleScript method to find an item’s “visibile” state was running very very slowly. I’m using a shell script instead.

set lib_visible to do shell script "ls -Ol ~ | grep \"Library\"" as text
 
if lib_visible contains "hidden" then
I've also added this script to my LaunchBar/Alfred/Keyboard Maestro script repository if you don't mind.

[ Reply to This | # ]
10.7: Quickly unhide the User Library improved
Authored by: robJ on Oct 25, '11 06:13:04AM

Nope, I don't mind at all and I've adopted your mod.

Edited on Oct 25, '11 06:17:53AM by robJ



[ Reply to This | # ]