8000 Merge pull request #1 from gabriel-logan/main · Multiform-Validator/python@1ec5924 · GitHub
[go: up one dir, main page]

Skip to content

Commit 1ec5924

Browse files
Merge pull request #1 from gabriel-logan/main
chore: Add GitHub workflows for Python PR check and publishing
2 parents a0d4dbc + 8583693 commit 1ec5924

File tree

6 files changed

+304
-0
lines changed

6 files changed

+304
-0
lines changed

.github/FUNDING.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# These are supported funding model platforms
2+
3+
github: [gabriel-logan] # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
4+
patreon: # Replace with a single Patreon username
5+
open_collective: # Replace with a single Open Collective username
6+
ko_fi: # Replace with a single Ko-fi username
7+
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
8+
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
9+
liberapay: # Replace with a single Liberapay username
10+
issuehunt: # Replace with a single IssueHunt username
11+
lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cloud-foundry
12+
polar: # Replace with a single Polar username
13+
buy_me_a_coffee: gabriellogan
14+
custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']

.github/workflows/python-pr-check.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Python Pull Request Check
2+
3+
on:
4+
push:
5+
branches: [ main ]
6+
7+
pull_request:
8+
branches: [ main ]
9+
10+
# Allows you to run this workflow manually from the Actions tab
11+
workflow_dispatch:
12+
13+
jobs:
14+
checking-pr:
15+
runs-on: ubuntu-latest
16+
17+
steps:
18+
- uses: actions/checkout@v2
19+
20+
- name: Set up Python
21+
uses: actions/setup-python@v4
22+
with:
23+
python-version: '3.9'
24+
25+
- name: Install dependencies
26+
run: |
27+
python -m pip install --upgrade pip
28+
pip install -r requirements.txt
29+
30+
- name: Run tests
31+
run: |
32+
python -m unittest ./tests/test_multiform_validator.py

.github/workflows/python-publish.yml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
# This workflow will upload a Python Package using Twine when a release is created
2+
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python#publishing-to-package-registries
3+
4+
# This workflow uses actions that are not certified by GitHub.
5+
# They are provided by a third-party and are governed by
6+
# separate terms of service, privacy policy, and support
7+
# documentation.
8+
9+
name: Upload Python Package
10+
11+
on:
12+
push:
13+
branches: ["main"]
14+
paths:
15+
- "pyproject.toml"
16+
17+
workflow_dispatch:
18+
19+
permissions:
20+
contents: read
21+
22+
jobs:
23+
deploy:
24+
runs-on: ubuntu-latest
25+
26+
steps:
27+
- uses: actions/checkout@v4
28+
- name: Set up Python
29+
uses: actions/setup-python@v3
30+
with:
31+
python-version: '3.x'
32+
33+
- name: Cd to directory to publish in PyPi
34+
run: |
35+
python -m pip install --upgrade pip
36+
pip install build
37+
pip install twine
38+
python -m build
39+
twine upload -u ${{ secrets.PYPI_USER }} -p ${{ secrets.PYPI_API_TOKEN }} dist/*

CODE_OF_CONDUCT.md

Lines changed: 128 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,128 @@
1+
# Contributor Covenant Code of Conduct
2+
3+
## Our Pledge
4+
5+
We as members, contributors, and leaders pledge to make participation in our
6+
community a harassment-free experience for everyone, regardless of age, body
7+
size, visible or invisible disability, ethnicity, sex characteristics, gender
8+
identity and expression, level of experience, education, socio-economic status,
9+
nationality, personal appearance, race, religion, or sexual identity
10+
and orientation.
11+
12+
We pledge to act and interact in ways that contribute to an open, welcoming,
13+
diverse, inclusive, and healthy community.
14+
15+
## Our Standards
16+
17+
Examples of behavior that contributes to a positive environment for our
18+
community include:
19+
20+
* Demonstrating empathy and kindness toward other people
21+
* Being respectful of differing opinions, viewpoints, and experiences
22+
* Giving and gracefully accepting constructive feedback
23+
* Accepting responsibility and apologizing to those affected by our mistakes,
24+
and learning from the experience
25+
* Focusing on what is best not just for us as individuals, but for the
26+
overall community
27+
28+
Examples of unacceptable behavior include:
29+
30+
* The use of sexualized language or imagery, and sexual attention or
31+
advances of any kind
32+
* Trolling, insulting or derogatory comments, and personal or political attacks
33+
* Public or private harassment
34+
* Publishing others' private information, such as a physical or email
35+
address, without their explicit permission
36+
* Other conduct which could reasonably be considered inappropriate in a
37+
professional setting
38+
39+
## Enforcement Responsibilities
40+
41+
Community leaders are responsible for clarifying and enforcing our standards of
42+
acceptable behavior and will take appropriate and fair corrective action in
43+
response to any behavior that they deem inappropriate, threatening, offensive,
44+
or harmful.
45+
46+
Community leaders have the right and responsibility to remove, edit, or reject
47+
comments, commits, code, wiki edits, issues, and other contributions that are
48+
not aligned to this Code of Conduct, and will communicate reasons for moderation
49+
decisions when appropriate.
50+
51+
## Scope
52+
53+
This Code of Conduct applies within all community spaces, and also applies when
54+
an individual is officially representing the community in public spaces.
55+
Examples of representing our community include using an official e-mail address,
56+
posting via an official social media account, or acting as an appointed
57+
representative at an online or offline event.
58+
59+
## Enforcement
60+
61+
Instances of abusive, harassing, or otherwise unacceptable behavior may be
62+
reported to the community leaders responsible for enforcement at
63+
.
64+
All complaints will be reviewed and investigated promptly and fairly.
65+
66+
All community leaders are obligated to respect the privacy and security of the
67+
reporter of any incident.
68+
69+
## Enforcement Guidelines
70+
71+
Community leaders will follow these Community Impact Guidelines in determining
72+
the consequences for any action they deem in violation of this Code of Conduct:
73+
74+
### 1. Correction
75+
76+
**Community Impact**: Use of inappropriate language or other behavior deemed
77+
unprofessional or unwelcome in the community.
78+
79+
**Consequence**: A private, written warning from community leaders, providing
80+
clarity around the nature of the violation and an explanation of why the
81+
behavior was inappropriate. A public apology may be requested.
82+
83+
### 2. Warning
84+
85+
**Community Impact**: A violation through a single incident or series
86+
of actions.
87+
88+
**Consequence**: A warning with consequences for continued behavior. No
89+
interaction with the people involved, including unsolicited interaction with
90+
those enforcing the Code of Conduct, for a specified period of time. This
91+
includes avoiding interactions in community spaces as well as external channels
92+
like social media. Violating these terms may lead to a temporary or
93+
permanent ban.
94+
95+
### 3. Temporary Ban
96+
97+
**Community Impact**: A serious violation of community standards, including
98+
sustained inappropriate behavior.
99+
100+
**Consequence**: A temporary ban from any sort of interaction or public
101+
communication with the community for a specified period of time. No public or
102+
private interaction with the people involved, including unsolicited interaction
103+
with those enforcing the Code of Conduct, is allowed during this period.
104+
Violating these terms may lead to a permanent ban.
105+
106+
### 4. Permanent Ban
107+
108+
**Community Impact**: Demonstrating a pattern of violation of community
109+
standards, including sustained inappropriate behavior, harassment of an
110+
individual, or aggression toward or disparagement of classes of individuals.
111+
112+
**Consequence**: A permanent ban from any sort of public interaction within
113+
the community.
114+
115+
## Attribution
116+
117+
This Code of Conduct is adapted from the [Contributor Covenant][homepage],
118+
version 2.0, available at
119+
https://www.contributor-covenant.org/version/2/0/code_of_conduct.html.
120+
121+
Community Impact Guidelines were inspired by [Mozilla's code of conduct
122+
enforcement ladder](https://github.com/mozilla/diversity).
123+
124+
[homepage]: https://www.contributor-covenant.org
125+
126+
For answers to common questions about this code of conduct, see the FAQ at
127+
https://www.contributor-covenant.org/faq. Translations are available at
128+
https://www.contributor-covenant.org/translations.

CONTRIBUTING.md

Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
# multiform-validator - Contribution Guide
2+
3+
The multiform-validator is a powerful Multilanguage library for validating form fields in multiple languages. This guide describes the guidelines for contributing to the project efficiently and effectively.
4+
5+
## How to Contribute
6+
7+
1. **Fork the Repository**
8+
- Fork the multiform-validator repository to your GitHub account.
9+
10+
2. **Clone the Repository**
11+
- Clone the forked repository to your local environment:
12+
```
13+
git clone https://github.com/gabriel-logan/multiform-validator.git
14+
```
15+
16+
4. **Commit and Push**
17+
- Commit your changes and push them to the forked repository:
18+
```
19+
git add .
20+
git commit -m "Concise description of the changes"
21+
git push origin my-feature
22+
```
23+
24+
5. **Open a Pull Request (PR)**
25+
- Go to the forked repository on GitHub and open a PR to the main branch of the project.
26+
27+
## Contribution Guidelines
28+
29+
feat: Adds a new feature to the project. For example:
30+
31+
feat: Add controller for user management
32+
fix: Fixes an existing bug or issue. For example:
33+
34+
fix: Fix validation error in the controller
35+
refactor: Restructures existing code without changing its functionality. For example:
36+
37+
refactor: Rearrange methods in the controller for better readability
38+
docs: Updates the project's documentation. For example:
39+
40+
docs: Update documentation for the user controller
41+
style: Makes code style-related changes, such as formatting, indentation, etc. For example:
42+
43+
style: Format code in the controller according to project guidelines
44+
test: Adds or modifies tests in the project. For example:
45+
46+
test: Add tests for the user controller
47+
chore: Performs maintenance tasks or other activities not directly related to code. For example:
48+
49+
chore: Update project dependencies for compatibility with new versions
50+
perf: Makes performance improvements in the code. For example:
51+
52+
perf: Optimize data query in the controller
53+
revert: Reverts a previous change. For example:
54+
55+
revert: Revert changes in the controller due to implementation issues
56+
ci: Makes modifications related to continuous integration (CI) and deployment. For example:
57+
58+
ci: Configure CI pipeline to automatically test the controller
59+
60+
- Follow the coding standards of the language you're contributing to (JavaScript, TypeScript, Java, etc.).
61+
- Keep the code clean and readable.
62+
- Add tests for new functionalities or bug fixes.
63+
- Properly document the changes made, including updates to README if necessary.
64+
- Be respectful to other contributors and maintain a collaborative environment.
65+
66+
## License
67+
68+
By contributing to multiform-validator, you agree that your contributions will be licensed under the MIT license. Make sure you're familiar with the terms of this license.

SECURITY.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# Security Policy
2+
3+
## Reporting a Vulnerability
4+
5+
If you find a vulnerability in the project, please follow these steps to report it:
6+
7+
1. **Report Submission**: Send a detailed email to [gabriellogan1717@gmail.com] with information about the vulnerability.
8+
2. **Required Information**: Include in the report details such as a description of the vulnerability, steps to reproduce it, the potential impact, and any suggested fixes.
9+
3. **Initial Response**: You can expect an initial response within 72 hours of submitting the report.
10+
4. **Review Process**: The vulnerability will be reviewed by our team. During this period, we may request additional information.
11+
5. **Updates**: We will provide regular updates on the status of the review and the action plan to resolve the vulnerability.
12+
6. **Disclosure**: If the vulnerability is confirmed, we will work on a fix and release a security update along with a vulnerability disclosure note.
13+
14+
We appreciate your help in keeping the project safe and secure.
15+
16+
You can also open the action in issues
17+
18+
## Reporter's Responsibilities
19+
20+
- Do not publicly disclose the vulnerability until it has been reviewed and fixed.
21+
- Collaborate with the security team to provide all necessary information.
22+
23+
Thank you for your contribution to the security of the multiform-validator project!

0 commit comments

Comments
 (0)
0