![Oracle Drags Its Feet in the JavaScript Trademark Dispute](https://cdn.sanity.io/images/cgdhsj6q/production/919c3b22c24f93884c548d60cbb338e819ff2435-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
git-hooks
is an utility for managing and running project git hooks for nodejs projects.
It has zero dependecies and easy to use.
Just install git-hooks and it will run your hooks when a hook is called by git.
Hooks are little scripts you can place in $GIT_DIR/hooks
directory to trigger action at certain points.
They are very powerful and helpful.
You can do a lot of things with them:
Note. When you use git-hooks
, you should not modify $GIT_DIR/hooks
directory manually because git-hooks
will do it for you.
Install git-hooks
in your project.
npm install git-hooks --save-dev
To keep things organized, git-hooks
looks for scripts in sub-directories named after the git hook name.
All these sub-directories should be stored in .githooks
directory in the project root.
Let's create some dummy pre-commit hook.
mkdir -p .githooks/pre-commit
echo -e '#!/usr/bin/env node' "\nconsole.log('hi!');" > .githooks/pre-commit/hello.js
chmod +x .githooks/pre-commit/hello.js
Then just try to commit and see how things are rolling.
git add .githooks package.json
git commit -m "Add git-hooks"
See also hooks examples.
It's worth to mention that our library checks for gitignore rules while executing scripts in .githooks/ directories.
FAQs
A tool to manage project Git hooks
The npm package git-hooks receives a total of 4,873 weekly downloads. As such, git-hooks popularity was classified as popular.
We found that git-hooks demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.