Saravanan666/pypi-org huggingface dataset:
Package: precision-recall-gain
Precision-recall-gain curves for PythonFree software: MIT licenseInstallationpip install precision-recall-gainYou can also install the in-development version with:pip install https://github.com/crypdick/precision-recall-gain/archive/master.zipDocumentationhttps://precision-recall-gain.readthedocs.io/DevelopmentTo run all the tests run:toxNote, to combine the coverage data from all the tox environments run:Windowsset PYTEST_ADDOPTS=--cov-append
toxOtherPYTEST_ADDOPTS=--cov-append toxReferences[Precision-Recall-Gain Curves: PR Analysis Done Right (2015) by Peter A. Flach and Meelis Kull](https://papers.nips.cc/paper/2015/file/33e8075e9970de0cfea955afd4644bb2-Paper.pdf)[sklearn-compatible implementation](https://github.com/scikit-learn/scikit-learn/pull/24121) by [Bradley Fowler](https://github.com/bradleyfowler123)[PRG curves](https://www.biostat.wisc.edu/~page/rocprg.pdf) by [David Page](https://www.biostat.wisc.edu/~page/)[Blog post by Bradley Fowler](https://snorkel.ai/improving-upon-precision-recall-and-f1-with-gain-metrics/)[Original implementation](https://github.com/meeliskull/prg) by [Meelis Kull](https://github.com/meeliskull)Changelog0.0.0 (2021-03-20)First release on PyPI.
Package: precli
Precli is the core of the GitHub App Precaution and also a command line interface to demonstate its functionality.Quick StartTo install precli:pip install precliRun precli on a single test example:precli tests/unit/rules/python/stdlib/examples/hmac_timing_attack.pyRun precli on a single test example, showing results in SARIF format:precli tests/unit/rules/python/stdlib/examples/hmac_timing_attack.py --jsonRun precli on a single test example, showing results in plain format:precli tests/unit/rules/python/stdlib/examples/hmac_timing_attack.py --plainRun precli on a single test example, showing results in markdown format:precli tests/unit/rules/python/stdlib/examples/hmac_timing_attack.py --markdownRun precli against all the python test examples:precli -r tests/unit/rules/python/stdlib/examples/Run precli against an entire GitHub repository:precli -r https://github.com/securesauce/precliRun precli against an entire GitHub repository and output the results in markdown format to Gist.
Note: this requires a GITHUB_TOKEN environment variable set to a valid GitHub token value:precli -r https://github.com/securesauce/precli --markdown --gist
Package: precnumber
Float Point Arithmetic is ImpreciseMany new python coders will be frustrated at the seemingly nonsensical way the language handles floating point numbers: even operations as simple as 0.1 + 0.2 should be easy to compute, right? Turns out floating point number storage yields many issues, and many minds smarter than me decided imprecision is better than storage and processing cost. The idea of this project is to invert that notion, storing floating point numbers as ratios.0.1+0.2==0.3#TrueNumber.parse("0.1")+Number.parse("0.2")==Number.parse("0.3")#FalseNumber.parse("0.92")/Number.parse("245")#23/6125Operation ExamplesThis library provides all basic arithmetic operations needed for numbers: addition, substration, multiplication, and division, as well as helper functions such as floor, ceil, opposite, inverse, and the equality operator.Number.parse("3.2")+Number.parse("4.7")#79/10Number.parse("9.21")-Number.parse("18.45")#231/-25Number.parse("1.6")*Number.parse("2.4")#96/25Number.parse("1.4")/Number.parse("3.3")#14/33Number.parse("1.5")==Number(3,2)#TrueNumber.parse("3.4").floor()#3Number.parse("0.2").ceil()#1Number.parse("-3").opposite()#3Number.parse("0.5").inverse()#2
Package: precog
# precog
For preventing your crimes, before you can commit them.InstallationTo install from PyPI, runpip install precog. To install the
githook, runprecog. This will try to write to your pre-commit file
(.git/hooks/pre-commit), and will abort if it already exists, so
move or remove it if you want to use precog.UsageOnce you have precog installed, your commits will be checked that they
conform. By default it will abort a commit if any offlake8,isortoreslintdo not exit cleanly, but will make no effort to fix any
problems. The pre-commit file contains the default values for the
options, but you can override the behaviour with environment variables
when committing, or if you can edit the defaults in the pre-commit file.Examples:To skip all checking altogether, eg for a work-in-progress commit:`STRICT=""git commit-m"wip" `this will still print issues, but will let the commit complete.To skip just isort:`ISORT_STRICT=""git commit-m"wip - todo: fix imports" `TheISORT_FORCEoptionThis one is a bit mad. Becauseisortknows how to fix the problems
it finds (whileflake8andeslintdo not), rather than complaining
at you, this option tellsprecogto tweak your changed files to
conform to theisortchecking. Though this is a bit scary, so is
disabled by default.In the case where all of a file is staged for commit, this is fairly
straight-forward:precogwill just runisorton the file and then
re-add it to include those changes in the commit. But if only part of
file is staged, then we don’t want to add the whole file. So we make
use of the-koption togit stashto stash only the unstaged
changes. We then runisort, add the file, then pop the stash.There are almost certainly edge-cases in this, and if it mucks up your
commit, then I am sorry. Out of your sadness, a PR/issue can rise to
make it not happen again.Integration witheslintTo lint your JavaScript, precog will invoke eslint on any changed.jsfiles. Because it is not a Python dependency, installing precog
makes no attempt to install eslint, but will try to find it atnode_modules/.bin/eslint. If it doesn’t find it, it will assume it
is installed globally. You can set theESLINT_PATHenvironment
variable if this doesn’t find it - if so you may want to set it as a
default in your pre-commit file.
Package: pre-commit-ci-config
pre-commit-ci-configvalidation forpre-commit.ciconfigurationinstallationpipinstallpre-commit-ci-configapipre_commit_ci_config.SCHEMAacfgvschema.the expected input to this schema is the loaded top-level pre-commit
configuration.>>>importcfgv>>>frompre_commit.clientlibimportload_config>>>frompre_commit_ci_configimportSCHEMA>>>cfg=load_config('.pre-commit-config.yaml')>>>cfg=cfgv.validate(cfg,SCHEMA)>>>cfg=cfgv.apply_defaults(cfg,SCHEMA)check-pre-commit-ci-configa commandline tool to validate the configuration$check-pre-commit-ci-config.pre-commit-config.yaml$as a pre-commit hookSeepre-commitfor instructionsSample.pre-commit-config.yaml:-repo:https://github.com/pre-commit-ci/pre-commit-ci-configrev:v1.6.1hooks:-id:check-pre-commit-ci-config
Package: pre-commit-commit-msg-hooks
A collection of checks for the commit-msg for pre-commit.The hooks in this repository makes it possible to check for the
rules defined byhttps://commit.style/.:Commit message style guide for Git

The first line of a commit message serves as a summary.  When displayed
on the web, it's often styled as a heading, and in emails, it's
typically used as the subject.  As such, you should capitalize it and
omit any trailing punctuation.  Aim for about 50 characters, give or
take, otherwise it may be painfully truncated in some contexts.  Write
it, along with the rest of your message, in the imperative tense: "Fix
bug" and not "Fixed bug" or "Fixes bug".  Consistent wording makes it
easier to mentally process a list of commits.

Oftentimes a subject by itself is sufficient.  When it's not, add a
blank line (this is important) followed by one or more paragraphs hard
wrapped to 72 characters.  Git is strongly opinionated that the author
is responsible for line breaks; if you omit them, command line tooling
will show it as one extremely long unwrapped line.  Fortunately, most
text editors are capable of automating this.

:qAnd then some.All hooks can be used from the command line as well.UsageConfigurehttps://pre-commit.comfor checking compliance withhttps://commit.stylerepos:
  - repo: ../pre-commit-commit-msg-hooks
    rev: 0.1.0
    hooks:
      - id: check-description-max-length
      - id: check-second-line-empty
      - id: check-summary-capitalized
      - id: check-summary-imperative
      - id: check-summary-max-length
      - id: check-summary-punctuationAvailable Hookscheck-description-max-lengthCheck lines in the description are not more than 72 characters.check-second-line-emptyCheck the second line of the commit message is blank.check-summary-conjunctionCheck the summary does not contain conjugated sentences.Searches for occurrences of ‘and’, ‘nor’, and ‘or’ and fails if found.check-summary-imperativeCheck the summary starts with a verb.Searches a wordlist comprised of > 6000 verbs. The check fails
if not found.NoteThe wordlist is comprised of different lists but as terminology
evolves, the list is incomplete. If you find anything missing,
please amendverbs-wordlist.txtand issue a Pull Request.check-summary-capitalizedCheck the summary starts with a capital letter.check-summary-max-lengthCheck the summary is not more than 54 characters.Notehttps://commit.stylesaysAim for about 50 characters, give
or take. 54 gives a little more lee-way.check-summary-min-lengthCheck the summary is at least 6 characters.check-summary-punctuationCheck the summary does not end with punctuation.Checks the last character againststring.punctuationand fails on match.
Package: pre-commit-config-shellcheck
pre-commit-config-shellcheck is a tool for checking entry points in the pre-commit config with ShellCheck.ContentsInstallationUsageUsage as a pre-commit hookUsage as GitHub actionContributingLicensingContactsInstallationIn order to use the tool you should first clone it from the source:$gitclonehttps://github.com/Anadea/pre-commit-config-shellcheck.gitThen you should install project dependencies with$python./setup.pyinstallor$pipinstallpre-commit-config-shellcheckThe installation is done and as simple as that.UsageTo run the program you should start it from the terminal and provide a config file to check:$pre_commit_config_shellcheck.py.pre-commit-config.yamlYou could change a default ShellCheck call with directory access with the-sor--shellcheckargument:$pre_commit_config_shellcheck.py.pre-commit-config.yaml-s/bin/shellcheckThe output from tool usage is sent to the stdout or stderr depending on the operation result.Usage as a pre-commit hookAlso, it can be used as apre-commithook out of the box. Just add it to yours.pre-commit-config.yaml:-repo:"https://github.com/Anadea/pre-commit-config-shellcheck"rev:"0.3.4"hooks:-id:"pre-commit-config-shellcheck"Usage as GitHub actionAlso, it can be used as aGitHub actionout of the box. Just add it to yours workflow:-name:"pre-commit-config-shellcheck"uses:"actions/pre-commit-config-shellcheck@0.3.4"id:"pre-commit-config-shellcheck"with:config:".pre-commit-config.yaml"ContributingFork itInstallGNU MakeInstall and configurepyenvandpyenv-virtualenv pluginInstall and configuredirenvCreate environment config from the examplecp.env.example.envInstall development dependencies:makeinstallCreate your fix/feature branch:gitcheckout-bmy-new-fix-or-featureCheck code style and moreover:makecheckRun tests:maketestPush to the branch:gitpushoriginmy-new-fix-or-featureCreate a new Pull RequestLicensingpre-commit-config-shellcheck uses the MIT license. Please check the MIT-LICENSE file for more details.ContactsProject Website:https://github.com/Anadea/pre-commit-config-shellcheck/Author: AnadeaFor contributors list see CONTRIBUTORS file.
Package: precommit-diffcheck
precommit-message-perservationThis is a simple library that makes it easier to code hooks forpre-committhat validate commit messages that preserve the commit message on failure.
In other words, if the user writes a long commit message and your pre-commit hook tells them the message is bad, they won't have their message entirely thrown away.HackingYou'll want to install the developer dependencies:pip install -e .[develop]This will includenose2, which is the test runner of choice. After you make modifications you can run tests withnose2When you're satisfied you'll want to update the version number and do build-and-upload:python setup.py sdist bdist_wheel
twine upload dist/* --verbose
Package: precommit-hook
<a href="https://asciinema.org/a/135255" target="_blank"><img src="https://asciinema.org/a/135255.png" height="400" /></a># precommit-hook[![Codacy Badge](https://api.codacy.com/project/badge/Grade/095d63a592e74b239b28b5e19e689709)](https://www.codacy.com/app/abtcolns/precommit-hook?utm_source=github.com&utm_medium=referral&utm_content=collin5/precommit-hook&utm_campaign=badger)[![Build Status](https://travis-ci.org/collin5/precommit-hook.svg?branch=master)](https://travis-ci.org/collin5/precommit-hook)[![Coverage Status](https://coveralls.io/repos/github/collin5/precommit-hook/badge.svg?branch=master)](https://coveralls.io/github/collin5/precommit-hook?branch=master)[![PyPI version](https://badge.fury.io/py/precommit-hook.svg)](https://badge.fury.io/py/precommit-hook)Auto check the quality of your python code before you ship it## Getting startedThese instructions will show you how to install and use the application### Installation```pip install precommit-hook```### UsageIn your project folder, just do```precommit.hook```Your code will now be automatically checked on every commit.## License[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)This project is licensed under MIT license. see the ![LICENSE](LICENSE) file for details## AuthorsSee list of <a href="https://github.com/collin5/precommit-hook/graphs/contributors">contributors</a> who participated in this project.## Credits<ul><li><a href="https://github.com/collin5">Collins Abitekaniza </a></li><li><a href="https://github.com/andela-engmkwalusimbi">Walusimbi Mahad </a></li></ul>
Package: pre-commit-hook-ensure-sops
pre-commit-hook-ensure-sopsApre-commithook to ensure that users don't
accidentally check-in unencrypted files into a repository that usessopsto safely store encrypted secrets.By default, any file with the wordsecretin its path is required to
be encrypted withsops. This means any files under a directory
namedsecretare also required to be encrypted. If you want to exempt
specific files or directories from this requirement in your repository,
use theexcludeoption in your.pre-commit-config.yaml. When pushing
secrets to a repo, better safe than sorry :)InstallationAdd this to your.pre-commit-config.yaml:-repo:https://github.com/yuvipanda/pre-commit-hook-ensure-sopsrev:v1.0hooks:-id:sops-encryption# Uncomment to exclude all markdown files from encryption# exclude: *.\.md
Package: pre_commit_hook_poetry_auto_semver
pre-commit-hook-poetry-auto-semverA pre-commit hook to auto-increment the poetry project's version when source code changes.Using pre-commit-hook-poetry-auto-semverAdd this to your.pre-commit-config.yaml-repo:https://github.com/ipear3/pre-commit-hook-poetry-auto-semverrev:'0.0.1'hooks:-id:poetry-auto-semverHooks availablepoetry-auto-semverCheck whether the poetry project's version is greater than the current git tag version.
If the poetry project's version is less than or equal to the current git tag version, increment the project's patch version.
If the poetry project's version is greater than the current git tag version, the developer has already incremented the project's version.Pre-configured to run onpushaffectingfiles: src.*|.*py|poetry.lock|pyproject.toml.Developmentpoetry installpre-commit install
Package: pre-commit-hooks-changelog
pre-commit-hooks-changeloggenerate a markdown changelog from folder of yaml filesUsing pre-commit-hooks-changelog with pre-commitAdd this to your.pre-commit-config.yaml-   repo: https://github.com/chrysa/pre-commit-hooks-changelog
    rev: v0.1.0  # Use the ref you want to point at
    hooks:
    -   id: generate-changelog
        files: 'changelog/.*(?<!\.yaml|.yml)$'Options--output-filedefine changelog outpout--changelog-foldersource folder of changelogs--rebuildrebuild changelog see belowRebuild optionsallrebuild changelog from scratchversionsrebuild changelog for each versionlatestrebuild latest changeloghomerebuild changelog file on repo rootStandalonepip install pre-commit-hooks-changelogChangelog
Package: pre-commit-hooks-django
pre-commit-hooks-djangoSome useful hooks for Django developmentSee also:https://github.com/pre-commit/pre-commitUsing pre-commit-hooks-django with pre-commitAdd this to your.pre-commit-config.yaml-repo:https://github.com/ecugol/pre-commit-hooks-djangorev:v0.4.0# Use the ref you want to point athooks:-id:check-untracked-migrations# Optional, if specified, hook will work only on these branches# otherwise it will work on all branchesargs:["--branches","main","other_branch"]-id:check-unapplied-migrations-id:check-absent-migrations-id:po-location-format# Mandatory, select one of the following options:# file: show only the file path as location# never: remove all locationsargs:["--add-location","file"]Hooks availablecheck-untracked-migrationsForbids commit if untracked migrations files are found (e.g.*/migrations/0001_initial.py)Options:--branches

Optional, if specified, hook will work only on these branches
otherwise it will work on all branchescheck-unapplied-migrationsWARNING: USE ONLY WITH DJANGO > v3.1Check for unapplied migrations with manage.py migrate --checkcheck-absent-migrationsCheck for absent migrations with manage.py makemigrations --check --dry-runpo-location-formatChanges location format for .po filesOptions:--add-location [file, never]

Mandatory, select one of the following options:

file: show only the file path as location
never: remove all locations
Package: pre-commit-k8s
pre-commit-k8sAn additional hook that can be used as a hook withpre-committo validate Kubernetes objects.Current hooks:kubernetes-secrets- check if secrets are pushedUsageInstall pre-commitpip install pre-commitSetup the.pre-commit-config.yamlconfig file:# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
repos:
- repo: https://github.com/zwennesm/pre-commit-k8s
  rev: master
  hooks:
  - id: pre-commit-k8s
    entry: pre-commit-k8sInstall the pre-commit hooks:pre-commit installLocal installAlternativelypre-commit-k8scan be installed locally for testing.pip install pre-commit-k8spre-commit-k8sexpects a list of files to be passed to it:➜ pre-commit-k8s LICENCE                                          
2020-12-07 14:50:06,636 - INFO - Validating the following rules:
2020-12-07 14:50:06,636 - INFO - ✓ Kubernetes Secret check
2020-12-07 14:50:06,636 - INFO - No validation errors foundRules can also be excluded:➜ pre-commit-k8s --exclude kubernetes-secrets kubernetes-secret.yaml 
2020-12-07 14:52:08,569 - WARNING - No rules activated to validate files
2020-12-07 14:52:08,569 - INFO - No validation errors found
Package: pre-commit-keyword-checker
Pre-commit Keyword Checker 📝✅Welcome to the Pre-commit Keyword Checker! This handy pre-commit hook checks for specified keywords in the files being committed. It offers file exclusion options and customizable keyword lists to make sure your commits stay keyword-free!Installation 🛠️Install the pre-commit package if you haven't already:pip install pre-commit-keyword-checkerAdd the following content to your project's.pre-commit-config.yamlfile, replacingyourusernamewith your GitHub username:repos:-repo:https://github.com/AliYmn/pre-commit-keyword-checkerrev:masterhooks:-id:check-keywordsargs:["--keywords","KEYWORD1","KEYWORD2","--exclude-files","file2.txt"]Replace KEYWORD1, KEYWORD and file1.txt with your desired keywords and excluded files.Install the pre-commit hook to your project:pre-commit installAnd you're all set! 🎉UsageOnce installed, the keyword-checking pre-commit hook will be run whenever you commit changes in your project. If any of the specified keywords are found in the files being committed (excluding the specified files), the commit will be blocked, and the script will display a list of keyword errors.You can also run the pre-commit hook manually:pre-commit run check-keywordsAnd you're good to go! 🚀Configuration--keywords: A list of keywords to search for in the files being committed. If this argument is not provided or left empty, the script will exit without checking the files.--exclude-files: A list of files to exclude from the keyword check.
Package: pre-commit-license-headers
Pre-Commit License HeadersApre-commithook to check the license
headers of your source code files.At present, it only supports checking files that use hash mark#comment syntax. For
more info, seeSupported file types.UsageAdd an entry like this to your.pre-commit-config.yaml-repo:https://github.com/johannsdg/pre-commit-license-headersrev:v0.1.0# Use the ref you want to point athooks:-id:check-license-headersargs:-"--template"-|Copyright (c) [YEARS] [OWNER]Use of this source code is governed by a BSD-3-clause license that canbe found in the LICENSE file or at https://opensource.org/licenses/BSD-3-Clause-"--owner=ThePre-CommitLicenseHeadersAuthors"(Note that the template provided above is the default, so if you are using BSD-3-clause
and are happy with the wording, you can skip--templateand just provide--owner)[YEARS]and[OWNER]are optional variables in the header template. If used, they
will automatically be replaced with:[YEARS]: a regular expression that accepts various combinations of years, such as:Single years, such as '2019' or '2021'Year ranges, such as '2018-2020'Combinations, such as '2014, 2016-2018, 2020'Note that ranges ending in '-present' are not supported[OWNER]: the contents of the--ownerargumentNote that--owneris optional unless the template uses the[OWNER]variableSupported file typesPre-Commit License Headerssupports checking file types that use hash mark#comment
syntax.This includes:pythonshellyamltomlplain-textetcFor the list of file types checked by default, seefile_types.pyYou may override the default
list with your own via the-for--file-typeoption (may be specified multiple
times).File types are determined using theidentifylibrary. For more information about file types, see:https://pre-commit.com/#filtering-files-with-typesAs a standalone packagePre-Commit License Headersis also available as a standalone package.To install via pip:pip install pre-commit-license-headersYou may also clone this repo and install viapoetry:poetry install --no-devEither installation option will place thecheck-license-headersexecutable in your
environment's configured binary directory (e.g., '.venv/bin')To use:foo@bar:~$check-license-headers--helpusage: check-license-headers [-h] [-d] [--list-file-types] [-s] [-f FILE_TYPE][-o COPYRIGHT_OWNER] -t TEMPLATE[FILE [FILE ...]]Checks if file headers match a provided template.positional arguments:FILEoptional arguments:-h, --help            show this help message and exit-d, --debug--list-file-types     lists all text file types and exits-s, --summary         prints a summary after checking the files-f FILE_TYPE, --file-type FILE_TYPEmay be specified multiple times-o COPYRIGHT_OWNER, --owner COPYRIGHT_OWNER-t TEMPLATE, --template TEMPLATE