Skip to content

Commit a82a40c

Browse files
cjsewellOanh Nguyen
authored andcommitted
Add support for Silverstripe CMS (#709)
* Add support for Silverstripe CMS * Fix typo
1 parent 81d8c4f commit a82a40c

File tree

1 file changed

+43
-0
lines changed

1 file changed

+43
-0
lines changed

recipe/silverstripe.php

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
<?php
2+
3+
require_once __DIR__ . '/common.php';
4+
5+
/**
6+
* Silverstripe configuration
7+
*/
8+
9+
// Silverstripe shared dirs
10+
set('shared_dirs', [
11+
'assets'
12+
]);
13+
14+
// Silverstripe writable dirs
15+
set('writable_dirs', ['assets']);
16+
17+
/**
18+
* Helper tasks
19+
*/
20+
task('silverstripe:build', function () {
21+
return run('{{bin/php}} {{release_path}}/framework/cli-script.php /dev/build');
22+
})->desc('Run /dev/build');
23+
24+
task('silverstripe:buildflush', function () {
25+
return run('{{bin/php}} {{release_path}}/framework/cli-script.php /dev/build flush=all');
26+
})->desc('Run /dev/build?flush=all');
27+
28+
/**
29+
* Main task
30+
*/
31+
task('deploy', [
32+
'deploy:prepare',
33+
'deploy:release',
34+
'deploy:update_code',
35+
'deploy:vendors',
36+
'deploy:shared',
37+
'deploy:writable',
38+
'silverstripe:buildflush',
39+
'deploy:symlink',
40+
'cleanup',
41+
])->desc('Deploy your project');
42+
43+
after('deploy', 'success');

0 commit comments

Comments
 (0)