Visit https://www.simonfacciol.com/squarespace-to-ghost/ for a guide on how to use this script.
Simon 👋🏻
| document.querySelectorAll("input[type=checkbox]").forEach(c => { c.checked = true; c.onchange(); }); |
Visit https://www.simonfacciol.com/squarespace-to-ghost/ for a guide on how to use this script.
Simon 👋🏻
| chown www-data:www-data -R *; | |
| find . -type d -exec chmod 755 {} \; | |
| find . -type f -exec chmod 644 {} \; |
| * * * * * dokku --rm-container run stats rake scraper:run_scraper | |
| 0 * * * * dokku --rm-container run stats rake scraper:hourly_cleanup | |
| 0 1 * * * dokku --rm-container run stats rake scraper:nightly_cleanup | |
| * * * * * dokku --rm-container run stats rake scraper:backup_check |
| https://github.com/heroku/heroku-buildpack-ruby.git | |
| https://github.com/heroku/heroku-buildpack-chromedriver.git | |
| https://github.com/heroku/heroku-buildpack-google-chrome.git |
| #!/bin/bash | |
| # Author:Andrey Nikishaev | |
| # Modified: Simon Facciol | |
| echo "CHANGELOG" | |
| echo ---------------------- | |
| git for-each-ref --sort=-taggerdate --format '%(tag)-%(*authordate)' refs/tags | grep 'release' | while read RES ; do | |
| IFS='-' read -a arrRES <<< "${RES}" | |
| TAG=${arrRES[0]} | |
| DAT=${arrRES[1]} | |
| echo |
| /** | |
| * Created by simonfacciol on 13/02/16. | |
| */ | |
| var gulp = require('gulp'), | |
| fs = require('fs'), | |
| del = require('del'), | |
| plugins = require('gulp-load-plugins')({ | |
| pattern: ['gulp-*', 'gulp.*'], | |
| replaceString: /\bgulp[\-.]/, | |
| lazy: true, |
| import os | |
| import csv | |
| with open('old-names-new-names.csv', 'rb') as csvfile: | |
| csvreader = csv.reader(csvfile, delimiter=',', quotechar='"') | |
| for row in csvreader: | |
| name = row[0] + '.jpg' | |
| new = row[1] + '.jpg' | |
| if os.path.exists(name): | |
| os.rename(name, new) |
| CREATE DEFINER=`[USER_NAME]`@`%` TRIGGER `[DATABASE_NAME]`.`Slug` BEFORE INSERT ON `[TABLE_NAME]`.`games` FOR EACH ROW | |
| BEGIN | |
| IF NEW.slug IS NULL THEN | |
| SET NEW.slug = LOWER(TRIM(NEW.name)); | |
| SET NEW.slug = REPLACE(NEW.slug, ':', ''); | |
| SET NEW.slug = REPLACE(NEW.slug, ')', ''); | |
| SET NEW.slug = REPLACE(NEW.slug, '(', ''); | |
| SET NEW.slug = REPLACE(NEW.slug, ',', ''); | |
| SET NEW.slug = REPLACE(NEW.slug, '\\', ''); | |
| SET NEW.slug = REPLACE(NEW.slug, '?', ''); |
| import Image | |
| import os | |
| files = [f for f in os.listdir('.') if os.path.isfile(f)] | |
| for file in files: | |
| if file.endswith(('.jpg')): | |
| img = Image.open(os.path.join(os.curdir, file)) | |
| size = img.size | |
| if ((410, 300) != size): | |
| name = file + ' ' |