Skip to content

Commit f73bec6

Browse files
committed
Merge branch 'release/1.7.1'
2 parents e0a2111 + 6e8ea2c commit f73bec6

File tree

5 files changed

+13
-12
lines changed

5 files changed

+13
-12
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
# v1.7.1
2+
## 06/14/2023
3+
4+
1. [](#improved)
5+
* Removed platform-config [#81](https://github.com/getgrav/grav-plugin-devtools/pull/81)
6+
17
# v1.7.0
28
## 02/15/2023
39

blueprints.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name: DevTools
22
slug: devtools
33
type: plugin
4-
version: 1.7.0
4+
version: 1.7.1
55
description: Plugin and Theme scaffolding utilities
66
icon: cogs
77
author:

classes/DevToolsCommand.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -308,11 +308,16 @@ protected function validate(string $type, $value)
308308
{
309309
switch ($type) {
310310
case 'name':
311-
// Check If name
311+
// Check if name is empty
312312
if ($value === null || trim($value) === '') {
313313
throw new \RuntimeException('Name cannot be empty');
314314
}
315315

316+
// Check if name starts with a numeric character
317+
if (is_numeric($value[0])) {
318+
throw new \RuntimeException('Name must start with an alphabetic character (A-Z, a-z)');
319+
}
320+
316321
if (!$this->options['offline']) {
317322
// Check for name collision with online gpm.
318323
if (false !== $this->gpm->findPackage($value)) {

components/plugin/blank/composer.json.twig

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,5 @@
2121
"Grav\\Plugin\\{{ component.name|camelize }}\\": "classes/"
2222
},
2323
"classmap": ["{{ component.name|hyphenize }}.php"]
24-
},
25-
"config": {
26-
"platform": {
27-
"php": "7.1.3"
28-
}
2924
}
3025
}

components/plugin/flex/composer.json.twig

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,5 @@
2121
"Grav\\Plugin\\{{ component.name|camelize }}\\": "classes/"
2222
},
2323
"classmap": ["{{ component.name|hyphenize }}.php"]
24-
},
25-
"config": {
26-
"platform": {
27-
"php": "7.1.3"
28-
}
2924
}
3025
}

0 commit comments

Comments
 (0)