Skip to content

Instantly share code, notes, and snippets.

@bipin-nag
bipin-nag / macos_set_dns.sh
Created March 25, 2024 10:33
MacOS set DNS
#!/bin/zsh
# networksetup -getdnsservers Wi-Fi
# 8.8.8.8
# 8.8.4.4
networksetup -setdnsservers Wi-Fi 192.168.29.1
@bipin-nag
bipin-nag / justanotherbrick.go
Created November 15, 2023 08:36
Just another brick in the wall
package main
import "fmt"
func main() {
line := 0
for i := 0; i < 1000; i++ {
if i%20 == 0 {
fmt.Println()
line += 1
@bipin-nag
bipin-nag / exclude.txt
Created August 12, 2023 12:01
Rsync Backup
Application
Application Support
Caches
Library
node_modules
.cargo
.dartServer
.gem
.gradle
.ivy2
@bipin-nag
bipin-nag / install.sh
Last active August 20, 2023 18:23
Brew Scripts
#!/bin/bash
#
brew install coreutils tree wget curl htop watch aria2 jq mas
#
brew install --cask iterm2 hyper
#
brew install --cask google-chrome firefox tor-browser
@bipin-nag
bipin-nag / kubeDashboardToken.sh
Created December 29, 2021 02:51
kubernetes-dashboard-token
#!/bin/bash
TOKEN=$(kubectl -n kube-system describe secret default| awk '$1=="token:"{print $2}')
echo $TOKEN
# kubectl config set-credentials kubernetes-admin --token="${TOKEN}"
@bipin-nag
bipin-nag / gist:d4223acdb634c3c6c9f007da55e6338a
Last active December 12, 2021 11:31
Language Benchmarks
https://programming-language-benchmarks.vercel.app/
https://benchmarksgame-team.pages.debian.net/benchmarksgame/
@bipin-nag
bipin-nag / node_setup.sh
Created September 17, 2021 00:54
Node.js setup
#!/bin/bash
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.38.0/install.sh | bash
echo '
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
'>> ~/.zshrc
@bipin-nag
bipin-nag / java_setup.sh
Created August 11, 2021 20:41
macOS java setup
#!/bin/bash
brew install jenv
echo 'export PATH="$HOME/.jenv/bin:$PATH"' >> ~/.zshrc
echo 'eval "$(jenv init -)"' >> ~/.zshrc
source ~/.zshrc
brew install AdoptOpenJDK/openjdk/adoptopenjdk8
brew install AdoptOpenJDK/openjdk/adoptopenjdk11
brew install AdoptOpenJDK/openjdk/adoptopenjdk14
java -version