Skip to content

Instantly share code, notes, and snippets.

View wzs's full-sized avatar

Paweł Wrzosek wzs

View GitHub Profile
@wzs
wzs / nbp.js
Created July 14, 2021 14:24
NBP currency rate for Google Sheets
/**
* Gets the NBP currency rate for the first non-holiday day before.
*
* @param {string} currency symbol (ie. "USD")
* @param {string} date in the format "YYYY-MM-DD"
* @return {number} currency rate
* @customfunction
*/
function NBP(currency, date) {
function fetchRate(currency, dateString) {
@wzs
wzs / pre-commit
Last active December 10, 2019 14:29
Prevent from commiting if the staged changes contains 'XXX'
#!/bin/bash
if git commit -v --dry-run | grep 'XXX' >/dev/null 2>&1
then
echo "Cannot commit XXX marker"
exit 1
else
exit 0
fi

Method to determine contacts that are family members

Motivation

In Fam we want to present to the User a list of their's contacts, with potential family members listed at the top. This will be used to find & invite relevant people to the Family.

@wzs
wzs / gist:d9ebf1668e1615cb1a7c
Created December 17, 2014 23:43
keybase.md
### Keybase proof
I hereby claim:
* I am wzs on github.
* I am wzs (https://keybase.io/wzs) on keybase.
* I have a public key whose fingerprint is B5C2 067A 0520 5BCA 4C6F 6F11 7104 7C6A DD2D 7857
To claim this, I am signing this object: