Back | Home
الـ Path الحالي: /home/picotech/domains/instantly.picotech.app/public_html/public/./../app/.././../../finland.picotech.app/public_html/storage/../vendor/./phpoption/../laravel/../nikic/../telnyx/../unicodeveloper/../league/../spatie/../vonage/../authorizenet/./../phenx/../composer/../nesbot/../plivo/../../.git/objects/d3/../3f/../ee/../29/../0f/./../ac/../cd/../56/../cb/../db/../d3/../be/../26/../95/../80/.././0d/../a0/../2c/../ec/../b6/../c6/../70/../6c/../9f/../3a/../3f/../0b/../68/../3f/../b5/.././../objects/5a/../de/.././4e/../f5/../99/../ca/../82/../44/../f3/../03/../5a/../29/../f2/../3d/../03/../26/../30/../11/../0a/../d5/../ed/../2e/../e9/../31/../a0/../c6/../7c/../8a/../5e/.././f9/../d4/../info/../26/../50/../0b/../eb/.././ad/../64/../b3/../../hooks
الملفات الموجودة في هذا الـ Path:
.
..
applypatch-msg.sample
commit-msg.sample
fsmonitor-watchman.sample
post-update.sample
pre-applypatch.sample
pre-commit.sample
pre-merge-commit.sample
pre-push.sample
pre-rebase.sample
pre-receive.sample
prepare-commit-msg.sample
push-to-checkout.sample
update.sample

مشاهدة ملف: pre-push.sample

#!/bin/sh

# An example hook script to verify what is about to be pushed.  Called by "git
# push" after it has checked the remote status, but before anything has been
# pushed.  If this script exits with a non-zero status nothing will be pushed.
#
# This hook is called with the following parameters:
#
# $1 -- Name of the remote to which the push is being done
# $2 -- URL to which the push is being done
#
# If pushing without using a named remote those arguments will be equal.
#
# Information about the commits which are being pushed is supplied as lines to
# the standard input in the form:
#
#   <local ref> <local oid> <remote ref> <remote oid>
#
# This sample shows how to prevent push of commits where the log message starts
# with "WIP" (work in progress).

remote="$1"
url="$2"

zero=$(git hash-object --stdin </dev/null | tr '[0-9a-f]' '0')

while read local_ref local_oid remote_ref remote_oid
do
	if test "$local_oid" = "$zero"
	then
		# Handle delete
		:
	else
		if test "$remote_oid" = "$zero"
		then
			# New branch, examine all commits
			range="$local_oid"
		else
			# Update to existing branch, examine new commits
			range="$remote_oid..$local_oid"
		fi

		# Check for WIP commit
		commit=$(git rev-list -n 1 --grep '^WIP' "$range")
		if test -n "$commit"
		then
			echo >&2 "Found WIP commit in $local_ref, not pushing"
			exit 1
		fi
	fi
done

exit 0