Skip to content

Instantly share code, notes, and snippets.

View tomkukral's full-sized avatar

Tomáš Kukrál tomkukral

View GitHub Profile
def jobName = ""
def jobNum = ""
Jenkins.instance.getItemByFullName(jobName).getBuildByNumber(jobNum).finish(hudson.model.Result.ABORTED, new java.io.IOException("Aborting build"));
import time
import json
import esp
import machine
def read_dht11(pin):
import dht
d = dht.DHT11(machine.Pin(pin))
@ValdikSS
ValdikSS / gist:d896cebd8e1aafc65b4b
Created July 19, 2014 11:52
thermald config for x220
<?xml version="1.0"?>
<!--
use "man thermal-conf.xml" for details
-->
<!-- BEGIN -->
<ThermalConfiguration>
<Platform>
<Name>Lenovo ThinkPad X220</Name>
<ProductName>*</ProductName>
<Preference>QUIET</Preference>
@KonradIT
KonradIT / readme.md
Last active July 11, 2024 20:46
GoPro Studio for Linux
@noteed
noteed / docker-ovs.md
Last active December 29, 2023 07:07
Docker - Open vSwitch setup
@oskar456
oskar456 / prouting.sh
Last active June 14, 2023 22:19
A simple script to set up policy routing on linux. It's stateless and detects everything automatically, so all you have to do is to run it after every network subsystem change. I run it in postup and postdown hooks in Gentoo network configuration file.
#!/bin/bash
IP="/bin/ip"
function prepare_rt_table() {
local rttables=/etc/iproute2/rt_tables
local iface=$1
[[ "${iface}" = 'lo' ]] && return
if ! egrep -q "\s${iface}\s*"\$ $rttables; then
idx=$(wc -l <$rttables)
@hofmannsven
hofmannsven / README.md
Last active October 22, 2024 13:29
Git CLI Cheatsheet
@jhrcz
jhrcz / kvm-force-blkio-throttle.sh
Last active December 4, 2017 12:00
force cpu and blkio thottle of kvm guests
#!/bin/bash
cat /cgroup/blkio/libvirt/qemu/blkio.throttle.read_bps_device
cat /cgroup/blkio/libvirt/qemu/blkio.throttle.write_bps_device
cat /cgroup/blkio/libvirt/qemu/*/blkio.throttle.read_bps_device
cat /cgroup/blkio/libvirt/qemu/*/blkio.throttle.write_bps_device
# 10MBps
#BPSLIMIT=10485760
@dk8996
dk8996 / navbar-div.html
Last active December 16, 2015 14:38
Blog post about Bootstrap and social icons in the navbar.
<div class="navbar navbar-inverse navbar-fixed-top">
<div class="navbar-inner">
<div class="container">
<button type="button" class="btn btn-navbar" data-toggle="collapse"
data-target=".nav-collapse">
<span class="icon-bar"></span> <span class="icon-bar"></span> <span
class="icon-bar"></span>
</button>
<a class="brand" href="#">{de-encode}</a>
<div class="nav-collapse collapse">

tmux cheatsheet

As configured in my dotfiles.

start new:

tmux

start new with session name: