minimal example of using [phantomjs] with [qunit]
$ phantomjs run-qunit.js file://`pwd`/test.html
'waitFor()' finished in 200ms.
Tests completed in 21 milliseconds.
5 tests of 5 passed, 0 failed.
location /aaa/ { | |
# internal; | |
set $upstream ""; | |
set $referer ""; | |
set $ref $arg_ref; | |
set $url $arg_url; | |
set $tohost ""; | |
set $newuri ""; | |
# add_header Content-Type text/plain; |
# This is draft version | |
# so code is ugly | |
# Possible todos: | |
* Code cleanup :) | |
* Accept filenames from command lines | |
* Create new file from date | |
* Create missing Trackpoints (for location based sports, like swimming) | |
* Refactor merge (do believe it might go slow on long distance run) | |
* Update sport name in file |
#!/bin/sh | |
# | |
# Adam Sharp | |
# Aug 21, 2013 | |
# | |
# Usage: Add it to your PATH and `git remove-submodule path/to/submodule`. | |
# | |
# Does the inverse of `git submodule add`: | |
# 1) `deinit` the submodule | |
# 2) Remove the submodule from the index and working directory |
# Setting up dnsmasq for Local Web Development Testing on any Device | |
Please note, these instructions are for OS X Lion. | |
First, you need to get the IP address of your machine on your local network. In OS X, the easiest place to find this is in System Preferences > Network. If you're using DHCP on your local network, you will want to make sure your computer requests the same IP address when it renews it's IP address lease. I recommend configuring the DCHP Reservation settings on your router to accomplish this. Otherwise, you can specify a manual address in your network settings: | |
1. Go to *System Preferences > Network* | |
1. Click *Advanced...* |
just change out app_name for your purposes
openssl genrsa 2048 > app_name-wildcard.key
openssl req -new -x509 -nodes -sha1 -days 3650 -key app_name-wildcard.key > app_name-wildcard.cert
# Common Name (eg, your name or your server's hostname) []:*.app_name.com
openssl x509 -noout -fingerprint -text < app_name-wildcard.cert > app_name-wildcard.info
apt-get install devscripts build-essential | |
apt-get build-dep golang-go | |
wget http://ftp.de.debian.org/debian/pool/main/g/golang/golang_1.3-1.dsc | |
wget http://ftp.de.debian.org/debian/pool/main/g/golang/golang_1.3.orig.tar.gz | |
wget http://ftp.de.debian.org/debian/pool/main/g/golang/golang_1.3-1.debian.tar.xz | |
dpkg-source -x golang_1.3-1.dsc | |
cd golang-1.3/ | |
debuild -us -uc |
# -*- coding: utf-8 -*- | |
""" | |
Скрипт для скачивания музыки с сайта vkontakte.ru (vk.com) | |
Запуск: | |
python vkcom_audio_download.py | |
Принцип работы: | |
Скрипт проверяет сохраненный access_token. Если его нет или срок истек, | |
то открывается страница в браузере с запросом на доступ к аккаунту. |
I use Namecheap.com as a registrar, and they resale SSL Certs from a number of other companies, including Comodo.
These are the steps I went through to set up an SSL cert.
- name: ensure github.com is a known host | |
lineinfile: | |
dest: /root/.ssh/known_hosts | |
create: yes | |
state: present | |
line: "{{ lookup('pipe', 'ssh-keyscan -t rsa github.com') }}" | |
regexp: "^github\\.com" |