Skip to content

Instantly share code, notes, and snippets.

View fattenap's full-sized avatar

Frank Panetta fattenap

View GitHub Profile
@TheRealFlyingCoder
TheRealFlyingCoder / Cloud Run & Remix
Last active March 19, 2024 17:58
Remix & Cloud Run
So you want to set up remix in cloud run huh? It's pretty simple but i'm going to assume you can figure out most of the GCP UI on your own.
Cloud Run:
Step 1: Create a new service and take note of the service ID
Step 2: Allow all traffic in the /triggers tab
Cloud Build:
Step 1: Set up a Cloud Build trigger on your repo
Step 2: Point the configuration to "cloud build configuration file" at the root of your project
Step 3: Add the following to the substitution variables (so you can keep it safe):
@dz4k
dz4k / Draggable._hs
Last active December 25, 2023 10:47
Draggable window in _hyperscript
-- Usage: _="install Draggable(dragHandle: .titlebar in me)"
behavior Draggable(dragHandle)
init
if no dragHandle set the dragHandle to me
end
on pointerdown(clientX, clientY) from dragHandle
halt the event
trigger draggable:start -- hooks, e.g. for adding a drop shadow while dragging
measure my x, y
@subfuzion
subfuzion / README.md
Last active April 11, 2024 14:52
vim/neovim configuration

I recently switched over to neovim (see my screenshots at the bottom). Below is my updated config file.

It's currently synchronized with my .vimrc config except for a block of neovim-specific terminal key mappings.

This is still a work in progress (everyone's own config is always a labor of love), but I'm already extremely pleased with how well this is working for me with neovim. While terminal mode isn't enough to make me stop using tmux, it is quite good and I like having it since it simplifies my documentation workflow for yanking terminal output to paste in a markdown buffer.

These days I primarily develop in Go. I'm super thrilled and grateful for fatih/vim-go,

port module Spelling exposing (..)
import Html exposing (..)
import Html.App as App
import Html.Attributes exposing (..)
import Html.Events exposing (..)
import String
main =
@JamsMendez
JamsMendez / process_parallel.go
Created September 1, 2015 00:40
Procesos Paralelos en Go lang
package main
import (
"fmt"
"runtime"
"sync"
"time"
)
func main() {
@jarrad
jarrad / install-kafka.txt
Last active August 24, 2023 08:23
Install Kafka on OSX via Homebrew
$> brew cask install java
$> brew install kafka
$> vim ~/bin/kafka
# ~/bin/kafka
#!/bin/bash
zkServer start
kafka-server-start.sh /usr/local/etc/kafka/server.properties
@MrOrz
MrOrz / README.md
Last active July 22, 2018 15:36
Cross-device BrowserSync with webpack demo
var Bar1 = base => class extends base {
componentWillMount(){
super.componentWillMount();
console.log('Bar1');
}
};
var Bar2 = base => class extends base {
componentWillMount(){
super.componentWillMount();
@mikelehen
mikelehen / generate-pushid.js
Created February 11, 2015 17:34
JavaScript code for generating Firebase Push IDs
/**
* Fancy ID generator that creates 20-character string identifiers with the following properties:
*
* 1. They're based on timestamp so that they sort *after* any existing ids.
* 2. They contain 72-bits of random data after the timestamp so that IDs won't collide with other clients' IDs.
* 3. They sort *lexicographically* (so the timestamp is converted to characters that will sort properly).
* 4. They're monotonically increasing. Even if you generate more than one in the same timestamp, the
* latter ones will sort after the former ones. We do this by using the previous random bits
* but "incrementing" them by 1 (only in the case of a timestamp collision).
*/
@ipbabble
ipbabble / gist:c7f231d6ebf596e61cd6
Last active April 28, 2016 00:51
Deeper Docker

Intro

Do a short recap on Docker/Containers/Images/build/pull/run. Repositories, Registries, Index.

Then looked at:

Preparation

Can build a quick Fedora/HTTP Image from Dockerfile: