Skip to content

An open-source, self-hostable PaaS alternative to Vercel, Heroku & Netlify that lets you easily deploy static sites, databases, full-stack applications and 360+ one-click services on your own servers.

chore(git): remove pre-commit hooks

peaklabs-deva57092cf4c5c
diff --git a/composer.json b/composer.json
index 1de3a82360..0aeb919586 100644
--- a/composer.json
+++ b/composer.json
@@ -109,11 +109,6 @@
}
},
"scripts": {
- "post-install-cmd": [
- "cp -r 'hooks/' '.git/hooks/'",
- "php -r \"copy('hooks/pre-commit', '.git/hooks/pre-commit');\"",
- "php -r \"chmod('.git/hooks/pre-commit', 0777);\""
- ],
"post-update-cmd": [
"@php artisan vendor:publish --tag=laravel-assets --ansi --force",
"Illuminate\\Foundation\\ComposerScripts::postUpdate"
diff --git a/hooks/pre-commit b/hooks/pre-commit
deleted file mode 100644
index fc96e9766a..0000000000
--- a/hooks/pre-commit
+++ /dev/null
@@ -1,34 +0,0 @@
-#!/bin/sh
-# Detect whether /dev/tty is available & functional
-if sh -c ": >/dev/tty" >/dev/null 2>/dev/null; then
- exec </dev/tty
-fi
-
-# Generate service templates and OpenAPI documentation
-echo "πŸ”„ Generating service templates..."
-php artisan generate:services
-
-echo "πŸ“š Generating OpenAPI documentation..."
-php artisan generate:openapi
-
-# Add the generated files to the commit
-git add templates/service-templates*.json
-git add openapi.json openapi.yaml
-
-echo "βœ… Generated files have been added to the commit"
-
-# Get list of stashed PHP files
-stashed_files=$(git diff --cached --name-only --diff-filter=ACM -- '*.php')
-
-# If there are no stashed PHP files, exit early
-if [ -z "$stashed_files" ]; then
- exit 0
-fi
-
-# Set files variable to only include stashed PHP files
-files="$stashed_files"
-
-$(pwd)/vendor/bin/pint $files -q
-if [ $? -eq 0 ]; then
- git add $files
-fi