"devDependencies": {
"connect-livereload": "^0.5.3",
"express": "^4.13.3",
"gulp": "^3.9.0",
"gulp-autoprefixer": "^2.3.1",
"gulp-concat": "^2.6.0",
"gulp-jshint": "^1.11.2",
"gulp-minify-css": "^1.2.0",| #!/usr/bin/env bash | |
| if [ ! -f package.json ]; then | |
| echo "This script must be run from the ghost blog directory" | |
| exit 1 | |
| fi | |
| ZIP_URL=https://ghost.org/zip/ghost-latest.zip | |
| PROJ_DIR=$(pwd) | |
| TMP_DIR=$(mktemp -d -t ghost) |
| @ECHO OFF | |
| CLS | |
| goto CHECK | |
| :CHECK | |
| net session >nul 2>&1 | |
| if %errorLevel% == 0 ( | |
| goto :MENU | |
| ) else ( | |
| echo Checking permission privilege... | |
| ping 1.1.1.1 -n 1 -w 500 > nul |
| $.fn.toggleAttr = function(a, b) { | |
| var c = (b === undefined); | |
| return this.each(function() { | |
| if((c && !$(this).is("["+a+"]")) || (!c && b)) $(this).attr(a,a); | |
| else $(this).removeAttr(a); | |
| }); | |
| }; |
| #!/usr/bin/env bash | |
| read -p "GitHub username: " -ei $(git config --get github.user) USERNAME | |
| read -sp "GitHub password: " PASSWORD | |
| echo | |
| read -p "Submit pull request to user: " TO_USER | |
| read -p "Submit pull request to repository: " TO_REPO | |
| read -p "Submit pull request to branch: " -ei master TO_BRANCH | |
| read -p "Submit pull request from user: " -ei $USERNAME FROM_USER | |
| read -p "Submit pull request from branch: " FROM_BRANCH |
| #!/bin/bash | |
| # Remove old linux | |
| echo $(dpkg --list | grep linux-image | awk '{ print $2 }' | sort -V | sed -n '/'`uname -r`'/q;p') $(dpkg --list | grep linux-headers | awk '{ print $2 }' | sort -V | sed -n '/'"$(uname -r | sed "s/\([0-9.-]*\)-\([^0-9]\+\)/\1/")"'/q;p') | xargs sudo apt-get -y purge |
Our Virtual Machines are provisioned using Vagrant from a Linux base box to run using VirutalBox. If the Hard Disk space runs out and you cannot remove files to free-up space, you can resize the Hard Disk using some VirtualBox and Linux commands.
The following steps assume you've got a set-up like mine, where:
| // url_to_drive.gs | |
| // Google Apps Script | |
| // Allows uploading a URL directly to Google Drive. | |
| // | |
| // Live link: | |
| // https://script.google.com/macros/s/AKfycbzvhbHS4hnWPVBDHjQzZHA0qWq0GR-6hY7TbYsNto6hZ0MeAFZt/exec | |
| // | |
| // Source-code: | |
| // https://gist.github.com/denilsonsa/8134679 | |
| // https://script.google.com/d/1Ye-OEn1bDPcmeKSe4gb0YSK83RPMc4sZJt79SRt-GRY653gm2qVUptoE/edit |
| #!/usr/bin/env bash | |
| # | |
| # Originally from https://gist.github.com/IanVaughan/2902499 | |
| # | |
| # authors: Ian Vaughan | |
| # Jacob Zimmerman | |
| # | |
| # usage: uninstall_gems [<version> ...] | |
| # | |
| # examples: |
I got tired on creating new files manually for each new post a write so I put together this little command line task with Thor.
It creates a new file in the _posts directory with today’s date, parses the parameters to command as the post’s title and adds that as a slug to the new file. It then writes a default yaml template to the file (as specified in the script).
Running thor jekyll:new New and shiny post will for example create the file _posts/2012-12-28-new-and-shiny-post.markdown, populate it with an yaml template and finally open the file in my favorite editor.
Add the following to your Gemfile: