Skip to content

Instantly share code, notes, and snippets.

View devarda's full-sized avatar
💻
Coding

Arda devarda

💻
Coding
View GitHub Profile
@devarda
devarda / 0-Clean-up-brew-php.sh
Last active March 2, 2020 16:56 — forked from idleberg/Install-Mcrypt.md
Mac OSX PHP Extensions 10.15 Catalina
# Will show you any php packages you've got. make not of that!
brew list | grep php
# Will uninstall any php packages you may have
brew list | grep php | while read x; do brew uninstall --force $x; done
# You may need to run this too
rm -rf /usr/local/Cellar/php
# Clean up Launch Agents
rm ~/Library/LaunchAgents/homebrew.mxcl.php*
sudo rm /Library/LaunchDaemons/homebrew.mxcl.php*
brew untap homebrew/php
@devarda
devarda / cmd.sh
Created April 22, 2020 14:18 — forked from kelvinn/cmd.sh
Example of using Apache Bench (ab) to POST JSON to an API
# post_loc.txt contains the json you want to post
# -p means to POST it
# -H adds an Auth header (could be Basic or Token)
# -T sets the Content-Type
# -c is concurrent clients
# -n is the number of requests to run in the test
ab -p post_loc.txt -T application/json -H 'Authorization: Token abcd1234' -c 10 -n 2000 http://example.com/api/v1/locations/
@devarda
devarda / iOS messages export.sh
Created July 20, 2020 00:55 — forked from John07/iOS messages export.sh
Get all your messages (SMS and iMessage) from your iOS device without jailbreak or proprietary tools. Assumes you have an encrypted backup of your iOS device on your Mac.
# Note: this is not a fully functioning script! You will need to edit paths and other variables manually and it's adviced to run each command manually one after another
# install dependencies
# http://www.securitylearn.net/tag/deep-analysis-of-itunes-backup/
sudo ARCHFLAGS='-arch i386 -arch x86_64' easy_install pycrypto
sudo easy_install M2crypto construct progressbar
# clone the decrypt tool source code
# hg stands for mercurial
hg clone https://code.google.com/p/iphone-dataprotection/
@devarda
devarda / dev_console_code.js
Created January 26, 2025 03:35
countingdownto.com clean up code
// Hide everything except the countdown widget
document.querySelectorAll('body > *').forEach(el => {
if (!el.contains(document.querySelector('#cdt'))) {
el.style.display = 'none';
}
});
// Hide specific elements we don't want
const selector = document.querySelector('#countdown_widget_selector');
if (selector) selector.style.display = 'none';
@devarda
devarda / README.md
Created March 15, 2025 19:34
Docker Core Commands Explained

Docker Core Commands Explained

Docker commands follow a pattern where different verbs represent different lifecycle actions:

Container Lifecycle Commands

  • docker run: Creates AND starts a new container from an image
    docker run --name my-container nginx