This content was presented at a sig-testing meeting on 8/25/2020, available as a video here
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| "$schema": "https://opencode.ai/config.json", | |
| "provider": { | |
| "ollama-lan": { | |
| "npm": "@ai-sdk/openai-compatible", | |
| "name": "Ollama LAN", | |
| "options": { | |
| "baseURL": "http://192.168.50.236:11434/v1" | |
| }, | |
| "models": { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "bytes" | |
| "flag" | |
| "golang.org/x/net/websocket" | |
| "io" | |
| "k8s.io/client-go/1.4/rest" | |
| "k8s.io/client-go/1.4/tools/clientcmd" | |
| "log" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "bufio" | |
| "fmt" | |
| "log" | |
| "time" | |
| "github.com/valyala/fasthttp" | |
| ) |
I hereby claim:
- I am exu on github.
- I am ex00 (https://keybase.io/ex00) on keybase.
- I have a public key ASA64vm8QItIOkLbBvBbpHqRQpNnxmEISrW2qI2QVFw2EQo
To claim this, I am signing this object:
I hereby claim:
- I am exu on github.
- I am ex00 (https://keybase.io/ex00) on keybase.
- I have a public key ASDPy0ZW9L2wtGYzcic-fjJZNr0sXSLKeaiu5mXV8tlhsgo
To claim this, I am signing this object:
Simply put, destructuring in Clojure is a way extract values from a datastructure and bind them to symbols, without having to explicitly traverse the datstructure. It allows for elegant and concise Clojure code.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // v2 of the great example of SSE in go by @ismasan. | |
| // includes fixes: | |
| // * infinite loop ending in panic | |
| // * closing a client twice | |
| // * potentially blocked listen() from closing a connection during multiplex step. | |
| package main | |
| import ( | |
| "fmt" | |
| "log" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # bash generate random alphanumeric string | |
| # | |
| # bash generate random 32 character alphanumeric string (upper and lowercase) and | |
| NEW_UUID=$(cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1) | |
| # bash generate random 32 character alphanumeric string (lowercase only) | |
| cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import java.util.Arrays; | |
| import org.springframework.boot.web.client.RestTemplateBuilder; | |
| import org.springframework.cloud.client.loadbalancer.LoadBalanced; | |
| import org.springframework.context.annotation.Bean; | |
| import org.springframework.context.annotation.Configuration; | |
| import org.springframework.hateoas.MediaTypes; | |
| import org.springframework.hateoas.hal.Jackson2HalModule; | |
| import org.springframework.http.converter.json.MappingJackson2HttpMessageConverter; | |
| import org.springframework.web.client.RestTemplate; |
NewerOlder