Skip to content

Instantly share code, notes, and snippets.

@nagyv
nagyv / gist:e8673fb9344bf6b7fc58
Last active August 29, 2015 14:01
brew install -v --HEAD goaccess 2>&1 failure
$ brew --config
HOMEBREW_VERSION: 0.9.5
ORIGIN: https://github.com/Homebrew/homebrew.git
HEAD: f92e7ec4077ebb226a9637b369db0e294a7afa8e
HOMEBREW_PREFIX: /usr/local
HOMEBREW_CELLAR: /usr/local/Cellar
CPU: quad-core 64-bit ivybridge
OS X: 10.9.2-x86_64
Xcode: 5.1.1
CLT: 5.1.0.0.1.1396320587
@nagyv
nagyv / 0 - odoo logs to sentry
Last active December 5, 2018 06:49 — forked from avoine/gist:2912777
Script to send rsyslog message of OpenERP to Sentry
This gist provides a simple setup to add Sentry logging to OpenERP/Odoo.
As Odoo's logging setup is rather limited, I'm using syslog to collect and forward logs to Sentry.
These scripts should run without any modification on an Ubuntu based server, assuming the paths and user names for openerp match with the ones in the `supervisord.conf` file.
To have rsyslog2sentry run fine, you'll need some python pagkages installed
$ pip install raven loggerglue
@nagyv
nagyv / odoo.ini
Created December 29, 2014 15:44
odoo supervisor ini
[program:odoo]
user=openerp
directory=/home/openerp/odoo
command=odoo.py -c /home/openerp/odoo/openerp_serverrc.prod
environment=PATH="/home/openerp/odoo/venv/bin"
autostart=true
autorestart=true
stopsignal=QUIT
stopwaitsecs=30
startsecs=5
@nagyv
nagyv / rebuild_libreoffice.sh
Last active October 4, 2018 03:40 — forked from lukebranch/rebuild_libreoffice.sh
Rebuild Libreoffice for ubuntu 14.04 trusty with python2 support for python-uno
#!/bin/sh
# we need some fixes from 14.10
# sudo add-apt-repository --enable-source ppa:libreoffice/libreoffice-4-3
sudo add-apt-repository --enable-source ppa:libreoffice/libreoffice-4-3 -y
# fetch this repository
sudo apt-get update -y
# update your libreoffice installation
sudo apt-get install libreoffice python3-uno -y
# get all build dependencies for libreoffice
sudo apt-get build-dep libreoffice -y
@nagyv
nagyv / README.md
Last active September 20, 2016 13:28
Git image diff

What it this for?

Have you ever wandered how to follow changes in images using git? This is a solution for the problem.

How to install

  1. Copy git-imgdiff.sh somewhere under your $PATH. Probably $HOME/bin.
  2. Create the $HOME/.gitattributes file with the following content ~/.gitattributes
@nagyv
nagyv / README.md
Created May 27, 2017 18:32
Mandrill API mocking in Nodejs

A simple way to mock calls to the Mandrill API from nodejs tests. It uses the amazing mockery package.

@nagyv
nagyv / gradlew logs
Created August 30, 2017 22:53
gradlew logs
C:\Users\Viktor\Projects\potzak\android\app\src\main\java\com\potzak\MainApplication.java:8: error: package com.learnium.RNDeviceInfo does not exist
import com.learnium.RNDeviceInfo.RNDeviceInfo;
^
C:\Users\Viktor\Projects\potzak\android\app\src\main\java\com\potzak\MainApplication.java:9: error: package com.lugg.ReactNativeConfig does not exist
import com.lugg.ReactNativeConfig.ReactNativeConfigPackage;
^
C:\Users\Viktor\Projects\potzak\android\app\src\main\java\com\potzak\MainApplication.java:10: error: package com.microsoft.azure.mobile.react.crashes does not exist
import com.microsoft.azure.mobile.react.crashes.RNCrashesPackage;
^
C:\Users\Viktor\Projects\potzak\android\app\src\main\java\com\potzak\MainApplication.java:11: error: package com.microsoft.azure.mobile.react.analytics does not exist
@nagyv
nagyv / WhoopsModal.js
Created September 8, 2017 09:09
Cannot read property 'state' of undefined
import React, { Component } from 'react'
// import PropTypes from 'prop-types';
import { View } from 'react-native'
import {
H1,
Icon,
Button,
Text
} from 'native-base'
import Modal from 'react-native-modal'
@nagyv
nagyv / example.html
Created February 6, 2018 12:15
example html for an RN bug report
<!DOCTYPE html>
<html lang="en">
<head>
<script>
// from: https://github.com/facebook/react-native/issues/11594#issuecomment-274689549
function awaitPostMessage() {
let isReactNativePostMessageReady = !!window.originalPostMessage;
const queue = [];
let currentPostMessageFn = function store(message) {
if (queue.length > 100) queue.shift();
@nagyv
nagyv / 1 - readme.md
Created June 3, 2018 19:58
using Nes with Schmervice

This is a simple example to use Nes with Schmervice in hapipal-like project.

As there might be several susbcription channels, I prefer to separate them by domain, and have a single service that handles all the even passing between different parts of the code.

Example usage:

  // somewhere in a router's handler