Skip to content

Commit

Permalink
[#20] Remove plugin license lines
Browse files Browse the repository at this point in the history
  • Loading branch information
joshuapease committed May 28, 2024
1 parent c7bc861 commit 0290c0d
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 5 deletions.
12 changes: 12 additions & 0 deletions composer-scripts/post-create-project.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,14 @@
replacement: "$projectName",
);

// Replace plugin license keys.
// These are regenerated when viewing the Control Panel
ScriptHelpers::replaceFileText(
filePath: "$cwd/config/project/project.yaml",
pattern: "/ licenseKey: REPLACE[\r\n|\r|\n]/", // Make sure to remove new line too
replacement: "",
);

ScriptHelpers::replaceFileText(
filePath: "$cwd/config/project/siteGroups/805d8826-faed-4186-9b88-f509eb9b07e6.yaml",
pattern: "/Viget Craft Starter/",
Expand All @@ -73,3 +81,7 @@
pattern: "/Viget Craft Starter/",
replacement: "$projectName",
);

/**
* Licence keys
*/
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
"@composer config --unset type",
"@composer update --ignore-platform-reqs",
"@composer dump-autoload -o",
"rm -rf install-scripts "
"rm -rf composer-scripts"
],
"post-root-package-install": [
"@php -r \"file_exists('.env') || copy('.env.example.dev', '.env');\""
Expand Down
8 changes: 4 additions & 4 deletions config/project/project.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,22 +40,22 @@ plugins:
imager-x:
edition: lite
enabled: true
licenseKey: EYY9QQALYS4PXKM10T0D9N67
licenseKey: REPLACE
schemaVersion: 4.0.0
navigation:
edition: standard
enabled: true
licenseKey: ZT0EJAAM7CJWOFKJ45G3LIYY
licenseKey: REPLACE
schemaVersion: 2.1.0
retour:
edition: standard
enabled: true
licenseKey: GZCRRQCSW4G1B3MCWWB9L6K1
licenseKey: REPLACE
schemaVersion: 3.0.12
seomatic:
edition: standard
enabled: true
licenseKey: 19RIJ06TIUTR4H8RSPARFML0
licenseKey: REPLACE
schemaVersion: 3.0.12
vite:
edition: standard
Expand Down

0 comments on commit 0290c0d

Please sign in to comment.