Skip to content

Instantly share code, notes, and snippets.

View wzin's full-sized avatar
💭
making internetz 📨

Wojciech Ziniewicz wzin

💭
making internetz 📨
View GitHub Profile
@wzin
wzin / gist:61865931953081dd7a346ec9471296da
Last active December 12, 2019 11:44
Ubuntu 18.04 + i3wm + xfce4-panel
# This file has been auto-generated by i3-config-wizard(1).
# It will not be overwritten, so edit it as you like.
#
# Should you change your keyboard layout some time, delete
# this file and re-run i3-config-wizard(1).
#
# i3 config file (v4)
#
# Please see https://i3wm.org/docs/userguide.html for a complete reference!
@wzin
wzin / gist:6d52adf6d80f5fcb7d62e72b6ba5488b
Created April 27, 2018 12:22
Automatic-scaling setup for Ubuntu with dual monitor setup (hidpi + nonhidpi) : QHD+ 3200x1800 and a FullHD 1920x1080
The script:
#!/bin/bash
# eDP-1 connected primary 3200x1800+320+2160 (normal left inverted right x axis y axis) 294mm x 165mm
# DP-1 connected 3840x2160+0+0 (normal left inverted right x axis y axis) 521mm x 293mm
xhost +
export DISPLAY=:1
export XAUTHORITY=$(ps -C Xorg -f --no-header | sed -n 's/.*-auth //; s/ -[^ ].*//; p' | tail -1)
@wzin
wzin / gist:bd32463788cc1a3b2eb5f351e23bc34a
Created March 30, 2017 13:28
Monitoring influx metrics with zabbix
# howto
- know your metric (events vs sampled measurements)
- create grafana dashboard for that
- define data ranges
- understand the data and define tresholds for triggers
- make sure you have a way to monitor your numbers
- start sampling numbers with items
- apply derivative (delta) or integral type (sum over time) of function on the data to detect errors
# influx samples (sampled every 10 seconds):
@wzin
wzin / gist:8a09ef8c12fe3f812d581aeeae37ac66
Last active February 23, 2017 14:54
Continuous integration basics
WIKI: `In software engineering, continuous integration (CI) is the practice of merging all developer working copies to a shared mainline several times a day`
as many as ten times a day
**Non-continuous integration**
- people work in separate branches - project gets fragmented to multiple siloed branches
- N teams working separately on a product
- they integrate every 3 months
- each feature is tested separately with automtaed tests and tester
- integration stats:
- 100 conflicts
Graphics Feature Status
Canvas: Software only, hardware acceleration unavailable
Flash: Software only, hardware acceleration unavailable
Flash Stage3D: Software only, hardware acceleration unavailable
Flash Stage3D Baseline profile: Software only, hardware acceleration unavailable
Compositing: Software only, hardware acceleration unavailable
Rasterization: Software only, hardware acceleration unavailable
Threaded Rasterization: Unavailable
Video Decode: Software only, hardware acceleration unavailable
Video Encode: Software only, hardware acceleration unavailable
@wzin
wzin / gist:119af2db31a823d74932
Created October 17, 2014 11:04
Nvidia 9800GT
Graphics Feature Status
Canvas: Software only, hardware acceleration unavailable
Flash: Software only, hardware acceleration unavailable
Flash Stage3D: Software only, hardware acceleration unavailable
Flash Stage3D Baseline profile: Software only, hardware acceleration unavailable
Compositing: Hardware accelerated and threaded
Rasterization: Software only, hardware acceleration unavailable
Threaded Rasterization: Enabled
Video Decode: Software only, hardware acceleration unavailable
Video Encode: Hardware accelerated
@wzin
wzin / gist:e6ca014a038d5a110c1a
Created October 17, 2014 11:02
Nvidia k5000
Graphics Feature Status
Canvas: Software only, hardware acceleration unavailable
Flash: Software only, hardware acceleration unavailable
Flash Stage3D: Software only, hardware acceleration unavailable
Flash Stage3D Baseline profile: Software only, hardware acceleration unavailable
Compositing: Hardware accelerated and threaded
Rasterization: Software only, hardware acceleration unavailable
Threaded Rasterization: Enabled
Video Decode: Software only, hardware acceleration unavailable
Video Encode: Hardware accelerated
@wzin
wzin / robot.js
Created December 5, 2012 17:35 — forked from AndreMeira/robot.js
wzind
//FightCode can only understand your robot
//if its class is called Robot
var id;
var Robot = function(robot) {
id = this.id;
};
Robot.prototype.onIdle = function(ev) {
var robot = ev.robot;
@wzin
wzin / robot.js
Created December 5, 2012 17:25
wzinb
//FightCode can only understand your robot
//if its class is called Robot
var Robot = function(robot) {
};
Robot.prototype.onIdle = function(ev) {
var robot = ev.robot;
robot.ahead(10);
@wzin
wzin / robot.js
Created December 5, 2012 10:57
wzina
//FightCode can only understand your robot
//if its class is called Robot
var Robot = function(robot) {
};
Robot.prototype.onIdle = function(ev) {
var robot = ev.robot;
robot.ahead(100);