Skip to content

Instantly share code, notes, and snippets.

View icholy's full-sized avatar
💥
breaking things

Ilia Choly icholy

💥
breaking things
View GitHub Profile
# install https://github.com/mooz/percol
alias cdd='while true; do cd $(ls -d */ | percol); done'
@icholy
icholy / tss_vim.md
Last active March 21, 2023 19:35
TypeScript autocomplete in vim

Install the tss tool.

git clone https://github.com/clausreinke/typescript-tools.git
cd typescript-tools
git checkout testing_ts1.4
npm install -g

Install vim plugin (my fork has a tiny tweak that made it work for me).

package casket
import (
"errors"
"sync"
"time"
)
var (
ErrDying = errors.New("casket: dying")
package main
import (
"log"
"urlparams"
)
func main() {
var (
SongName ArtistName AlbumName
(New Wave) Poly [Mark Goodier Nirvana Incesticide
New Slang The Shins Oh, Inverted World
One Thing Finger Eleven Finger Eleven
Walk In Regret I Am The Architect Gate
Water On The Moon Aer Water On The Moon ( GoodMusicAllDay.com Mixtape)
Simon & Garfunkel!!s Sound of Silence Sound of Silence
Always Gold Radical Face The Family Tree: The Roots
Breezeblocks alt-J An Awesome Wave
Holography Retaliate
declare module Cesium {
type RenderState = any;
interface Proxy {
getURL(resource: string): string;
}
class ArcGisImageServerTerrainProvider {

Here's what I'm doing to animate a linestring over time. It add points to the front while removing them from the tail. Think snake

var viewer = new Cesium.Viewer('mapContainer');

var positions = [];

function randomInRange(from, to) {
  return Math.random() * (to - from) + from;
}
@icholy
icholy / TSServer.py
Last active May 16, 2024 19:17
Python wrapper around TypeScript TSServer
#!/usr/bin/env python
#
# Copyright (C) 2015 Google Inc.
#
# This file is part of YouCompleteMe.
#
# YouCompleteMe is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
package main
import "time"
type Item struct {
time.Time
}
type RingBuffer struct {
items []*Item
function shuffle<T>(o: T[]): T[] {
for(var j, x, i = o.length; i; j = Math.floor(Math.random() * i), x = o[--i], o[i] = o[j], o[j] = x);
return o;
}
enum Door {
Zonk,
Prize
}