Skip to content

Instantly share code, notes, and snippets.

View bitwisebro's full-sized avatar
👾
Lost Somewhere😶‍🌫️

Gaurav Jani bitwisebro

👾
Lost Somewhere😶‍🌫️
View GitHub Profile
@bitwisebro
bitwisebro / json-import-to-mongo.py
Created December 21, 2023 11:50
Python Script for importing all json files in a folder to mongoDB
import os
# Set the database and collection names
db_name = "dbOne"
collection_name = "collectionOne"
# Set the path to the folder containing JSON files
folder_path = "D:/path/to/json/folder"
# Iterate through all files in the given folder
@bitwisebro
bitwisebro / Git_Commands.md
Last active September 7, 2023 09:52
Git Commands for Normies

Author: Gaurav Jani

  1. Clone the Repo:

    • git clone <repo_url>
  2. Switch to Branch you want:

    • git checkout branch_name
  3. Stage modified files:

    • git add
@bitwisebro
bitwisebro / process_killer.bat
Last active March 17, 2023 06:16
Windows Batch Script for killing all the instances of given process
@echo off
Title Process Killer
rem Utility By Gaurav Jani
rem just kills the given local instancess
color F0
echo Process killer Utility By Gaurav Jani
set /p processName= Type process name to kill:
color FD
echo Killing all instances of: %processName%.exe
taskkill /im %processName%.exe /f
@bitwisebro
bitwisebro / Complete Udemy Progress.md
Last active April 14, 2026 18:20
Complete the Progress of Udemy course

Complete Udemy Progress

This guide will walk you through the process of making udemy course progress as 100%

Prerequisites

Before you begin, make sure you have the following:

  • An Udemy course open in your web browser.
  • The course's sidebar should be visible.
@bitwisebro
bitwisebro / Reset Udemy Progress.md
Created October 30, 2022 07:22 — forked from AstralJohn/Reset Udemy Progress.md
Reset Udemy Progress

Reset Udemy Progress

Last Updated: 09/30/2022

Step 1. Go to Udemy course in browser

Go to the course and have any video up. The following code relies on the right sidebar to be visible to uncheck all your progress.

Step 2. Open browser console

You can do this with ctrl+shift+j and making sure the console tab is selected for chrome/brave

@bitwisebro
bitwisebro / app.js
Created November 22, 2020 07:18 — forked from gilpanal/app.js
The following code demonstrates how to get a file from Telegram without exposing Bot Secret Token in the client side. In this case is used to retrieve a MP3, but the example should work for other file types. An intermediate API, (server.js) built using Node.js, get the raw data of the file and forward it to the web client (index.html and app.js)
const TEL_PATH = '/music/file_352.mp3'
const API_FILEDONWLOAD = 'http://localhost:3000/fileDownload?'
const load = () => {
return new Promise((resolve, reject) => {
const xhr = new XMLHttpRequest()
xhr.open('GET', API_FILEDONWLOAD + TEL_PATH, true)
xhr.responseType = 'arraybuffer'
@bitwisebro
bitwisebro / GNS.sh
Last active January 13, 2024 10:23
cwd - bash shell script
#!/bin/bash
# This script is GNS: Gaurav's Navigation Script
# Make this script executable: chmod +x GNS
# Move this to you bin folder for global access : mv GNS.sh /bin/gns
# call this with '. gns'
comm0="pkg update; pkg upgrade"
folder1="/mnt/c/"
folder2="/mnt/d/"
@bitwisebro
bitwisebro / bash_setup.sh
Last active September 15, 2023 05:31
Termux Themes
#!/data/data/com.termux/files/usr/bin/bash
## Author : Gaurav Jani
## Github : @bitwiseBro
#colors
R='\033[1;31m'
B='\033[1;34m'
C='\033[0;36m'
G='\033[1;32m'
@bitwisebro
bitwisebro / bash.bashrc
Last active October 5, 2020 10:53
My Termux
if [ -x /data/data/com.termux/files/usr/libexec>
command_not_found_handle() { /data/data/com.termux/files/usr>
}
fi
PS1='\$ '
# Change directory aliases
alias home='cd ~'
alias cd..='cd ..'