Skip to content

Commit

Permalink
configureable new larecipe packages location
Browse files Browse the repository at this point in the history
  • Loading branch information
saleem-hadad committed Apr 4, 2019
1 parent aab877d commit 6b82478
Show file tree
Hide file tree
Showing 5 changed files with 54,062 additions and 9 deletions.
26,084 changes: 26,083 additions & 1 deletion publishable/assets/css/app.css

Large diffs are not rendered by default.

27,957 changes: 27,956 additions & 1 deletion publishable/assets/js/app.js

Large diffs are not rendered by default.

22 changes: 19 additions & 3 deletions publishable/config/larecipe.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,9 @@
|
*/

'settings' => [
'auth' => false,
'ga_id' => ''
'settings' => [
'auth' => false,
'ga_id' => ''
],

/*
Expand Down Expand Up @@ -167,5 +167,21 @@
'site_name' => '', // yoursite.disqus.com
]
]
],

/*
|--------------------------------------------------------------------------
| Components and Packages
|--------------------------------------------------------------------------
|
| Once you create a new asset or theme, its directory will be
| published under `larecipe-components` folder. However, If
| you want a different location, feel free to change it.
|
|
*/

'packages' => [
'path' => 'larecipe-components',
]
];
4 changes: 2 additions & 2 deletions src/Commands/AssetCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ protected function replace($search, $replace, $path)
*/
protected function assetPath()
{
return base_path('larecipe-components/'.$this->assetClass());
return base_path($this->relativeAssetPath());
}

/**
Expand All @@ -220,7 +220,7 @@ protected function assetPath()
*/
protected function relativeAssetPath()
{
return 'larecipe-components/'.$this->assetClass();
return config('larecipe.packages.path', 'larecipe-components').'/'.$this->assetClass();
}

/**
Expand Down
4 changes: 2 additions & 2 deletions src/Commands/ThemeCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ protected function replace($search, $replace, $path)
*/
protected function themePath()
{
return base_path('larecipe-components/'.$this->themeClass());
return base_path($this->relativeThemePath());
}

/**
Expand All @@ -169,7 +169,7 @@ protected function themePath()
*/
protected function relativeThemePath()
{
return 'larecipe-components/'.$this->themeClass();
return config('larecipe.packages.path', 'larecipe-components').'/'.$this->themeClass();
}

/**
Expand Down

0 comments on commit 6b82478

Please sign in to comment.