Skip to content

Instantly share code, notes, and snippets.

View laughingman7743's full-sized avatar
🤣

laughingman7743

🤣
  • Niihama-shi
  • 03:55 (UTC +09:00)
View GitHub Profile
@laughingman7743
laughingman7743 / schema.cue
Last active June 19, 2022 15:40
cue import -f -p argoworkflow -l '#ArgoWorkflow:' pkg/argoworkflow/schema.json
package argoworkflow
#ArgoWorkflow: {
@jsonschema(schema="http://json-schema.org/schema#")
(#["io.argoproj.workflow.v1alpha1.ClusterWorkflowTemplate"] | #["io.argoproj.workflow.v1alpha1.CronWorkflow"] | #["io.argoproj.workflow.v1alpha1.Workflow"] | #["io.argoproj.workflow.v1alpha1.WorkflowEventBinding"] | #["io.argoproj.workflow.v1alpha1.WorkflowTemplate"]) & {
@jsonschema(id="http://workflows.argoproj.io/workflows.json")
...
}
#: "eventsource.CreateEventSourceRequest": {
@laughingman7743
laughingman7743 / redshift_s3_util.py
Last active March 15, 2022 15:25
redshift merge unload file
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import argparse
import gzip
import json
import os
from boto.s3.connection import S3Connection
from boto.s3.key import Key
import cStringIO
@laughingman7743
laughingman7743 / .gitignore
Last active August 12, 2021 13:46
Terraform wrapper python
.idea
*.iml
*.tfstate
*.tfstate.backup
.terraform
*/*/*/__*.tf
!*/*/_template/__*.tf
Pipfile.lock
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import boto3
SCRIPT_RUNNER_JAR = 's3://us-east-1.elasticmapreduce/libs/script-runner/script-runner.jar'
BASE_ARGS_HIVE_STEP = [
'/usr/share/aws/emr/scripts/hive-script',
'--run-hive-script',
'--args',
@laughingman7743
laughingman7743 / Pipfile
Last active April 29, 2019 10:49
Triggering DAGs with Python script
[[source]]
name = "pypi"
url = "https://pypi.org/simple"
verify_ssl = true
[dev-packages]
[packages]
google-api-python-client = "*"
requests = "*"
@laughingman7743
laughingman7743 / Pipfile
Created September 22, 2018 15:24
PyAthena performance
[[source]]
url = "https://pypi.org/simple"
verify_ssl = true
name = "pypi"
[packages]
pandas = "*"
pyathena = {git = "https://github.com/laughingman7743/PyAthena.git", ref = "add_pandas_cursor"}
[dev-packages]
FROM redash/redash:1.0.0.b2521
COPY ./supervisord.conf /opt/redash/supervisord/supervisord.conf
COPY ./athena.py /opt/redash/current/redash/query_runner/athena.py
RUN sed -i -e "s/'Copy of/u'Copy of/g" /opt/redash/current/redash/models.py \
&& apt-get update \
&& apt-get install -y software-properties-common \
&& add-apt-repository ppa:openjdk-r/ppa \
&& apt-get update \
# Unless explicitly stated otherwise all files in this repository are licensed
# under the Apache License Version 2.0.
# This product includes software developed at Datadog (https://www.datadoghq.com/).
# Copyright 2017 Datadog, Inc.
from __future__ import print_function
import base64
import gzip
import json
import logging
// ==UserScript==
// @name Tumblr Adblock
// @namespace com.tumblr.laughingman7743
// @author laughingman7743
// @version 0.0.4
// @homepage http://laughingman7743.tumblr.com/
// @description 広告は過去の遺物です!
// @run-at ducument-start
// @include http://www.tumblr.com/dashboard
// @include https://www.tumblr.com/dashboard
# Oracle
export ORACLE_HOME=~/bin/oracle/instantclient_11_2
export PATH=$ORACLE_HOME:$PATH
export DYLD_LIBRARY_PATH=$ORACLE_HOME
export LD_LIBRARY_PATH=$ORACLE_HOME