Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 113 lines (97 sloc) 3.319 kb
db24d77 @taylorotwell merge paths into a single place.
taylorotwell authored
1 <?php
bc2e54b @taylorotwell cleaning up some files.
taylorotwell authored
2 /**
3 * Laravel - A PHP Framework For Web Artisans
4 *
5 * @package Laravel
681f80e @taylorotwell update change log
taylorotwell authored
6 * @version 3.2.3
bc2e54b @taylorotwell cleaning up some files.
taylorotwell authored
7 * @author Taylor Otwell <taylorotwell@gmail.com>
8 * @link http://laravel.com
9 */
db24d77 @taylorotwell merge paths into a single place.
taylorotwell authored
10
34cb9a0 @taylorotwell move 'is' method to the str class where it belongs.
taylorotwell authored
11 /*
12 |----------------------------------------------------------------
13 | Application Environemtns
14 |----------------------------------------------------------------
15 |
16 | Laravel takes a dead simple approach to environments, and we
17 | think you'll love it. Just specify which URLs belongs to a
18 | given environment, and when you access your application
19 | from a URL matching that pattern, we'll be sure to
20 | merge in that environment's configuration files.
21 |
22 */
23
24 $environments = array(
25
1d7c27c @taylorotwell tweak local environment defaults.
taylorotwell authored
26 'local' => array('http://localhost*', '*.dev'),
34cb9a0 @taylorotwell move 'is' method to the str class where it belongs.
taylorotwell authored
27
28 );
29
db24d77 @taylorotwell merge paths into a single place.
taylorotwell authored
30 // --------------------------------------------------------------
31 // The path to the application directory.
32 // --------------------------------------------------------------
97fcea1 @taylorotwell cleaned up paths.
taylorotwell authored
33 $paths['app'] = 'application';
db24d77 @taylorotwell merge paths into a single place.
taylorotwell authored
34
35 // --------------------------------------------------------------
5792546 @taylorotwell added tests_path constant and added tests to bundle publisher.
taylorotwell authored
36 // The path to the Laravel directory.
37 // --------------------------------------------------------------
97fcea1 @taylorotwell cleaned up paths.
taylorotwell authored
38 $paths['sys'] = 'laravel';
5792546 @taylorotwell added tests_path constant and added tests to bundle publisher.
taylorotwell authored
39
40 // --------------------------------------------------------------
db24d77 @taylorotwell merge paths into a single place.
taylorotwell authored
41 // The path to the bundles directory.
42 // --------------------------------------------------------------
97fcea1 @taylorotwell cleaned up paths.
taylorotwell authored
43 $paths['bundle'] = 'bundles';
db24d77 @taylorotwell merge paths into a single place.
taylorotwell authored
44
45 // --------------------------------------------------------------
46 // The path to the storage directory.
47 // --------------------------------------------------------------
97fcea1 @taylorotwell cleaned up paths.
taylorotwell authored
48 $paths['storage'] = 'storage';
db24d77 @taylorotwell merge paths into a single place.
taylorotwell authored
49
50 // --------------------------------------------------------------
51 // The path to the public directory.
52 // --------------------------------------------------------------
2b88c78 @taylorotwell simplified the paths.php file.
taylorotwell authored
53 $paths['public'] = 'public';
db24d77 @taylorotwell merge paths into a single place.
taylorotwell authored
54
0c8c671 @taylorotwell make the paths file more friendly.
taylorotwell authored
55 // *-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-
56 // END OF USER CONFIGURATION. HERE BE DRAGONS!
57 // *-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-
58
db24d77 @taylorotwell merge paths into a single place.
taylorotwell authored
59 // --------------------------------------------------------------
99e634d @taylorotwell better organize paths file.
taylorotwell authored
60 // Change to the current working directory.
61 // --------------------------------------------------------------
62 chdir(__DIR__);
63
64 // --------------------------------------------------------------
65 // Define the directory separator for the environment.
66 // --------------------------------------------------------------
67 if ( ! defined('DS'))
68 {
69 define('DS', DIRECTORY_SEPARATOR);
70 }
71
72 // --------------------------------------------------------------
73 // Define the path to the base directory.
74 // --------------------------------------------------------------
75 $GLOBALS['laravel_paths']['base'] = __DIR__.DS;
76
77 // --------------------------------------------------------------
db24d77 @taylorotwell merge paths into a single place.
taylorotwell authored
78 // Define each constant if it hasn't been defined.
79 // --------------------------------------------------------------
80 foreach ($paths as $name => $path)
81 {
711d60a @taylorotwell dont override paths if they are already set in bootstrap.
taylorotwell authored
82 if ( ! isset($GLOBALS['laravel_paths'][$name]))
83 {
84 $GLOBALS['laravel_paths'][$name] = realpath($path).DS;
85 }
97fcea1 @taylorotwell cleaned up paths.
taylorotwell authored
86 }
87
62072e5 @sparksp PHPDoc fixes
sparksp authored
88 /**
89 * A global path helper function.
90 *
91 * <code>
92 * $storage = path('storage');
93 * </code>
94 *
95 * @param string $path
96 * @return string
97 */
97fcea1 @taylorotwell cleaned up paths.
taylorotwell authored
98 function path($path)
99 {
100 return $GLOBALS['laravel_paths'][$path];
101 }
102
62072e5 @sparksp PHPDoc fixes
sparksp authored
103 /**
104 * A global path setter function.
105 *
106 * @param string $path
107 * @param string $value
108 * @return void
109 */
97fcea1 @taylorotwell cleaned up paths.
taylorotwell authored
110 function set_path($path, $value)
111 {
112 $GLOBALS['laravel_paths'][$path] = $value;
db24d77 @taylorotwell merge paths into a single place.
taylorotwell authored
113 }
Something went wrong with that request. Please try again.