Skip to content

Instantly share code, notes, and snippets.

View matthlavacka's full-sized avatar
🏠
Working from home

Matt H matthlavacka

🏠
Working from home
View GitHub Profile
@matthlavacka
matthlavacka / fix.sh
Last active October 19, 2016 09:33
Script to fix dyld error
# It looks like the distributed versions of Node and npm live here:
~/.meteor/packages/meteor-tool/1.3.5.1/mt-os.osx.x86_64/dev_bundle/bin/
# To make sure that the executables there are found before any systemwide installed executables,
# you can add them to your $PATH variable like this:
export PATH=~/.meteor/packages/meteor-tool/1.3.5.1/mt-os.osx.x86_64/dev_bundle/bin/:$PATH
# After running the line above, try and see what these say:
which node
which npm
@matthlavacka
matthlavacka / gist:430a0d18caccc1a61dd55d2c53928794
Last active September 29, 2016 09:39 — forked from guilhermef/gist:297680f457f82fb27b3d
Install Thumbor 5.2.1 on Ubuntu 15.04
# sudo su and run the following
sudo aptitude update
# install all dependencies
sudo aptitude -y install \
python-pip \
python2.7-dev \
libssl-dev \
libcurl4-openssl-dev \
@matthlavacka
matthlavacka / vehicle-json.json
Last active September 7, 2016 19:34
Vehicle List
// New
[
{"brand": "Seat", "models": ["Alhambra", "Altea", "Altea XL", "Arosa", "Cordoba", "Cordoba Vario", "Exeo", "Ibiza", "Ibiza ST", "Exeo ST", "Leon", "Leon ST", "Inca", "Mii", "Toledo"]},
{"brand": "Renault", "models": ["Captur", "Clio", "Clio Grandtour", "Espace", "Express", "Fluence", "Grand Espace", "Grand Modus", "Grand Scenic", "Kadjar", "Kangoo", "Kangoo Express", "Koleos", "Laguna", "Laguna Grandtour", "Latitude", "Mascott", "Mégane", "Mégane CC", "Mégane Combi", "Mégane Grandtour", "Mégane Coupé", "Mégane Grandtour", "Mégane Coupé", "Mégane Scénic", "Scénic", "Talisman", "Talisman Grandtour", "Thalia", "Twingo", "Wind"]},
]
// Old
(1998, ’Seat’, ‘Altea’),
(1998, ’Seat’, ‘Altea XL’),
(1998, ’Seat’, ‘Arosa’),
import { Posts } from '../../api/posts/posts.js';
import { Villages } from '../../api/villages/villages.js';
import { Notifications } from '../../api/notifications/notifications.js';
import { Comments } from '../../api/comments/comments.js';
import { Inbox } from '../../api/inbox/inbox.js';
import { Emails } from '../../api/emails/emails.js';
import { Meteor } from 'meteor/meteor';
import { Template } from 'meteor/templating';
import { ReactiveVar } from 'meteor/reactive-var';
console.log('Time now ' + new Date());
const t = new Date();
t.setSeconds(t.getSeconds() + 10);
console.log('Setting job to future in 10 seconds ' + t);
SyncedCron.add({
name: 'aggregateNotifications',
schedule: function (parser) {
// Every 12 hours
return parser.text('every 12 hours');
@matthlavacka
matthlavacka / vkcom_audio_download.py
Created February 21, 2016 02:56 — forked from st4lk/vkcom_audio_download.py
Python: vkontakte.ru (vk.com) audio music downloader
# -*- coding: utf-8 -*-
"""
Скрипт для скачивания музыки с сайта vkontakte.ru (vk.com)
Запуск:
python vkcom_audio_download.py
Принцип работы:
Скрипт проверяет сохраненный access_token. Если его нет или срок истек,
то открывается страница в браузере с запросом на доступ к аккаунту.
<head>
<title>Yak</title>
<!-- To support mobile-devices -->
<meta name="viewport" content="width=device-width, initial-scale=1.0">
</head>
<body>
<div class="navbar navbar-static-top">
<div class="navbar-inner">
<div class="container">