For MacOS Catalina, visit Install mysql2 on MacOS Catalina
Installing mysql2
gem errors on MacOS Mojave.
Make sure openssl
is installed on Mac via Homebrew.
#!/usr/bin/env bash | |
set -e | |
TEMPORARY="vue-docs.md" | |
GUIDE_PATH="./src/guide/" | |
OUTPUT_EPUB="vue-docs.epub" | |
OUTPUT_HTML="vue-docs.html" | |
git clone --depth=1 https://github.com/vuejs/docs |
# | |
# This program is free software: you can redistribute it and/or modify | |
# it under the terms of the GNU General Public License as published by | |
# the Free Software Foundation, either version 3 of the License, or | |
# (at your option) any later version. | |
# | |
# This program is distributed in the hope that it will be useful, | |
# but WITHOUT ANY WARRANTY; without even the implied warranty of | |
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
# GNU General Public License for more details. |
// Example Scriptable Object. Instance must be placed in Resources folder and have the same name as the class, type of generic parameter must be your class. | |
using UnityEngine; | |
[CreateAssetMenu(fileName = "MySingletonSO")] | |
public class MySingletonSO : SingletonScriptableObject<MySingletonSO> | |
{ | |
// Here goes your data. This class can be called by the static Instance property, which will automatically locate the instance in the Resources folder. | |
} |
module MyWrapperCreator | |
def my_method_wrapper(method_name) | |
original_method = instance_method(method_name) | |
define_method(method_name) do |*args, &block| | |
puts "wrapper :: INI" | |
result = original_method.bind(self).call(*args, &block) | |
puts "wrapper :: END" | |
result |
For MacOS Catalina, visit Install mysql2 on MacOS Catalina
Installing mysql2
gem errors on MacOS Mojave.
Make sure openssl
is installed on Mac via Homebrew.
public static float Noise3D(float x, float y, float z, float frequency, float amplitude, float persistence, int octave, int seed) | |
{ | |
float noise = 0.0f; | |
for (int i = 0; i < octave; ++i) | |
{ | |
// Get all permutations of noise for each individual axis | |
float noiseXY = Mathf.PerlinNoise(x * frequency + seed, y * frequency + seed) * amplitude; | |
float noiseXZ = Mathf.PerlinNoise(x * frequency + seed, z * frequency + seed) * amplitude; | |
float noiseYZ = Mathf.PerlinNoise(y * frequency + seed, z * frequency + seed) * amplitude; |
You're taking your first steps into Ruby
A good introduction to programming in general. Easy on newer programmers.
~/dev/real-world-rails (master) | |
$ ag -G 'config/initializers/' ::DATE_FORMATS | |
apps/accelerated_claims/config/initializers/date_formats.rb | |
1:Date::DATE_FORMATS[:printed] = '%d %B %Y' | |
apps/advocate-defence-payments/config/initializers/date_time.rb | |
2:Date::DATE_FORMATS[:default] = Settings.date_format | |
5:DateTime::DATE_FORMATS[:default] = Settings.date_time_format | |
8:Time::DATE_FORMATS[:default] = Settings.date_time_format |
def lerp(start, stop, step) | |
(stop * step) + (start * (1.0 - step)) | |
end |
angular.module('exceptionOverride', []).factory('$exceptionHandler', function() { | |
return function(exception, cause) { | |
Rollbar.error(exception, {cause: cause}); | |
throw exception; | |
}; | |
}); |