File::HomeDir::Darwin::Cocoa - Find your home and other directories on Darwin (OS X)
This module provides Darwin-specific implementations for determining
common user directories using Cocoa API through
the Mac::SystemDirectory manpage. In normal usage this module will always be
used via the File::HomeDir manpage.
Theoretically, this should return the same paths as both of the other
Darwin drivers.
Because this module requires the Mac::SystemDirectory manpage, if the module
is not installed, the File::HomeDir manpage will fall back to the File::HomeDir::Darwin manpage.
use File::HomeDir;
# Find directories for the current user
$home = File::HomeDir->my_home; # /Users/mylogin
$desktop = File::HomeDir->my_desktop; # /Users/mylogin/Desktop
$docs = File::HomeDir->my_documents; # /Users/mylogin/Documents
$music = File::HomeDir->my_music; # /Users/mylogin/Music
$pics = File::HomeDir->my_pictures; # /Users/mylogin/Pictures
$videos = File::HomeDir->my_videos; # /Users/mylogin/Movies
$data = File::HomeDir->my_data; # /Users/mylogin/Library/Application Support
Copyright 2009 - 2011 Adam Kennedy.
Copyright 2017 - 2020 Jens Rehsack
|