File tree 2 files changed +24
-0
lines changed
2 files changed +24
-0
lines changed Original file line number Diff line number Diff line change 57
57
],
58
58
"post-update-cmd" : [
59
59
" DrupalProject\\ composer\\ ScriptHandler::createRequiredFiles"
60
+ ],
61
+ "post-create-project-cmd" : [
62
+ " DrupalProject\\ composer\\ ScriptHandler::removeInternalFiles"
60
63
]
61
64
},
62
65
"extra" : {
Original file line number Diff line number Diff line change @@ -60,6 +60,27 @@ public static function createRequiredFiles(Event $event) {
60
60
}
61
61
}
62
62
63
+ /**
64
+ * Remove project-internal files after create project.
65
+ */
66
+ public static function removeInternalFiles (Event $ event ) {
67
+ $ fs = new Filesystem ();
68
+
69
+ // List of files to be removed.
70
+ $ files = [
71
+ '.travis.yml ' ,
72
+ 'LICENSE ' ,
73
+ 'README.md ' ,
74
+ 'phpunit.xml.dist ' ,
75
+ ];
76
+
77
+ foreach ($ files as $ file ) {
78
+ if ($ fs ->exists ($ file )) {
79
+ $ fs ->remove ($ file );
80
+ }
81
+ }
82
+ }
83
+
63
84
/**
64
85
* Checks if the installed version of Composer is compatible.
65
86
*
You can’t perform that action at this time.
0 commit comments