Skip to content

Instantly share code, notes, and snippets.

Jordan Schatz shofetim

Block or report user

Report or block shofetim

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View gist:18a9bcb366c36b4915470eb1d5d234dc
var Comment = {
oninit: function (vnode) {
this.comment = vnode.attrs;
},
view: function () {
var item, extra, that;
that = this;
item = this.comment;
if (item.children.length == 0) {
return m("li", {key: item.id}, [
View script.js
"use strict";
var log = function(msg) {
console.log(msg);
};
var SelectWidget = {},
App = {},
path = [],
data = {
phone: {
View boundary_scanner.md

My mappings:

{
  "abstract": {
    "type": "text",
    "term_vector": "with_positions_offsets"
  },
  "app_country": {
    "type": "text",
View result.js
function parseLabel(label, r) {
const res = r || [];
res.push(label.label_name.replace(/[,\s]+$/g, '').trim())
if (label.label_child) {
parseLabel(label.label_child, res)
}
return res.join(', ');
}
classifications = parseLabel(result._source.classifications[0])
View index.php
<?php
#exit;
#$ua=$_SERVER['HTTP_USER_AGENT'];
#if ($ua == 'GuzzleHttp/6.2.0 curl/7.35.0 PHP/5.5.9-1ubuntu4.17') {
#header($_SERVER["SERVER_PROTOCOL"]." 404 Not Found");
#header("Status: 404 Not Found");
#$_SERVER['REDIRECT_STATUS'] = 404;
#exit;
View index.js
var https = require('https'),
http = require('http'),
url = require('url'),
restify = require('restify'),
FeedParser = require('feedparser'),
log = console.log.bind(console);
var get = (str, callback) => {
var handler = res => callback(res),
endpoint = url.parse(str),
View bobosales-backup.sh
export PGPASSWORD=redacted
export AWS_ACCESS_KEY_ID=redacted
export AWS_DEFAULT_REGION=us-west-2
export AWS_SECRET_ACCESS_KEY=redacted
pg_dump -h shops-ksl-com.cxpx7kkpqtcv.us-west-2.rds.amazonaws.com -U redacted redacted | gzip | mpipe ~~/stor/bobosales/`date +%Y-%m-%d`-backup.sql.gz
easy_install-2.7 awscli
aws s3 sync s3://images.bobosales.com/ images/
tar -cf images.tar images
gzip images.tar
mput -f images.tar.gz ~~/stor/bobosales/images.tar.gz
View tmp.js
var bf5 = {};
bf5.util = {
getQueryParameter: function (name) {
var url = window.location.href;
name = name.replace(/[\[\]]/g, "\\$&");
var regex = new RegExp("[?&]" + name + "(=([^&#]*)|&|#|$)"),
results = regex.exec(url);
if (!results) return null;
if (!results[2]) return "";
View test-notes.md
View dashboard.html
<!--# include file="/partials/reseller-header.html" -->
<div class="container-fluid">
<div class="row">
<div class="col-sm-12 main">
<center>
<img src="/partials/dashboard.png">
</center>
</div>
</div>
</div>
You can’t perform that action at this time.