Skip to content

Instantly share code, notes, and snippets.

View rishiv3's full-sized avatar
:octocat:
Eat πŸ˜‹ | Code πŸ‘¨β€πŸ’» | Sleep 😴 | Repeat ♾️ | Achieve πŸš€

Rishi Vishwakarma rishiv3

:octocat:
Eat πŸ˜‹ | Code πŸ‘¨β€πŸ’» | Sleep 😴 | Repeat ♾️ | Achieve πŸš€
View GitHub Profile
@rishiv3
rishiv3 / jshipster_and_and.js
Created March 14, 2017 12:59 — forked from berzniz/jshipster_and_and.js
Some small javascript hacks for hipsters
// Boring
if (isThisAwesome) {
alert('yes'); // it's not
}
// Awesome
isThisAwesome && alert('yes');
// Also cool for guarding your code
var aCoolFunction = undefined;
@rishiv3
rishiv3 / awesomebuilder.sh
Created February 15, 2017 15:04
Automate automation with this bash script. Build and package all joomla extensions you develop. It is using phing and a phing.xml found on another git repo. git@github.com:enav/phing-joomla-extension-builder.git. Prerequisite : follow enav's tutorial. Then just place awesomebuilder.sh script where your extensions source folder is. Not in your jo…
#!/bin/bash
cd "$1" && find . -maxdepth 3 -type f -name "build.xml" -print0 | xargs -0 -I{} \
bash -c 'current_dir=$(dirname "$1") ; echo "${current_dir}"; base=$(basename "${current_dir}"); echo "${base}"; \
phing -f "$1" -Dextension="${base}" build \
&& phing -f "$1" -Dextension="${base}"' -- {}