Skip to content

Instantly share code, notes, and snippets.

"""
run_with_timeout(
command; log=stdout, timeout = 5*60, name = "",
wait_time = 1, verbose = true
)
Runs `command` and pipes all output to `log`. The process will be terminated after
`timeout` seconds without any output. `name` describes the process in log messages,
and `verbose` determines whether meta-logs ("process started" etc.) will be printed.
"""
function run_with_timeout(
# Set up notification options
notifications:
email:
recipients:
- one@example.com
- other@example.com
# change is when the repo status goes from pass to fail or vice versa
on_success: change
on_failure: always
@DrKrar
DrKrar / README.rst
Created January 26, 2016 21:47 — forked from dupuy/README.rst
Common markup for Markdown and reStructuredText

Markdown and reStructuredText

GitHub supports several lightweight markup languages for documentation; the most popular ones (generally, not just at GitHub) are Markdown and reStructuredText. Markdown is sometimes considered easier to use, and is often preferred when the purpose is simply to generate HTML. On the other hand, reStructuredText is more extensible and powerful, with native support (not just embedded HTML) for tables, as well as things like automatic generation of tables of contents.

@DrKrar
DrKrar / peakdetect.py
Last active August 29, 2015 14:26 — forked from sixtenbe/analytic_wfm.py
Peak detection in Python
import numpy as np
from math import pi, log
import pylab
from scipy import fft, ifft
from scipy.optimize import curve_fit
i = 10000
x = np.linspace(0, 3.5 * pi, i)
y = (0.3*np.sin(x) + np.sin(1.3 * x) + 0.9 * np.sin(4.2 * x) + 0.06 *
np.random.randn(i))