Skip to content

Instantly share code, notes, and snippets.

View narwanimonish's full-sized avatar

Monish Narwani narwanimonish

View GitHub Profile
#!/usr/bin/env bash
funnyCommit() {
commitMessage=$(echo $(curl --silent --fail whatthecommit.com/index.txt))
echo "Your Commit Message is -> ${commitMessage}"
echo "Do you wish to procced with this commit message 😅 (y/n/o = other)?"
old_stty_cfg=$(stty -g)
stty raw -echo ; answer=$(head -c 1) ; stty $old_stty_cfg
if echo "$answer" | grep -iq "^y" ;then
git add -A && git commit -m "${commitMessage}"
@JohnDinhDev
JohnDinhDev / Reset Udemy Progress.md
Last active April 29, 2024 18:36
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

#!/bin/bash
# declare an array called array and define 3 vales
databases=( drupal fresh lasalle_wp_fts )
username=root
password=password
filepath=/home/amitavroy/code/backup
for i in "${databases[@]}"
do
filename=${i}_$(date +"%m%d%Y-%k%M")
mysqldump -u${username} -p${password} ${i} > ${filepath}/${filename}.sql
@Geoff-Ford
Geoff-Ford / master-javascript-interview.md
Last active May 2, 2024 13:13
Eric Elliott's Master the JavaScript Interview Series