Skip to content

Instantly share code, notes, and snippets.

@JayantGoel001
JayantGoel001 / Video To Audio.py
Created February 11, 2021 15:31
Convert Video to Audio using moviepy
from moviepy import editor
video = editor.VideoFileClip("GIF.mp4") # Put Video Path
audio = video.audio
file_name = str(audio.filename).split('.')[0]
audio.write_audiofile(file_name+".mp3")
print("==========Succesfully Converted==========")
@JayantGoel001
JayantGoel001 / Set Public visibility of an Organization.html
Last active January 18, 2022 13:14
Set Public Visibility of An Organization by putting Your GitHub Personal Token, your Username, and the Organization Name.
<!DOCTYPE html>
<html lang="en" dir="ltr">
<head>
<meta charset="utf-8">
<title>Set Public Visibility Of An Organization.</title>
</head>
<body>
<script type="module">
import { Octokit } from "https://cdn.skypack.dev/@octokit/core"
const octokit = new Octokit({ auth: `<------Put Here Your GitHub Personal Access Token----->` });
@JayantGoel001
JayantGoel001 / Indian Flag.py
Created January 26, 2021 16:30
Created Indian Flag using turtle and python
from turtle import Turtle, done
flag = Turtle()
flag.speed(3)
flag.pensize(5)
flag.color("#000080")
def draw(x, y):
@JayantGoel001
JayantGoel001 / Wikipedia.py
Created January 13, 2021 17:40
Get Information related to a topic from Wikipedia using pywhatkit
import pywhatkit as kt
topics = ["C++", "Python 3"]
text = {}
for topic in topics:
text[topic] = kt.info(topic, 4)
print(topic)
@JayantGoel001
JayantGoel001 / Currency Converter.py
Created January 9, 2021 21:32
Creating A Currency Converter using forex_python
# pip install forex-python
from forex_python.converter import CurrencyCodes, CurrencyRates
from forex_python.bitcoin import BtcConverter
codes = CurrencyCodes()
l = ['INR', 'USD']
for i in l:
name = codes.get_currency_name(i)
symbol = codes.get_symbol(i)
@JayantGoel001
JayantGoel001 / Progress Bar.py
Created January 9, 2021 21:32
Creating A Progress Bar using tqdm
from tqdm import tqdm, trange
import time
for i in tqdm(range(10)):
time.sleep(1)
for i in trange(10):
time.sleep(1)
@JayantGoel001
JayantGoel001 / Convert JS to py File.py
Created January 9, 2021 21:31
Convert JavaScript Code to python code using js2py
import js2py
log = "console.log('Hello World');"
pr = js2py.eval_js(log)
pr
func = '''function add(a,b){
return a+b;
}'''
@JayantGoel001
JayantGoel001 / Heart.py
Created January 9, 2021 21:30
Creating A Heart using turtle
import turtle
def curvedPart():
for i in range(200):
turtle.right(1)
turtle.forward(1)
turtle.speed(3)
turtle.bgcolor("black")
@JayantGoel001
JayantGoel001 / Desktop Notifier.py
Created January 9, 2021 18:30
Create Desktop Notification using plyer
from plyer import notification
title = "Hey Coders"
message = "I am Jayant Goel"
notification.notify(title=title, message=message, app_icon=None, timeout=10, toast=False)
@JayantGoel001
JayantGoel001 / Grab Screenshot.py
Created January 9, 2021 18:14
Grab Screenshot using pyautogui and tkinter to create GUI
import pyautogui
from tkinter import *
win = Tk()
win.title("Grab ScreenShot")
canvas1 = Canvas(win, width=300, height=300)
canvas1.pack()