This file contains 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
# install Homebrew if you don't already have it: http://mxcl.github.io/homebrew/ | |
# On Mac, Homebrew with homebrew-dupes will allow you to easily upgrade nano to a newer version than the one that came with Mac OSX. | |
# [homebrew-dupes](https://github.com/Homebrew/homebrew-dupes): | |
# These formulae duplicate software provided by OS X, though may provide more recent or bugfix versions. | |
# Add the dupes formulae, then install a new version of nano. | |
brew tap homebrew/dupes | |
brew install nano |
This file contains 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
color_green='\033[92m' | |
color_red='\033[91m' | |
color_off='\033[0m' | |
gruntfile() { | |
if [ -e "gruntfile.js" ] ; then | |
echo -e "${color_red}gruntfile.js already exists${color_off}" | |
if [ -e "Gruntfile.js" ] ; then | |
echo -e "${color_red}Gruntfile.js already exists${color_off}" |
This file contains 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
<!-- Emmet: snippet>description+tabTrigger+content{<![CDATA[ ]]>} --> | |
<!-- Gruntfile.js --> | |
<snippet> | |
<description>Gruntfile.js Skeleton</description> | |
<tabTrigger>grunt</tabTrigger> | |
<content><![CDATA[ | |
module.exports = function(grunt) { | |
// Configure task(s) |
This file contains 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
# Update store_id, store_name and store_url for all existing orders | |
##################################################################### | |
# store_id can be checked with `SELECT * FROM oc_store`. Default store = 0 | |
UPDATE oc_order SET store_id=0, store_name="Store Name", store_url="http://domain.com"; |
This file contains 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
<?php | |
$email = "aamnah@aamnah.com"; | |
$email_neat = strtolower(trim($email)); | |
$email_hash = md5($email_neat); | |
$file_type = 'jpg'; | |
$size = 80; | |
$gravatar = 'http://www.gravatar.com/avatar/'. $email_hash . '.' . $file_type. '?s=' . $size .''; | |
$gravatar_image = '<img src="'. $gravatar . '" />'; |
This file contains 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
<div id="time"></div> |
This file contains 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
<!-- image --> | |
<a href="javascript:play('dog')"><img src="img/dog.png"></img></a> | |
<!-- link --> | |
<a href="javascript:play('dog')">Dog</a> | |
<!-- audio file --> | |
<audio | |
id="dog" | |
src="media/dog.wav" |
This file contains 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/bash | |
### | |
# Author: Aamnah | |
# Link: http://aamnah.com | |
# Description: Install script for Opencart 2.x on a Linux (Ubuntu/Debian) server | |
### | |
# Color Reset | |
Color_Off='\033[0m' # Text Reset |
This file contains 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
chmod 777 config.php | |
chmod 777 admin/config.php | |
chmod 777 image/ | |
chmod 777 image/cache/ | |
chmod 777 image/catalog/ | |
chmod 777 system/cache/ | |
chmod 777 system/logs/ | |
chmod 777 system/download/ | |
chmod 777 system/upload/ |
This file contains 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
################################ | |
# CUSTOM MOTD FOR RASPBERRY PI | |
################################ | |
let upSeconds="$(/usr/bin/cut -d. -f1 /proc/uptime)" | |
let secs=$((${upSeconds}%60)) | |
let mins=$((${upSeconds}/60%60)) | |
let hours=$((${upSeconds}/3600%24)) | |
let days=$((${upSeconds}/86400)) | |
UPTIME=`printf "%d days, %02dh %02dm %02ds" "$days" "$hours" "$mins" "$secs"` |
OlderNewer