Skip to content

Instantly share code, notes, and snippets.

View Zero-Fanker's full-sized avatar
🧐
I may be slow to respond.

Zero Fanker Zero-Fanker

🧐
I may be slow to respond.
  • Ottawa, ON, Canada
View GitHub Profile
@Zero-Fanker
Zero-Fanker / sudo
Last active September 9, 2021 05:27
fake sudo for windows shell
#!/bin/sh
cmdStr=""
lastIsSlash=0
isFirstCmd=1
for cmd in $*;do
if [ $isFirstCmd -ne 0 ];then
isFirstCmd=0
if [ $cmd == su ];then
continue