Skip to content

Instantly share code, notes, and snippets.

View fpapadopou's full-sized avatar

Fotis Papadopoulos fpapadopou

View GitHub Profile
@fpapadopou
fpapadopou / operations.go
Created November 20, 2019 13:36
A location-aware user database implemented using Google S2 Geometry and Hashicorp's go-memdb (insert/update operations)
package store
import (
"github.com/golang/geo/s1"
"github.com/golang/geo/s2"
"github.com/hashicorp/go-memdb"
)
// Insert adds a new user to th
func (s *Store) Insert(user int, lat float64, lon float64) error {
@fpapadopou
fpapadopou / redis_cheatsheet.bash
Created December 4, 2019 07:46 — forked from LeCoupa/redis_cheatsheet.bash
Redis Cheatsheet - Basic Commands You Must Know --> UPDATED VERSION --> https://github.com/LeCoupa/awesome-cheatsheets
# Redis Cheatsheet
# All the commands you need to know
redis-server /path/redis.conf # start redis with the related configuration file
redis-cli # opens a redis prompt
# Strings.