This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| show dbs | |
| use testdb | |
| db.dropDatabase() | |
| db.test.find( {} ) | |
| db.test.remove({ "_id" : ObjectId("622fe6b767d3cd1a9e5d5eec") }) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| window.location.href = 'https://www.example.com'; | |
| location.href; | |
| document.body.innerHTML; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/zsh | |
| /Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --headless --disable-gpu --remote-debugging-port=9222 https://www.example.com | |
| echo "Connec to the remote target at chrome://inspect/#devices` | |
| read -p "Press Return to Close..." |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # https://flaviocopes.com/linux-command-xargs/ | |
| cat ~/ips.txt | xargs -n1 whois -h whois.cymru.com |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # https://www.vagrantup.com/docs/cli | |
| vagrant validate | |
| vagrant provision | |
| # find the SSH config for ~/.ssh/config | |
| vagrant ssh-config |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Search lines | |
| grep -nr 'yourString*' . |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # https://www.debian.org/doc/manuals/debian-faq/pkgtools.en.html#whatpackages | |
| #install .deb | |
| sudo dpkg -i file.deb | |
| sudo apt-get install file.deb | |
| #view content of a package | |
| dpkg -c file.deb | |
| # extract pacakge | |
| dpkg -x somefile.deb somefolder |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #https://github.com/luarocks/luarocks/wiki/Using-LuaRocks | |
| luarocks show lyaml # find rocks | |
| luarocks which yaml # find files |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| make -n # or --just-print | |
| make --debug | |
| make SHELL="sh -x" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| aws sso login | |
| aws configure list-profiles | |
| set AWS_DEFAULT_PROFILE=management |