Skip to content

Instantly share code, notes, and snippets.

View join.py
import multiprocessing
from multiprocessing import Value, Pool
from concurrent.futures import ThreadPoolExecutor, ProcessPoolExecutor
import pandas as pd
from pathlib import Path
import sys
output_csv = 'output.csv'
base_dir = 'base_dir'
View gist:182e06fc95f7a9b86388fb3276fa2adb
from concurrent.futures import ThreadPoolExecutor, ProcessPoolExecutor
import pandas as pd
from pathlib import Path
import sys
base_dir = sys.argv[1]
output_csv = sys.argv[2]
files = Path(base_dir).rglob('*.csv')
def read_file(file):
View pubkey
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQCjKxZ7tM25ucBjc+k9foQ2Jrv/vo9OpWv4i89IkFtxv5RYGE6NQqWazoris1fyByhT7hQONPZP2tFELKrg+rFOWSd5nTbZORdSfJIQLUe2W36oc/cfw0ZCRYxXundD1v/8YoxEzmjcgrzi75811+T8lo6OrGFPv3aXQb0mOcN++rRH89ee30EZYorkouGdYs5VG0cIoCF52LdeURC0s9TYs5PGV7It5EJn3My1B1Qq02VvO9q9bZRKK9uShj19zL0wKg2jpdwmc1CDQUvCFvDLoALr+Aop+EQnLn5ZLI7IxwoeiUpXyCrMw/10aCZWD4bxYZMO+cZ7VKD09ZqsvFp+0eYkAulOwuPLMeaYD9+Qckm+A9gmw7/iDaZM+o0N1JBIRgbShZPm7yiMKepBAvY6dVJ+rQGJ3eIP+RidDmi3SAVZcZVchuq/Z7egPNAsL1/PtHxXYo1mbqpaGqiga8sKgLhCz0LkoJXVMyOMHlX0unv3riPi2at3XzF6gvyz/H8= viroos@Maciejs-MacBook-Pro.local
@viroos
viroos / gist:1242279
Created Sep 26, 2011
This D-trace script lists all run programs with their arguments - works with OSX
View gist:1242279
#!/usr/sbin/dtrace -C -s
#pragma D option quiet
proc::posix_spawn:exec-success,proc::__mac_execve:exec-success
{
this->isx64=(curproc->p_flag & P_LP64)!=0;
#define SELECT_64_86(x64, x86) (this->isx64 ? (x64) : (x86))
#define GET_POINTER(base, offset) (user_addr_t)SELECT_64_86(*(uint64_t*)((base)+sizeof(uint64_t)*(offset)), *(uint32_t*)((base)+sizeof(uint32_t)*(offset)))
View keybase.md

Keybase proof

I hereby claim:

  • I am viroos on github.
  • I am maciejsawicki (https://keybase.io/maciejsawicki) on keybase.
  • I have a public key whose fingerprint is 517B 99C3 2FCE 2835 9C53 7A29 DA2B 23C8 9DC6 889A

To claim this, I am signing this object:

View gist:a06c251c740f33a4d485bda8d2c3ee9f
viroos@ubuntu-test:~/core-infra$ kubectl describe pvc mypvc
Name: mypvc
Namespace: default
StorageClass: default
Status: Pending
Volume:
Labels: <none>
Annotations: kubectl.kubernetes.io/last-applied-configuration={"apiVersion":"v1","kind":"PersistentVolumeClaim","metadata":{"annotations":{"volume.beta.kubernetes.io/storage-provisioner":"kubernetes.io/azure-file"...
volume.beta.kubernetes.io/storage-provisioner=kubernetes.io/azure-disk
Capacity:
View gist:f536f17a8af425674fd3d64f52931bde
viroos@ubuntu-test:~/core-infra$ kubectl get sc -o yaml --export default
apiVersion: storage.k8s.io/v1
kind: StorageClass
metadata:
annotations:
kubectl.kubernetes.io/last-applied-configuration: |
{"apiVersion":"storage.k8s.io/v1","kind":"StorageClass","metadata":{"annotations":{"storageclass.beta.kubernetes.io/is-default-class":"true"},"creationTimestamp":"2017-10-19T11:48:48Z","labels":{"kubernetes.io/cluster-service":"true"},"name":"default","namespace":"","resourceVersion":"220","selfLink":"/apis/storage.k8s.io/v1/storageclasses/default","uid":"7821c002-b4c3-11e7-9b54-000d3a03a7b3"},"provisioner":"kubernetes.io/azure-disk"}
storageclass.beta.kubernetes.io/is-default-class: "true"
creationTimestamp: null
labels:
View gist:12bf6388920f930e8d3c663ed5d6a1d4
viroos@ubuntu-test:~/core-infra$ kubectl get pvc mypvc -o yaml --export
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
annotations:
kubectl.kubernetes.io/last-applied-configuration: |
{"apiVersion":"v1","kind":"PersistentVolumeClaim","metadata":{"annotations":{"volume.beta.kubernetes.io/storage-provisioner":"kubernetes.io/azure-file"},"creationTimestamp":null,"name":"mypvc","namespace":"default","selfLink":"/api/v1/namespaces/default/persistentvolumeclaims/mypvc"},"spec":{"accessModes":["ReadWriteOnce"],"resources":{"requests":{"storage":"10Gi"}}},"status":{}}
volume.beta.kubernetes.io/storage-provisioner: kubernetes.io/azure-disk
creationTimestamp: null
name: mypvc
View plugins.txt
metrics:3.1.2.10
workflow-cps-global-lib:2.8
credentials-binding:1.12
credentials:2.1.14
variant:1.1
jclouds-jenkins:2.14
cloud-stats:0.12
durable-task:1.14
icon-shim:2.0.3
pipeline-stage-view:2.8
@viroos
viroos / ios_tamplate
Created Mar 10, 2013
Polidea ios project template