-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
12 changed files
with
2,547 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# editorconfig.org | ||
|
||
root = true | ||
|
||
[*] | ||
indent_style = space | ||
indent_size = 2 | ||
end_of_line = lf | ||
charset = utf-8 | ||
trim_trailing_whitespace = true | ||
insert_final_newline = true | ||
|
||
[*.php] | ||
indent_size = 4 | ||
|
||
[phpcs.xml] | ||
indent_size = 4 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
.github export-ignore | ||
.editorconfig export-ignore | ||
.gitattributes export-ignore | ||
.gitignore export-ignore | ||
.phpcs.xml export-ignore | ||
CHANGELOG.md export-ignore | ||
composer.lock export-ignore |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"$schema": "https://docs.renovatebot.com/renovate-schema.json", | ||
"extends": ["config:base"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
name: Release | ||
on: | ||
workflow_dispatch: | ||
push: | ||
branches: | ||
- master | ||
jobs: | ||
release: | ||
name: Release | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
token: ${{ secrets.OBLAK_BOT_TOKEN }} | ||
- name: Publish a composer package | ||
uses: better-php-actions/publish-composer-package@v1 | ||
with: | ||
package_slug: "whmcs-dev-helper" | ||
package_name: "WHMCS Development Helper" | ||
with_gpg: true | ||
gpg_key: ${{ secrets.GPG_PRIVATE_KEY }} | ||
gpg_passphrase: ${{ secrets.GPG_PASSPHRASE }} | ||
release_token: ${{ secrets.OBLAK_BOT_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
.vscode | ||
vendor |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
<?xml version="1.0"?> | ||
<ruleset name="composer-installer"> | ||
<description>Coding standards for AutoConstructor Composer Plugin</description> | ||
|
||
<arg name="extensions" value="php"/> | ||
<!-- Show sniff codes in all reports, and progress when running --> | ||
<arg value="sp"/> | ||
<!-- Strip the filepaths down to the relevant bit. --> | ||
<arg name="basepath" value="."/> | ||
|
||
<file>.</file> | ||
<exclude-pattern>*/.git*</exclude-pattern> | ||
<exclude-pattern>*/build/*</exclude-pattern> | ||
<exclude-pattern>*/vendor/*</exclude-pattern> | ||
|
||
<rule ref="PSR12"/> | ||
<rule ref="PSR1"/> | ||
|
||
<rule ref="Generic.Formatting.MultipleStatementAlignment"> | ||
<properties> | ||
<property name="maxPadding" value="40" /> | ||
</properties> | ||
</rule> | ||
|
||
<rule ref="PSR1.Files.SideEffects"> | ||
<exclude-pattern>*/tests/bootstrap\.php$</exclude-pattern> | ||
</rule> | ||
|
||
<!-- Fixture method names in the test classes will be in snake_case because of the PHPUnit Polyfills. --> | ||
<rule ref="PSR1.Methods.CamelCapsMethodName.NotCamelCaps"> | ||
<exclude-pattern>*/tests/</exclude-pattern> | ||
</rule> | ||
|
||
</ruleset> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
<div align="center"> | ||
|
||
# WHMCS Dev Helper | ||
|
||
</div> | ||
|
||
Composer module which makes your WHMCS Module development easier 😊 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
#!/usr/bin/env bash | ||
set -e | ||
|
||
find ./modules/ -mindepth 2 -maxdepth 2 -type d | while read -r dir; do | ||
if [ -f "$dir/composer.json" ]; then | ||
printf "Installing Composer modules for: %s\n" "$(basename "$dir")" | ||
composer --working-dir="$dir" install --quiet --no-dev --no-interaction --no-suggest | ||
fi | ||
done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
#!/usr/bin/env bash | ||
set -e | ||
|
||
rm -rf build && mkdir build | ||
|
||
while IFS= read -r MODULE_PATH | ||
do | ||
MODULE_PATH="${MODULE_PATH%%/*}" | ||
mkdir -p "build/$MODULE_PATH" | ||
cp -ar "$MODULE_PATH/" "build/" | ||
done < .manifest | ||
|
||
cp .manifest build/ | ||
find "$(dirname "$(find build/modules -mindepth 2 -maxdepth 3 -type f -name composer.json)")" -name "composer.*" -type f -exec rm -f {} \; | ||
|
||
cp scripts/install build/ | ||
|
||
MODULE_NAME="$(basename "$(pwd)")" | ||
|
||
pushd build | ||
|
||
zip -qr "../$MODULE_NAME.zip" . | ||
|
||
popd && rm -rf build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
{ | ||
"name": "oblak/whmcs-dev-helper", | ||
"description": "Development utilities for WHMCS modules", | ||
"type": "composer-plugin", | ||
"version": "1.0.0", | ||
"license": "MIT", | ||
"authors": [ | ||
{ | ||
"name": "Sibin Grasic", | ||
"email": "[email protected]", | ||
"homepage": "https://oblak.host", | ||
"role": "CTO" | ||
}, | ||
{ | ||
"name": "Contributors", | ||
"homepage": "https://github.com/oblakhost/whmcs-dev-helper/graphs/contributors" | ||
} | ||
], | ||
"support": { | ||
"issues": "https://github.com/oblakhost/whmcs-dev-helper/issues", | ||
"source": "https://github.com/oblakhost/whmcs-dev-helper" | ||
}, | ||
"bin": [ | ||
"bin/module-install", | ||
"bin/pack" | ||
], | ||
"autoload": { | ||
"psr-4": { | ||
"Oblak\\Composer\\Plugin\\": "src" | ||
} | ||
}, | ||
"require": { | ||
"php": "^8.0 | ^8.1", | ||
"composer-plugin-api": "^2.0" | ||
}, | ||
"require-dev": { | ||
"composer/composer": "^2.0", | ||
"oblak/whmcs-stubs": "^7.10" | ||
}, | ||
"minimum-stability": "dev", | ||
"prefer-stable": true, | ||
"extra": { | ||
"class": "\\Oblak\\Composer\\Plugin\\WHMCSDevPlugin" | ||
}, | ||
"scripts": {} | ||
} |
Oops, something went wrong.