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 gulp = require('gulp'), | |
less = require('gulp-less'), | |
livereload = require('gulp-livereload'), | |
notify = require('gulp-notify'); | |
minifycss = require('gulp-minify-css'); | |
gutil = require('gulp-util'); | |
gulp.task('less', function() { | |
return gulp.src(['../blog/css/*.less'], {base: '../blog/css/'}) | |
.pipe(less().on('error', function(err){ |
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
git remote set-url origin git@github.com:user/repo.git |
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 | |
# Big thanks to @sam_h for this! Works like a charm. | |
# | |
# This script assumes you have ssh access to a remote server | |
# Both databases are backed up to sql files in the same directory | |
# this script is executed from. | |
# Usage: | |
# 1. Make sure this file is executable with `chmod +x mysqlsync` | |
# 2. Set the credentials for the variables at the top |
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 ($_SERVER['SERVER_NAME'] == 'local.sitename') | |
{ | |
return array( | |
'server' => 'localhost', | |
'user' => 'user', | |
'password' => 'password', | |
'database' => 'database', | |
'tablePrefix' => 'craft', |
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 | |
return array( | |
'domain.com' => array( | |
//'devMode' => true, | |
'omitScriptNameInUrls' => true, | |
'environmentVariables' => array( | |
'siteUrl' => 'http://domain.com/', | |
'fileSystemPath' => '', | |
) |
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
# | |
brew tap exolnet/homebrew-deprecated | |
brew install php@5.6 |
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 exp_members | |
SET password = SHA1('pass123') | |
WHERE member_id = 1 |
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
{% for block in entry.pageBuilder %} | |
{% switch block.type %} | |
{% case block.type %} | |
{% include "pages/_parts/_" ~ block.type ~ ".twig" %} | |
{% endswitch %} | |
{% endfor %} |
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
<script lang="js" defer> | |
let referrer = document.referrer; | |
let location = window.location; | |
let userAgent = navigator.userAgent; | |
let userAgentData = navigator.userAgentData; | |
console.log(location, userAgent, userAgentData); | |
let person = { | |
referrer: referrer, |