This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#mylib.pyx | |
import pandas as pd | |
df = pd.DataFrame({ 'A' : 1., | |
'B' : pd.Timestamp('20130102'), | |
'C' : pd.Series(1, index=list(range(4)), dtype='float32'), | |
'D' : pd.Series([1, 2, 1, 2], dtype='int32'), | |
'E' : pd.Categorical(["test", "train", "test", "train"]), | |
'F' : 'foo' }) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import setuptools | |
import sys, io, os, glob | |
from setuptools import setup, find_packages, Extension | |
# In python < 2.7.4, a lazy loading of package `pbr` will break | |
# setuptools if some other modules registered functions in `atexit`. | |
# solution from: http://bugs.python.org/issue15881#msg170215 | |
try: | |
import multiprocessing # noqa | |
except ImportError: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Demo json + libcurl cpp program | |
Copyright (C) 2016 Michael Gugino | |
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 2 | |
of the License, or (at your option) any later version. | |
This program is distributed in the hope that it will be useful, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
https://askubuntu.com/questions/515407/how-recipe-to-build-only-one-kernel-module |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
parent: | |
{% for item in childern %} | |
name: {{ item.name }} | |
port: {% if item.proto == 'https' %}443{% else %}80{% endif %} | |
things: | |
{% for t in item.things %} | |
- prepend-something{{ t }} | |
{% endfor %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[OSEv3:children] | |
masters | |
nodes | |
etcd | |
[OSEv3:vars] | |
ansible_ssh_user=fedora | |
ansible_python_interpreter=/usr/bin/python3 | |
become=True | |
openshift_deployment_type=origin |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- name: do x | |
x: | |
something: "{{ l_do_x_var }}" | |
vars: | |
l_do_x_default: "{{ big_ugly_registered_var.stat.something[1] }}" | |
l_do_x_var: "{{ my_inventory_var | default(l_do_x_default) }}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- hosts: all # Never a good idea to use all group unless testing | |
sudo: yes # don't do this, use inventory to set the ansible_become=True variable. | |
tasks: | |
- name: Cat inputs out of splunk in opt | |
slurp: | |
src: "{{ splunk_inputs_file }}" | |
register: splunk_inputs_file_slurp | |
when: | |
- ansible_distribution == 'RedHat' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
xxx="go1.18.3" | |
xxx2="go1.10.2" | |
str_to_array() { | |
local IFS='.' | |
local NEW_ARRAY=(0 0 0 0) | |
local version_part_index=0 | |
for i in $1; do |
OlderNewer