diff --git a/.all-contributorsrc b/.all-contributorsrc index 6d905e8..07a3236 100644 --- a/.all-contributorsrc +++ b/.all-contributorsrc @@ -12,7 +12,8 @@ "avatar_url": "https://avatars.githubusercontent.com/u/65337802?v=4", "profile": "http://mpotane.github.io", "contributions": [ - "maintenance" + "maintenance", + "test" ] }, { @@ -86,9 +87,18 @@ "contributions": [ "doc" ] + }, + { + "login": "VishMaster17", + "name": "VishMaster17", + "avatar_url": "https://avatars.githubusercontent.com/u/74035077?v=4", + "profile": "https://github.com/VishMaster17", + "contributions": [ + "doc" + ] } ], - "contributorsPerLine": 7, + "contributorsPerLine": 3, "skipCi": true, "repoType": "github", "repoHost": "https://github.com", diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml new file mode 100644 index 0000000..11925d6 --- /dev/null +++ b/.github/workflows/main.yml @@ -0,0 +1,19 @@ +name: Learning GitHub Script + +on: + issues: + types: [opened] + +jobs: + comment: + runs-on: ubuntu-latest + steps: + - uses: actions/github-script@v6 + with: + script: | + github.rest.issues.createComment({ + issue_number: context.issue.number, + owner: context.repo.owner, + repo: context.repo.repo, + body: '👋 Thanks for reporting!' + }) diff --git a/README.md b/README.md index 3142814..b82422c 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,11 @@ ## PythonScriptPH 🇵🇭 -[![All Contributors](https://img.shields.io/badge/all_contributors-9-orange.svg?style=flat-square)](#contributors-) +[![All Contributors](https://img.shields.io/badge/all_contributors-10-orange.svg?style=flat-square)](#contributors-) -[![](https://img.shields.io/static/v1?label=python&message=3.10.7&color=f7df28&style=for-the-badge&logo=python)](https://www.python.org/) [![](https://img.shields.io/static/v1?label=LICENSE&message=GPLv3&color=brightgreen&style=for-the-badge&logo=gnu)](https://www.gnu.org/licenses/gpl-3.0.en.html) +![LOVE](https://forthebadge.com/images/badges/built-with-love.svg) ![yes](https://forthebadge.com/images/badges/check-it-out.svg) + +[![](https://img.shields.io/static/v1?label=python&message=3.11.4&color=f7df28&style=for-the-badge&logo=python)](https://www.python.org/) [![](https://img.shields.io/static/v1?label=LICENSE&message=GPLv3&color=brightgreen&style=for-the-badge&logo=gnu)](https://www.gnu.org/licenses/gpl-3.0.en.html) --- @@ -13,23 +15,31 @@ - [Searching](https://github.com/mpotane/PythonScriptPH/tree/main/Algorithms/Searching) - [Sorting](https://github.com/mpotane/PythonScriptPH/tree/main/Algorithms/Sorting) - [Btc To Php](https://github.com/mpotane/PythonScriptPH/tree/main/btc-to-php) +- [Compress Photo](https://github.com/mpotane/PythonScriptPH/tree/main/compress-photo) - [Csv To Excel](https://github.com/mpotane/PythonScriptPH/tree/main/csv-to-excel) - [Csv To Json](https://github.com/mpotane/PythonScriptPH/tree/main/csv-to-json) - [Detect Language](https://github.com/mpotane/PythonScriptPH/tree/main/detect-language) - [Filecopy](https://github.com/mpotane/PythonScriptPH/tree/main/filecopy) - [Img To Pdf](https://github.com/mpotane/PythonScriptPH/tree/main/img-to-pdf) +- [Json To YAML](https://github.com/mpotane/PythonScriptPH/tree/main/json-to-yaml) +- [Pdf to docx](https://github.com/mpotane/PythonScriptPH/tree/main/pdf-to-docx) - [Philippine Flag](https://github.com/mpotane/PythonScriptPH/tree/main/Philippine-flag) +- [Proof Reader](https://github.com/mpotane/PythonScriptPH/tree/main/proof-reader) - [Qrcode](https://github.com/mpotane/PythonScriptPH/tree/main/qrcode) - [Remove Background Image](https://github.com/mpotane/PythonScriptPH/tree/main/remove-background-image) - [Speed Test](https://github.com/mpotane/PythonScriptPH/tree/main/speed-test) - [Text To Tagalog](https://github.com/mpotane/PythonScriptPH/tree/main/text-to-tagalog) - [Usd To Peso](https://github.com/mpotane/PythonScriptPH/tree/main/usd-to-peso) -- [Youtube Video Downloader](https://github.com/mpotane/PythonScriptPH/tree/main/Youtube-Video-Downloader) +- [Youtube Video Downloader](https://github.com/mpotane/PythonScriptPH/tree/main/youtube-video-downloader) + --- ### 🎯 Contribute -Open for contributions. Create a pull request and I will review the code. 🧐 +Open for contributions. Create a pull request and I will review the code. [Contributor Guide](./CODE_OF_CONDUCT.md) 🧐 + +### 📋 Code of Conduct +This project and everyone participating in it are governed by the [Contributor Covenant Code of Conduct](./CODE_OF_CONDUCT.md). By participating, you agree to abide by this code of conduct. --- @@ -41,18 +51,23 @@ Open for contributions. Create a pull request and I will review the code. 🧐 - + + + - + + + +
mpotane
mpotane

🚧
mpotane
mpotane

🚧 ⚠️
Kayode
Kayode

📖
Vishvam S
Vishvam S

📖
Omoleye Julius Fortunate
Omoleye Julius Fortunate

🔌
Ayush Awasthi
Ayush Awasthi

💻
Ashu
Ashu

💻
RIZWAN AHMAD
RIZWAN AHMAD

💻
RIZWAN AHMAD
RIZWAN AHMAD

💻
Santiago Ariza
Santiago Ariza

💻
ADITYA DAS
ADITYA DAS

📖
VishMaster17
VishMaster17

📖
diff --git a/compress-photo/requirements.txt b/compress-photo/requirements.txt new file mode 100644 index 0000000..dc7fba5 --- /dev/null +++ b/compress-photo/requirements.txt @@ -0,0 +1,2 @@ +tkinter +Pillow \ No newline at end of file diff --git a/compress-photo/script.py b/compress-photo/script.py new file mode 100644 index 0000000..8ed543b --- /dev/null +++ b/compress-photo/script.py @@ -0,0 +1,8 @@ +import PIL +from PIL import Image +from tkinter.filedialog import * + + +fl=askopenfilenames() +img = Image.open(fl[0]) +img.save("output.jpg", "JPEG", optimize = True, quality = 10) \ No newline at end of file diff --git a/csv-to-json/script.py b/csv-to-json/script.py index 9976cd6..55be48a 100644 --- a/csv-to-json/script.py +++ b/csv-to-json/script.py @@ -1,5 +1,12 @@ import pandas as pd # Reading the csv file and converting it to a json file. -df = pd.read_csv('sample.csv') -df.to_json('sample.json') \ No newline at end of file + + +def main(): + df = pd.read_csv('sample.csv') + df.to_json('sample.json') + + +if __name__ == '__main__': + main() diff --git a/pdf-to-docx/requirements.txt b/pdf-to-docx/requirements.txt new file mode 100644 index 0000000..9c2b9de --- /dev/null +++ b/pdf-to-docx/requirements.txt @@ -0,0 +1 @@ +pdf2docx \ No newline at end of file diff --git a/pdf-to-docx/rickroll_4k.docx b/pdf-to-docx/rickroll_4k.docx new file mode 100644 index 0000000..63d29a5 Binary files /dev/null and b/pdf-to-docx/rickroll_4k.docx differ diff --git a/pdf-to-docx/rickroll_4k.pdf b/pdf-to-docx/rickroll_4k.pdf new file mode 100644 index 0000000..8723527 Binary files /dev/null and b/pdf-to-docx/rickroll_4k.pdf differ diff --git a/pdf-to-docx/script.py b/pdf-to-docx/script.py new file mode 100644 index 0000000..aebaa0b --- /dev/null +++ b/pdf-to-docx/script.py @@ -0,0 +1,13 @@ +from pdf2docx import Converter + + +def main(): + pdf_file = 'rickroll_4k.pdf' + docx_file = 'rickroll_4k.docx' + cv = Converter(pdf_file) + cv.convert(docx_file) + cv.close() + + +if __name__ == '__main__': + main() diff --git a/proof-reader/requirements.txt b/proof-reader/requirements.txt new file mode 100644 index 0000000..39941b8 --- /dev/null +++ b/proof-reader/requirements.txt @@ -0,0 +1 @@ +lmproof \ No newline at end of file diff --git a/proof-reader/script.py b/proof-reader/script.py new file mode 100644 index 0000000..1797492 --- /dev/null +++ b/proof-reader/script.py @@ -0,0 +1,10 @@ +import lmproof + + +def proofread(text): + proofread = lmproof.load("en") + correction = proofread.proofread(text) + print("Original: {}".format(text)) + print("Correction: {}".format(correction)) + +proofread("Your Text") \ No newline at end of file diff --git a/soundrecorder/script.py b/soundrecorder/script.py new file mode 100644 index 0000000..5c7a153 --- /dev/null +++ b/soundrecorder/script.py @@ -0,0 +1,14 @@ +import sounddevice +from scipy.io.wavfile import write + + +def main(): + fs = 44100 # Sample rate + seconds = 10 # Duration of recording + + myrecording = sounddevice.rec(int(seconds * fs), samplerate=fs, channels=2) + sounddevice.wait() # Wait until recording is finished + write("output.wav", fs, myrecording) # Save as WAV file + +if __name__ == "__main__": + main() \ No newline at end of file