Skip to content

Instantly share code, notes, and snippets.

View mchwalisz's full-sized avatar

Mikołaj Chwalisz mchwalisz

View GitHub Profile
#!/bin/sh
### BEGIN INIT INFO
# Provides: myservice
# Required-Start: $remote_fs $syslog
# Required-Stop: $remote_fs $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Put a short description of the service here
# Description: Put a long description of the service here
@mchwalisz
mchwalisz / ros.bash
Last active August 29, 2015 13:56
Personalized ROS startup script
#!/bin/bash
RP_BASEDIR=~/Code/ros
export TURTLEBOT_BASE=kobuki
export TURTLEBOT_STACKS=hexagons
export TURTLEBOT_3D_SENSOR=kinect
# source /opt/ros/groovy/setup.bash
source /home/opt/ros-hydro-ws/install_isolated/setup.bash
@mchwalisz
mchwalisz / foobar.py
Last active October 7, 2016 07:34
Python: Empty script with docopt
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
foobar.py: Does really cool stuff
Usage:
foobar.py [options] [-q | -v]
foobar.py --config
@mchwalisz
mchwalisz / humidity-arm.rrd
Last active August 29, 2015 14:03
cgp_issue_19
@mchwalisz
mchwalisz / email.sh
Created August 6, 2014 12:42 — forked from fuzzmz/email.sh
#!/bin/sh
### BEGIN INIT INFO
# Provides: SystemEmail
# Required-Start: $remote_fs $syslog
# Required-Stop: $remote_fs $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Send email
# Description: Sends an email at system start and shutdown
### END INIT INFO
import thread
import time
import zmq
# global zmg context
context = zmq.Context.instance()
endpoint = "tcp://*:8888"
# the subscriber thread function
def subscriber(name, address, cnt, subscriptions):
---
# ^^^ YAML documents must begin with the document separator "---"
#
#### Example docblock, I like to put a descriptive comment at the top of my
#### playbooks.
#
# Overview: Playbook to bootstrap a new host for configuration management.
# Applies to: production
# Description:
# Ensures that a host is configured for management with Ansible.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@mchwalisz
mchwalisz / keybase.md
Created April 15, 2015 06:53
keybase.md

Keybase proof

I hereby claim:

  • I am mchwalisz on github.
  • I am mchwalisz (https://keybase.io/mchwalisz) on keybase.
  • I have a public key whose fingerprint is 8A62 1675 1437 B3B5 5CCE 611E 662B 4026 9083 AE1B

To claim this, I am signing this object:

@mchwalisz
mchwalisz / twist.py
Last active October 20, 2015 12:04
Python interface to TWIST sensor testbed
#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""
twist.py: Command line interface to TWIST testbed
Usage:
twist.py [options] [-q | -v] ([-n <nodeid>]... | [--floor <floor>]... | --all )
twist.py --config