Skip to content

Instantly share code, notes, and snippets.

View ff6347's full-sized avatar
🤖
updating status…

Fabian Morón Zirfas ff6347

🤖
updating status…
View GitHub Profile
@ff6347
ff6347 / Baby-Parse-Extendscript.jsx
Created July 13, 2019 06:17
Baby Parse Edited for Extendscript
/*
Baby Parse
v0.4.1
https://github.com/Rich-Harris/BabyParse
Created by Rich Harris
Maintained by Matt Holt
Based on Papa Parse v4.0.7 by Matt Holt
https://github.com/mholt/PapaParse
@ff6347
ff6347 / index.html
Created July 11, 2019 06:51
Using modules in HTML
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- The above 3 meta tags *must* come first in the head; any other head content must come *after* these tags -->
<title>Page Title</title>
<meta name="description" content="something">
@ff6347
ff6347 / setup_rds_postgis.sql
Created June 24, 2019 12:17 — forked from matthewberryman/setup_rds_postgis.sql
Setup postgis in Amazon RDS
-- taken from http://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Appendix.PostgreSQL.CommonDBATasks.html#Appendix.PostgreSQL.CommonDBATasks.PostGIS
create extension postgis;
create extension fuzzystrmatch;
create extension postgis_tiger_geocoder;
create extension postgis_topology;
alter schema tiger owner to rds_superuser;
alter schema tiger_data owner to rds_superuser;
alter schema topology owner to rds_superuser;
import aws from 'aws-sdk-promise';
import url from 'url';
import https from 'https';
import fs from 'mz/fs';
import _ from 'lodash';
import path from 'path';
import crypto from 'crypto';
(async function() {
@ff6347
ff6347 / index.html
Last active April 29, 2019 06:01
ES6 Modules in the Browser. Run it with `npx reload`
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- The above 3 meta tags *must* come first in the head; any other head content must come *after* these tags -->
<title>Page Title</title>
<meta name="description" content="something">
@ff6347
ff6347 / launch.json
Last active April 3, 2019 10:51
nodemon and vscode debugger
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"type": "node",
"request": "attach",
const sqlQueryFail = this.createQueryBuilder('bathingspot')
    // .where(`"bathingspot"."userId" = ${userId}`)
    .where('bathingspot.userId = :id', {id: userId})
    .andWhere('bathingspot.id = :id', {id: spotId}).getSql();
    console.log('failing query 1', sqlQueryFail);

failing query

@ff6347
ff6347 / script.js
Last active March 15, 2019 05:45 — forked from romanlab/script.js
basic node js script for github actions (great pattern to check if we are a module or cli)
const program = require('commander')
const fs = require('fs')
async function doSomething(arg) { return arg }
async function main() {
const event = JSON.parse(fs.readFileSync('/github/workflow/event.json', 'utf8'))
const firstArg = program.firstArg
@ff6347
ff6347 / webpack.banner.js
Created February 28, 2019 04:49 — forked from kevinSuttle/webpack.banner.js
Webpack auto-injecting banner into each file
const pkg = require('./package.json');
const moment = require('moment');
const localTimeZone = Intl.DateTimeFormat().resolvedOptions().timeZone
const timeStamp = moment().format('LLLL');
const banner = `
Generated on ${timeStamp} - ${localTimeZone}
Description: ${pkg.description}
Package: ${pkg.name}
Version: v${pkg.version}
Contributors: ${pkg.contributors.map(function(contributor){ return contributor})}
{
"extends": [
"airbnb-base",
"plugin:@typescript-eslint/recommended",
"plugin:import/recommended",
"plugin:import/typescript",
"plugin:prettier/recommended"
],
"rules": {
"quotes": [