Skip to content

Instantly share code, notes, and snippets.

View Bhupesh-V's full-sized avatar
🤔
Do I know what I am doing? No

Bhupesh Varshney Bhupesh-V

🤔
Do I know what I am doing? No
View GitHub Profile
@Bhupesh-V
Bhupesh-V / html-template.html
Last active April 30, 2024 08:55
A Sample HTML Template for better SEO
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta content='text/html; charset=utf-8' http-equiv='Content-Type'>
<meta http-equiv='X-UA-Compatible' content='IE=edge'>
<meta name='viewport' content="width=device-width,height=device-height, initial-scale=1, shrink-to-fit=yes">
<!--theme colors -->
<meta name="theme-color" content="" />
@Bhupesh-V
Bhupesh-V / main.go
Created February 15, 2024 07:33
Providing Git VCS commit info from Go
package main
import (
"fmt"
"log"
"runtime/debug"
)
func main() {
// Only works when we do a main module build (doesn't work with direct go run)
@Bhupesh-V
Bhupesh-V / tea-spinner-with-work.go
Created January 31, 2024 16:46
bubble tea with work
package main
import (
"fmt"
"net/http"
"os"
"time"
"github.com/charmbracelet/bubbles/spinner"
tea "github.com/charmbracelet/bubbletea"
@Bhupesh-V
Bhupesh-V / filesystem-alpine.txt
Last active January 25, 2024 14:13
Filesystem analysis of alpine:latest" docker image as of Jan 2024
-----File-----
Analysis for alpine:latest:
FILE SIZE
/bin 790.7K
/bin/arch 12B
/bin/ash 12B
/bin/base64 12B
/bin/bbconfig 12B
@Bhupesh-V
Bhupesh-V / neovim.desktop
Last active April 14, 2023 14:14
NeoVim desktop file to use with Mate Terminal - open file with neovim in new terminal window
[Desktop Entry]
Name=NeoVim
Categories=;
Comment=Edit file in NeoVim
Exec=mate-terminal -e 'nvim %F' %f
Terminal=false
Type=Application
Keywords=Text;editor;
Icon=nvim
Categories=Utility;TextEditor;
@Bhupesh-V
Bhupesh-V / aws-certified-developer-associate-courses.md
Last active February 15, 2023 18:48
Courses for AWS Certified Developer - Associate Certification Exam
# A barebones cache with a TTL
import threading
import time
class Cache:
def __init__(self):
self.cache = {}
# 4 seconds
self.TTL = 4
@Bhupesh-V
Bhupesh-V / get_instances.py
Last active March 31, 2022 17:03
Get list of working (and good) searx instances
import urllib.request
import json
HEADERS = {
"User-Agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/77.0.3865.90 Safari/537.36",
"Content-Type": "application/json",
}
def request(url, data=None, method=None):
@Bhupesh-V
Bhupesh-V / extract.md
Last active September 29, 2021 04:18
Extract The Unique Image ID from Google Drive URL

Extract The Unique Image ID from Google Drive URL

Usage

python3 extract.py <drive_image_url>

Demo

The ID as a string, Example :

python3 extract.py https://drive.google.com/file/d/0BwZFRt1DatLLZUt4eF94dFh1ZXJubUthenY3MVZERU5yeV9z/view\?usp\=sharing

@Bhupesh-V
Bhupesh-V / _highlights.scss
Last active May 17, 2021 05:54
jekyll-now Code Monokai Theme. Just copy paste the following code under _sass directory in _highlights.scss file
pre.highlight {
background-color: #282923;
padding: 7px 7px 7px 10px;
border: 20px solid yellowgreen;
-moz-box-shadow: 3px 3px rgba(0,0,0,0.1);
-webkit-box-shadow: 3px 3px rgba(0,0,0,0.1);
box-shadow: 3px 3px rgba(0,0,0,0.1);
margin: 20px 0 20px 0;
overflow: auto;