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
function getFilesFromDrive() { | |
var sheet = SpreadsheetApp.getActive().getSheetByName('SHEETNAME'); | |
var folders = DriveApp.getFolderById('XXFOLDERIDXX'); | |
sheet.clear(); | |
sheet.appendRow(['Folder', 'Name', 'URL']); | |
var folder = folders.getFolders(); | |
if (folder.hasNext()) { | |
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
PROMPT='%{$fg[red]%}➜ %{$fg[yellow]%}%c%{$reset_color%} %{$fg_bold[blue]%}$(git_prompt_info)%{$fg_bold[blue]%} % :%{$reset_color%}' | |
ZSH_THEME_GIT_PROMPT_PREFIX="git:(%{$fg[red]%}" | |
ZSH_THEME_GIT_PROMPT_SUFFIX="%{$reset_color%}" | |
ZSH_THEME_GIT_PROMPT_DIRTY="%{$fg[blue]%}) %{$fg[yellow]%}✗%{$reset_color%}" | |
ZSH_THEME_GIT_PROMPT_CLEAN="%{$fg[blue]%})" |
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 if ( ! defined( 'FW' ) ) { | |
die( 'Forbidden' ); | |
} | |
$options = array( | |
'main' => array( | |
'type' => 'box', | |
'title' => '', | |
'options' => array( | |
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 | |
function get_absolute_attachment_url( $image_id ) { | |
$url = wp_get_attachment_url( $image_id ); | |
$site_url = site_url(); | |
if(strpos($url, $site_url) === false) { | |
$url = trailingslashit($site_url) . $url; | |
} | |
// or |
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
#!/usr/bin/env bash | |
cd /opt | |
sed -i "s/^\#[ ]deb\-src/deb\-src/" /etc/apt/sources.list.d/nginx-stable-trusty.list | |
apt-get -y update | |
apt-get -y build-dep nginx | |
apt-get -y source nginx | |
nginx_version=`nginx -v 2>&1 | awk '{print $3}' | cut -d '/' -f 2` | |
cd /opt/nginx-$nginx_version/debian/modules |
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 | |
if (!function_exists('cal_days_in_month')) | |
{ | |
function cal_days_in_month($calendar, $month, $year) | |
{ | |
return date('t', mktime(0, 0, 0, $month, 1, $year)); | |
} | |
} |
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
var RawGallery = window.RawGallery || {}; | |
(function($, window, undefined) { | |
var RG = RawGallery; | |
_.templateSettings = { | |
interpolate: /\{\{(.+?)\}\}/g, | |
escape: /\{\{-(.*?)\}\}/g | |
}; | |
_.extend(RG, { |