Skip to content

kaiqueBellmont/GitHook-Arqmeds

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 

Repository files navigation

Githook Arqmeds

This is a precommit hook that calls an API as a service, which validates the modified files to meet the PEP8 requirements.

Texto alternativo

Project installation:

  • 1: Download: Just Click me
  • OR
  • 1: Clone the project or download the folder with the following command:
  • Clone the project:
git clone https://github.com/kaiqueBellmont/GitHook-Arqmeds.git

Important:

Extract the hook folder to the root of the project.

e.g:

root 
   |___ folder1
   |___ folder2
   |___ file...
   |___ hook/...

In The ROOT:

install (venv):

pip install  -r hook/requeriments.txt

install (poetry):

poetry add click requests && poetry lock

requeriments:

python = "^3.10"
click = "^8.1.3"
requests = "^2.29.0"

Create pre-commit-file:

cd hook/cli/ && python3  cli.py && cd ../..

This will create a pre-commit file inside the root/.git/hooks folder.

Pre-commit is already installed.

But to make it work, you need to install at least gitHookAPI:

git clone https://github.com/kaiqueBellmont/githookAPI.git

GitHookAPI:

Let's go to the next README

OpenAIWorker:

Let's go to the last one README

Important:

The HOOK only works for modified files already added to the git index and .py!!!

E.G:

git add filename.py 

Now any .py file you try to commit will go through pre-commit

git commit -m file.py "my message"

or by ide also works. (tested in pycharm)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages