Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit ee04bd6

Browse files
Merge pull request avinashkranjan#2 from avinashkranjan/master
update forked repo
2 parents 498d56d + 2536ca4 commit ee04bd6

File tree

35 files changed

+1459
-42
lines changed

35 files changed

+1459
-42
lines changed

‎.all-contributorsrc

Lines changed: 75 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,6 @@
55
"imageSize": 100,
66
"commit": false,
77
"contributors": [
8-
{
9-
"login": "jeffugo",
10-
"name": "jeffugo",
11-
"avatar_url": "https://avatars0.githubusercontent.com/u/70389806?v=4",
12-
"profile": "https://github.com/jeffugo",
13-
"contributions": [
14-
"doc"
15-
]
16-
},
178
{
189
"login": "avinashkranjan",
1910
"name": "Avinash Kr. Ranjan",
@@ -28,6 +19,81 @@
2819
"code",
2920
"doc"
3021
]
22+
},
23+
{
24+
"login": "jeffugo",
25+
"name": "jeffugo",
26+
"avatar_url": "https://avatars0.githubusercontent.com/u/70389806?v=4",
27+
"profile": "https://github.com/jeffugo",
28+
"contributions": [
29+
"doc"
30+
]
31+
},
32+
{
33+
"login": "geekymeeky",
34+
"name": "Srijan Kumar Gupta",
35+
"avatar_url": "https://avatars3.githubusercontent.com/u/66238394?v=4",
36+
"profile": "https://github.com/geekymeeky",
37+
"contributions": [
38+
"code"
39+
]
40+
},
41+
{
42+
"login": "abirbhattacharya82",
43+
"name": "Abir Bhattacharya",
44+
"avatar_url": "https://avatars0.githubusercontent.com/u/70687014?v=4",
45+
"profile": "https://abirbhattacharya.herokuapp.com/",
46+
"contributions": [
47+
"code",
48+
"ideas"
49+
]
50+
},
51+
{
52+
"login": "madihamallick",
53+
"name": "Madiha Mallick",
54+
"avatar_url": "https://avatars1.githubusercontent.com/u/70858557?v=4",
55+
"profile": "https://github.com/madihamallick",
56+
"contributions": [
57+
"code"
58+
]
59+
},
60+
{
61+
"login": "mdb571",
62+
"name": "Mohammed Bilal",
63+
"avatar_url": "https://avatars2.githubusercontent.com/u/55395092?v=4",
64+
"profile": "http://mohammedbilal.me",
65+
"contributions": [
66+
"doc"
67+
]
68+
},
69+
{
70+
"login": "shivamsh555",
71+
"name": "shivam sharma",
72+
"avatar_url": "https://avatars0.githubusercontent.com/u/72130276?v=4",
73+
"profile": "https://github.com/shivamsh555",
74+
"contributions": [
75+
"code"
76+
]
77+
},
78+
{
79+
"login": "sooryaprakash31",
80+
"name": "Soorya Prakash",
81+
"avatar_url": "https://avatars1.githubusercontent.com/u/41444412?v=4",
82+
"profile": "https://www.linkedin.com/in/sooryaprakash31",
83+
"contributions": [
84+
"code",
85+
"doc"
86+
]
87+
},
88+
{
89+
"login": "hardikkhurana",
90+
"name": "Hardik Khurana",
91+
"avatar_url": "https://avatars0.githubusercontent.com/u/43683221?v=4",
92+
"profile": "http://github.com/hardikkhurana",
93+
"contributions": [
94+
"code",
95+
"doc"
96+
]
3197
}
3298
],
3399
"contributorsPerLine": 7,

‎.github/FUNDING.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# These are supported funding model platforms
22

33
github: # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
4-
patreon: avinashranjan
4+
patreon: avinashkranjan
55
open_collective: # Replace with a single Open Collective username
66
ko_fi: # Replace with a single Ko-fi username
77
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel

‎.github/pull_request_template.md

Lines changed: 22 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,38 @@
11
<!--
22
Thank you for sending the PR! We appreciate you spending the time to work on these changes.
3-
43
Help us understand your motivation by explaining why you decided to make this change.
5-
You can learn more about contributing to NeoAlgo here: https://github.com/TesseractCoding/NeoAlgo/blob/master/CONTRIBUTING.md
6-
74
Happy Contributing!
8-
95
-->
6+
107
# Description
118

12-
(Write your answer here.)
9+
Please include a summary of the change and which issue is fixed. List any dependencies that are required for this change.
1310

14-
## Related Issues or Pull Requests
11+
## Fixes #(issue_no)
1512

16-
#(Mention Issue Number Here.)
13+
Replace `issue_no` with the issue number which is fixed in this PR
1714

18-
### Have you read the [Contributing Guidelines on Pull Requests](https://github.com/avinashkranjan/Amazing-Python-Scripts/blob/master/CONTRIBUTING.md)?
15+
## Have you read the [Contributing Guidelines on Pull Requests](https://github.com/avinashkranjan/Amazing-Python-Scripts/blob/master/CONTRIBUTING.md)?
1916

2017
- [ ] Yes
2118
- [ ] No
2219

23-
### Checklist
20+
## Type of change
21+
22+
_Please delete options that are not relevant._
23+
24+
- [ ] Bug fix (non-breaking change which fixes an issue)
25+
- [ ] New feature (non-breaking change which adds functionality)
26+
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
27+
- [ ] This change requires a documentation update
28+
- [ ] Documentation Update
2429

25-
- [ ] I've read the contribution guidelines.
26-
- [ ] I've checked the issue list before deciding what to submit.
27-
- [ ] I've edited the `README.md` and link to my code.
30+
## Checklist:
2831

32+
- [ ] My code follows the style guidelines(Clean Code) of this project
33+
- [ ] I have performed a self-review of my own code
34+
- [ ] I have commented my code, particularly in hard-to-understand areas
35+
- [ ] I have created a helpful and easy to understand `README.md`
36+
- [ ] I have made corresponding changes to the documentation
37+
- [ ] My changes generate no new warnings
38+
- [ ] I have added tests/screenshots(if any) that prove my fix is effective or that my feature works.

‎.github/workflows/greetings.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name: Greetings
22

3-
on: [pull_request, issues]
3+
on: [pull_request_target, issues]
44

55
jobs:
66
greeting:

‎.github/workflows/hacktoberfest.yml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
name: Hacktoberfest Label
2+
on:
3+
issues:
4+
types: [opened,labeled]
5+
6+
jobs:
7+
build:
8+
runs-on: ubuntu-latest
9+
10+
steps:
11+
- name: hacktoberfest-action
12+
uses: mdb571/hacktoberfest-action@master
13+
env:
14+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
15+
LABEL_COLOR: ${{secrets.LABEL_COLOR}}
16+
LABEL_FILTER: ${{secrets.LABEL_FILTER}}

‎.github/workflows/stale.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: Mark stale issues and pull requests
2+
3+
on:
4+
schedule:
5+
- cron: "30 1 * * *"
6+
7+
jobs:
8+
stale:
9+
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
- uses: actions/stale@v1
14+
with:
15+
# Token for the repository. Can be passed in using `{{ secrets.GITHUB_TOKEN }}`.
16+
repo-token: ${{ secrets.GITHUB_TOKEN }}
17+
stale-pr-message: 'Due to inactivity this pull request has been marked as stale.'
18+
# The message to post on the issue when closing it. If none provided, will not comment when closing an issue.
19+
close-pr-message: 'Closing this pr due to no activity.'
20+
# The number of days old an issue can be before marking it stale. Set to -1 to never mark issues or pull requests as stale automatically.
21+
days-before-stale: 7
22+
# The number of days to wait to close an issue or pull request after it being marked stale. Set to -1 to never close stale issues.
23+
days-before-close: 7
24+
# The label to apply when a pull request is stale.
25+
stale-pr-label: 'Stale'
26+
# The label to apply when a pull request is closed.
27+
close-pr-label: 'Stale-n-closed'

‎Amazon_Price_Tracker/amazonprice.py

Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
import requests
2+
from bs4 import BeautifulSoup
3+
import time
4+
import smtplib
5+
6+
# header = {
7+
# "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/85.0.4183.121 Safari/537.36"
8+
# }
9+
10+
# Url = "https://www.amazon.in/Apple-AirPods-Wireless-Charging-Case/dp/B07QDRYVCZ/ref=sr_1_1_sspa?crid=2O0YQXVBL4T86&dchild=1&keywords=airpods&qid=1601031081&sprefix=airpod%2Caps%2C615&sr=8-1-spons&psc=1&spLa=ZW5jcnlwdGVkUXVhbGlmaWVyPUFPVUpPNUNIQUE1RUUmZW5jcnlwdGVkSWQ9QTAxNzI3NjJPNlg3OTJFSTVSOE8mZW5jcnlwdGVkQWRJZD1BMDg1MTYzNjJSRUw4VFVKQzQ1TDkmd2lkZ2V0TmFtZT1zcF9hdGYmYWN0aW9uPWNsaWNrUmVkaXJlY3QmZG9Ob3RMb2dDbGljaz10cnVl"
11+
12+
# get your browser information by searching "my user agent"
13+
user_agent = input("Enter your User-Agent string here\n")
14+
headers = {
15+
"User-Agent": f'{user_agent}'
16+
17+
}
18+
Url = input("Drop the Url of product you wish to buy...!\n")
19+
20+
page = requests.get(Url, headers=headers)
21+
soup = BeautifulSoup(page.content, "html.parser")
22+
23+
24+
# print(soup)
25+
26+
27+
def mail_sending(mail_id, title, password):
28+
server_mail = "smtp.gmail.com"
29+
port = 587
30+
server = smtplib.SMTP(server_mail, port)
31+
server.ehlo()
32+
server.starttls()
33+
server.login(mail_id, password)
34+
subject = "GO BUY FAST!"
35+
body = f"Price of {title} is fallen below the threshold amount. Click on the link below to buy the product!!!\n\n" + Url
36+
message = f'Subject:{subject}\n\n {body}'
37+
server.sendmail(mail_id, mail_id, message)
38+
server.quit()
39+
40+
41+
def check_price():
42+
title = soup.find(id="productTitle").get_text().strip()
43+
try:
44+
price = soup.find(id="priceblock_ourprice_row").get_text().strip()[:20].replace('₹', '').replace(' ',
45+
'').replace(
46+
'Price:', '').replace('\n', '').replace('\xa0', '').replace(',', '').replace('Fu', '')
47+
48+
except:
49+
try:
50+
price = soup.find(id="priceblock_dealprice").get_text().strip()[:20].replace('₹', '').replace(' ',
51+
'').replace(
52+
'Price:', '').replace('\n', '').replace('\xa0', '').replace(',', '').replace('Fu', '')
53+
54+
except:
55+
try:
56+
price = soup.find(id="priceblock_ourprice").get_text().strip()[:20].replace('₹', '').replace(' ',
57+
'').replace(
58+
'Price:', '').replace('\n', '').replace('\xa0', '').replace(',', '').replace('Fu', '')
59+
60+
except:
61+
price = soup.find(id="priceblock_ourprice_lbl").get_text().strip()[:20].replace('₹', '').replace(' ',
62+
'').replace(
63+
'Price:', '').replace('\n', '').replace('\xa0', '').replace(',', '').replace('Fu', '')
64+
65+
fixed_price = float(price)
66+
print(title)
67+
print(f'The current price is {fixed_price}')
68+
y_price = (input('Enter the price you wish to get the product at:'))
69+
your_price = y_price.replace(',', '')
70+
mail_id = input("Please enter your email id: ")
71+
password = input("Enter your app password here: ")
72+
print("Thank You! You'll receive an email as soon as the price of product drops...!")
73+
# print(price)
74+
if fixed_price <= float(your_price):
75+
mail_sending(mail_id, title, password)
76+
exit()
77+
else:
78+
pass
79+
80+
81+
while 1:
82+
check_price()
83+
# checks at an interval of 2 hours
84+
time.sleep(7200.00)

‎BMI-Calculator/BMI_Calculator.py

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
from tkinter import*
2+
3+
root = Tk()
4+
root.geometry("1350x650+0+0")
5+
root.resizable(0,0)
6+
root.title("BMI CALCULATOR")
7+
8+
def BMI_Cal():
9+
Bheight = float(var2.get())
10+
Bweight = float(var1.get())
11+
BMI = str('%.2f' %(Bweight / (Bheight * Bheight)))
12+
labelBMIResult.config(text = BMI)
13+
14+
15+
var1 = DoubleVar()
16+
var2 = DoubleVar()
17+
18+
Tops = Frame(root, width = 1350, height = 50, bd = 8, relief = "raise")
19+
Tops.pack(side = TOP)
20+
21+
f1 = Frame(root, width = 600, height = 600, bd = 8, relief = "raise")
22+
f1.pack(side = LEFT)
23+
24+
f2 = Frame(root, width = 300, height = 700, bd = 8, relief = "raise")
25+
f2.pack(side = RIGHT)
26+
27+
f1a = Frame(f1, width = 600, height = 200, bd = 20, relief = "raise")
28+
f1a.pack(side = TOP)
29+
f1b = Frame(f1, width = 600, height = 600, bd = 20, relief = 'raise')
30+
f1b.pack(side=TOP)
31+
32+
label1Title = Label(Tops, text = " BODY MASS INDEX ", padx = 16, pady = 16, bd = 16, fg = '#000000', font = ("arial", 54, 'bold'), bg = "powder blue", relief = 'raise', width = 32, height = 1)
33+
label1Title.pack()
34+
35+
labelweight = Label(f1a, text = "Select Weight in Kilograms", font =('arial', 20, 'bold'), bd = 20).grid(row = 0, column = 0)
36+
Bodyweight = Scale(f1a, variable = var1, from_ = 1, to = 500, length = 880, tickinterval = 30, orient = HORIZONTAL)
37+
Bodyweight.grid(row = 1, column = 0)
38+
39+
labelheight = Label(f1b, text = "Enter Height in Meters Square", font =('arial', 20, 'bold'), bd = 20).grid(row = 0, column = 0)
40+
textheight = Entry(f1b, textvariable = var2, font = ('arial', 16, 'bold'), bd = 16, width = 22, justify = 'center')
41+
textheight.grid(row = 1, column = 0)
42+
43+
labelBMIResult = Label(f1b, padx = 16, pady = 16, bd = 16, fg = '#000000', font = ('arial', 30, 'bold'), bg = 'sky blue', relief = 'sunk', width = 34, height = 1)
44+
labelBMIResult.grid(row = 2, column = 0)
45+
46+
labelBMITable = Label(f2, font = ("arial", 20, 'bold'), text = 'BMI Table').grid(row = 0, column = 0)
47+
txtlabelBMITable = Text(f2, height = 12, width = 38, bd = 16, font = ("arial", 12, 'bold'))
48+
txtlabelBMITable.grid(row = 1, column = 0)
49+
50+
txtlabelBMITable.insert(END, 'Meaning \t\t' + "BMI \n\n")
51+
txtlabelBMITable.insert(END, 'Normal weight \t\t' + "19-24 \n\n")
52+
txtlabelBMITable.insert(END, 'Overwight \t\t' + "25-29,9 \n\n")
53+
txtlabelBMITable.insert(END, 'Obesity level I \t\t' + "30-34, 9 \n\n")
54+
txtlabelBMITable.insert(END, 'Obesity level II \t\t' + "35-39, 9\n\n")
55+
txtlabelBMITable.insert(END, 'Obesity level III \t\t' + ">= 40\n\n")
56+
57+
btnBMI = Button(f2, text = "Click to \nCheck Your \nBMI", padx = 8, pady = 8, bd = 12, width = 21, font = ("arial", 20, 'bold'), height = 3, command = BMI_Cal)
58+
btnBMI.grid(row = 2, column = 0)
59+
60+
root.mainloop()
61+

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /