Skip to content

Instantly share code, notes, and snippets.

Zeeshan Ahmad ziishaned

Block or report user

Report or block ziishaned

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@ziishaned
ziishaned / android_instructions.md
Created Dec 19, 2019 — forked from patrickhammond/android_instructions.md
Easily setup an Android development environment on a Mac
View android_instructions.md

Here is a high level overview for what you need to do to get most of an Android environment setup and maintained.

Prerequisites (for Homebrew at a minimum, lots of other tools need these too):

  • XCode is installed (via the App Store)
  • XCode command line tools are installed (xcode-select --install will prompt up a dialog)
  • Java

Install Homebrew:

ruby -e "$(curl -fsSL https://raw.github.com/Homebrew/homebrew/go/install)"
@ziishaned
ziishaned / markdown.css
Created Nov 5, 2019
Intellij Markdown Github css
View markdown.css
body {
font-family: "Operator Mono" !important;
font-size: 16px !important;
line-height: 1.5 !important;
}
h1 {
font-size: 2em !important;
margin: .67em 0 !important;
}
View gist:a38b493ca4fbdb8b7b275647d02f902f
rm ~/Library/Preferences/com.bjango.istatmenus.plist
@ziishaned
ziishaned / isDateBetweenOrEqual.js
Created May 21, 2019
Check if provided date is equal or between two dates
View isDateBetweenOrEqual.js
const isDateBetweenOrEqual = (checkDate, fromDate, toDate) => {
const toMS = Date.parse(toDate);
const checkMS = Date.parse(check);
const fromMS = Date.parse(fromDate);
return checkMS >= fromMS && checkMS <= toMS;
},
View dark.css
body { background: #222; color: #e6e6e6; }
a { color: #949494; }
a:link, a:visited { color: #949494; }
a:hover, a:active, a:focus { color: #c7c7c7; }
hr { border-bottom: 1px solid #424242; border-top: 1px solid #222; }
@ziishaned
ziishaned / iterm_open_with_subl
Created Jan 27, 2019
Open file links in sublime from iTerm
View iterm_open_with_subl
#!/bin/sh
pwd=$1
file=$2
regex='https?://([a-z0-9A-Z]+(:[a-zA-Z0-9]+)?@)?[-a-z0-9A-Z\-]+(\.[-a-z0-9A-Z\-]+)*((:[0-9]+)?)(/[a-zA-Z0-9;:/\.\-_+%~?&amp;@=#\(\)]*)?'
perl -e "if ( \"$file\" =~ m|$regex|) { exit 0 } else { exit 1 }"
if [ $? -ne 0 ]; then
# if it's not a url, try splitting by ':'
arr=($(echo $2 | tr ':' "\n"))
@ziishaned
ziishaned / laracast-theme.icls
Created Jan 15, 2019 — forked from jdssem/laracast-theme.icls
Laracast theme updated
View laracast-theme.icls
<scheme name="laracasts-theme-updated" version="142" parent_scheme="Default">
<option name="LINE_SPACING" value="1.7" />
<option name="EDITOR_FONT_SIZE" value="15" />
<option name="CONSOLE_FONT_NAME" value="Menlo" />
<option name="CONSOLE_FONT_SIZE" value="10" />
<option name="CONSOLE_LINE_SPACING" value="1.4" />
<option name="EDITOR_FONT_NAME" value="Menlo" />
<colors>
<option name="ADDED_LINES_COLOR" value="292d38" />
<option name="ANNOTATIONS_COLOR" value="8b999f" />
@ziishaned
ziishaned / installation.md
Created Jul 5, 2018
Install php mongodb driver using pecl
View installation.md
pecl install mongodb
subl /usr/local/etc/php/7.2/php.ini
extension="/usr/local/lib/php/pecl/20170718/mongodb.so"
View flat-object.js
function getFlatObject(object) {
function iter(o, p) {
if (Array.isArray(o) ){
o.forEach(function (a, i) {
iter(a, p.concat(i));
});
return;
}
if (o !== null && typeof o === 'object') {
Object.keys(o).forEach(function (k) {
@ziishaned
ziishaned / node-gyp.md
Created May 8, 2018
node 10 node-gyp problem
View node-gyp.md
npm i -g node-gyp node-pre-gyp npm-check-updates
npm i -g node-libcurl aerospike --build-from-source --fallback-to-build
npm install --no-optional
You can’t perform that action at this time.