I hereby claim:
- I am smeevil on github.
- I am smeevil (https://keybase.io/smeevil) on keybase.
- I have a public key ASBOjzbEMuSL7Dm11vlW5GwW6-DgFhuclmXHjCU7X3gc-Qo
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
1. In Library/LaunchDaemons create a file named limit.maxfiles.plist and paste the following in (feel free to change the two numbers (which are the soft and hard limits, respectively): | |
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" | |
"http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>Label</key> | |
<string>limit.maxfiles</string> | |
<key>ProgramArguments</key> |
-server | |
-Xms2048m | |
-Xmx2048m | |
-XX:NewSize=512m | |
-XX:MaxNewSize=512m | |
-XX:PermSize=512m | |
-XX:MaxPermSize=512m | |
-XX:+UseParNewGC | |
-XX:ParallelGCThreads=4 | |
-XX:MaxTenuringThreshold=1 |
In phoenix when using a hidden field that should contain the value of a boolean with "<%= hidden_input f, :anonymous %>" it renders the following : | |
When true : | |
<input id="investment_anonymous" name="investment[anonymous]" type="hidden" value="value"> | |
When false : | |
<input id="investment_anonymous" name="investment[anonymous]" type="hidden"> | |
I would expect it to render the following : |
defmodule Sheep.PriceFormatter do | |
def format(number) when is_integer(number) do | |
"€ " <> (number |> set_decimal |> Float.to_string(decimals: 2) |> set_separators) | |
end | |
def format(not_a_number) do | |
string_number = not_a_number |> to_string |> String.replace(~r/\D/, "") | |
{number, _} = Integer.parse(string_number) | |
number |> format | |
end |
public static float GetAngleOfTransformToSelf(Transform other, Transform origin, bool debug) { | |
var angle = (Math.Atan2(other.position.z - origin.position.z, other.position.x - origin.position.x)*Mathf.Rad2Deg); | |
angle += origin.rotation.eulerAngles.y; | |
angle -= 90; | |
while (angle > 180) angle -= 360; | |
if (!debug) return (float) angle; | |
Debug.Log(string.Format("angle orgin {0} to {1} : {2}", origin, other, angle), origin); | |
Debug.DrawLine(origin.position, other.position, Color.white, 1.0f); | |
return (float)angle; |
str="You shall not not pass" | |
if str == "Somehow it does" || "But why is that?" | |
console.log "I passed with no problems ??" | |
str="You shall not not pass" | |
if str == ("I cannot pass anymore" || "Me either") | |
console.log "This indeed never happens" |
// ==UserScript== | |
// @name Minimal Irc Cloud | |
// @namespace http://govannon.nl/ | |
// @version 0.1 | |
// @description Add a button to toggle minimal mode for irc cloud | |
// @author Smeevil | |
// @match https://www.irccloud.com | |
// @grant none | |
// ==/UserScript== | |
setTimeout(function() { |
Template.foo.rendered = -> | |
@_mySharedFunction = -> | |
console.log "yeah baby" | |
Template.foo.events | |
'click .something': (e, template)-> | |
template._mySharedFunction() | |
Template.foo.helpers | |
myHelper: -> |
Template.chatLine.helpers | |
username: -> | |
username = userIdsToUserNames[@userId] | |
return username if username | |
console.log "searching for id #{@userId}" | |
user = Meteor.users.findOne(_id: @userId) | |
if user? | |
userIdsToUserNames[@userId] = user.username | |
return user.username | |
else |