Skip to content

Instantly share code, notes, and snippets.

View danecjensen's full-sized avatar
🎯
Focusing

Dane Jensen danecjensen

🎯
Focusing
View GitHub Profile
from bs4 import BeautifulSoup
import requests
import time
import pandas as pd
import datadotworld as ddw
import re
import string
from pyparsing import anyOpenTag, anyCloseTag
from xml.sax.saxutils import unescape as unescape
unescape_xml_entities = lambda s: unescape(s, {"'": "'", """: '"', " ":" "})
bitnami@ip-10-136-65-200:~$ sudo certbot -d custom.sockclub.com --manual --preferred-challenges dns certonly
Saving debug log to /var/log/letsencrypt/letsencrypt.log
Plugins selected: Authenticator manual, Installer None
Enter email address (used for urgent renewal and security notices) (Enter 'c' to
cancel): danecjensen@gmail.com
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Please read the Terms of Service at
https://letsencrypt.org/documents/LE-SA-v1.2-November-15-2017.pdf. You must
agree in order to register with the ACME server at
@danecjensen
danecjensen / client.py
Created May 6, 2020 20:04 — forked from kylehounslow/client.py
Send and receive images using Flask, Numpy and OpenCV
from __future__ import print_function
import requests
import json
import cv2
addr = 'http://localhost:5000'
test_url = addr + '/api/test'
# prepare headers for http request
content_type = 'image/jpeg'
@danecjensen
danecjensen / shell-starter.sh
Created November 2, 2022 21:13
shell-starter.sh
#!/usr/bin/env bash
set -o errexit
set -o nounset
set -o pipefail
if [[ "${TRACE-0}" == "1" ]]; then
set -o xtrace
fi
if [[ "${1-}" =~ ^-*h(elp)?$ ]]; then
@danecjensen
danecjensen / Chatgpt.md
Created April 21, 2023 22:33
Build the models for marketplace

Based on your description, here's a list of ActiveRecord models you'll need for your Airbnb-like marketplace application:

  1. User
  2. Role
  3. Service
  4. Booking
  5. Review

Now, let's define the models along with their associations: