Skip to content

Instantly share code, notes, and snippets.

@veprbl
veprbl / gist:9ab33daa07b68c28671c
Created May 16, 2014 17:08
0001-OSX-allow-.-configure-with-only-Command-Line-Tools.patch
From 1b59f4b4edbc66c1afce60dc4c50302259bd8687 Mon Sep 17 00:00:00 2001
From: Dmitry Kalinkin <[email protected]>
Date: Tue, 13 May 2014 21:15:29 +0400
Subject: [PATCH] OSX: allow ./configure with only Command Line Tools
As it is now, ROOT can't be built with Cocoa and ./configure without full Xcode
installation. The problem is that Command Line Tools don't provide SDK the way
Xcode does. This patch allows detecting system-wide frameworks available at
/System/... .
---
"""
K/A = 0.307075 MeV g^-1 cm^2
-dE/dX = K/A z^2 Z / \beta^2 [0.5*ln(2 m_e \beta^2 \gamma^2 T_{max}/I^2) - \beta^2 - \delta(\beta \gama)/2]
z^2 = 1
Z = 1
p = 850 MeV
M = 139.6 MeV
\gamma = sqrt(1+(p/M)^2) = 6.17
#!/usr/bin/env python3
"""
Copyright (c) 2010, Dmitry
All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
1) Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
2) Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
[Unit]
Description=Gitlab Resque Worker
Requires=redis.service
After=redis.service
Wants=postfix.service mysqld.service
[Service]
Type=forking
User=git
WorkingDirectory=/home/git/gitlab
@veprbl
veprbl / html5_valid_elements.js
Created August 10, 2011 07:28
TinyMCE valid_elements setting for HTML5
valid_elements : ""
+"@[accesskey|draggable|style|class|hidden|tabindex|contenteditable|id|title|contextmenu|lang|dir<ltr?rtl|spellcheck|"
+"onabort|onerror|onmousewheel|onblur|onfocus|onpause|oncanplay|onformchange|onplay|oncanplaythrough|onforminput|onplaying|onchange|oninput|onprogress|onclick|oninvalid|onratechange|oncontextmenu|onkeydown|onreadystatechange|ondblclick|onkeypress|onscroll|ondrag|onkeyup|onseeked|ondragend|onload|onseeking|ondragenter|onloadeddata|onselect|ondragleave|onloadedmetadata|onshow|ondragover|onloadstart|onstalled|ondragstart|onmousedown|onsubmit|ondrop|onmousemove|onsuspend|ondurationmouseout|ontimeupdate|onemptied|onmouseover|onvolumechange|onended|onmouseup|onwaiting],"
+"a[target<_blank?_self?_top?_parent|ping|media|href|hreflang|type"
+"|rel<alternate?archives?author?bookmark?external?feed?first?help?index?last?license?next?nofollow?noreferrer?prev?search?sidebar?tag?up"
+"],"
+"abbr,"
+"address,"
+"area[alt|coords|shape|href|target<_blank?_self?_top?_parent|ping|media