Skip to content

Instantly share code, notes, and snippets.

View technoplato's full-sized avatar

Michael Lustig technoplato

View GitHub Profile
{"lastUpload":"2020-07-16T18:57:23.032Z","extensionVersion":"v3.4.3"}
* optional: Firebase Login with Instagram
debugging: https://instagram-auth.appspot.com/ (this site doesn't work)
may be related:
https://status.firebase.google.com/incident/Authentication/18002
https://github.com/firebase/firebaseui-web/issues/30
Grab all pictures and user info
implement authorization window:
https://developers.facebook.com/docs/instagram-basic-display-api/overview#authorization-window
https://developers.facebook.com/docs/instagram-basic-display-api/guides/getting-access-tokens-and-permissions
@technoplato
technoplato / keybase.md
Created October 22, 2019 03:31
keybase.md

Keybase proof

I hereby claim:

  • I am technoplato on github.
  • I am technoplato (https://keybase.io/technoplato) on keybase.
  • I have a public key ASAIUNR5KORAOEpBaN-B0YXWTGEtH9PiYmCoAMAXfDyKRAo

To claim this, I am signing this object:

@technoplato
technoplato / youtube-upload.scpt
Created October 17, 2019 16:33
YouTube Upload - AppleScript - Brute Force
activate application "Safari Technology Preview"
tell application "Safari Technology Preview"
tell document 1
set the URL to "https://youtube.com/upload"
delay 2
do JavaScript "document.getElementById('start-upload-button-single').click()"
end tell
end tell
tell application "System Events"
@technoplato
technoplato / Welcome file.md
Last active October 5, 2019 04:01
Welcome file

Gone from StackEdit!

Hi! I'm your first Markdown file in StackEdit. If you want to learn about StackEdit, you can read me. If you want to play with Markdown, you can edit me. Once you have finished with me, you can create new files by opening the file explorer on the left corner of the navigation bar.

Files

StackEdit stores your files in your browser, which means all your files are automatically saved locally and are accessible offline!

Create files and folders

@technoplato
technoplato / upload-video.py
Last active October 4, 2019 17:58
Upload Video to YouTube
#!/usr/local/bin/python3
'''
This script is a slightly modified version of the one on this page: https://developers.google.com/youtube/v3/guides/uploading_a_video
As I mention in this annotation, this script is modified for python3 https://hyp.is/jUS8hObPEem-SP9iESMhsg/developers.google.com/youtube/v3/docs
Gist: https://gist.github.com/technoplato/4d28f4f308ea7c5fe20bd23e751e9e60
'''
import http.client
import httplib2
@technoplato
technoplato / attempt1.swift
Last active October 4, 2019 18:04
YouTube Video Upload Swift OAuth2
import Foundation
import Alamofire
// I __think__ this actually does work, I was just providing an inavlid token.
// I've now used the upload-video.py script below that generates a token in the folder you run the script (as long as you've got credentials setup in that directory)
// Using that token, this script works. Now I just need to figure out how to add the name, description, tags, etc.
func postVideoToYouTube(callback: (Bool) -> Void){
let url = "https://www.googleapis.com/upload/youtube/v3/videos?part=id"
@technoplato
technoplato / plainascanbe.js
Last active April 2, 2020 14:43
Infinite Scrolling List Flavors
import React, { useState, useEffect } from 'react'
import {
SafeAreaView,
View,
FlatList,
StyleSheet,
Text,
Dimensions
} from 'react-native'
@technoplato
technoplato / postlist.js
Created September 8, 2019 20:52
Likes with Firestore
import React from 'react'
import { FlatList, View, Share } from 'react-native'
import firestore from '@react-native-firebase/firestore'
import PostItem from './PostItem'
import ShowNewPostsButton from './ShowNewPostsButton'
export default class PostsList extends React.PureComponent {
// Staged posts are posts that have been added remotely but not shown yet.
state = { posts: {}, staged: {} }
@technoplato
technoplato / ios fixes.txt
Last active July 4, 2019 19:27
React Native Cheat Sheet
* Something about glob and double-convert and the build failing on Xcode
https://github.com/facebook/react-native/issues/21168#issuecomment-422431294