Skip to content

Instantly share code, notes, and snippets.

View stephenwithav's full-sized avatar

Steven Edwards stephenwithav

View GitHub Profile
@stephenwithav
stephenwithav / gcloud-tramp.el
Created June 6, 2023 00:38 — forked from jackrusher/gcloud-tramp.el
Tramping into GCloud instances from within emacs
;; make sure you've set your default project with:
;; gcloud config set project <project-name>
(require 'tramp)
(add-to-list 'tramp-methods
'("gcssh"
(tramp-login-program "gcloud compute ssh")
(tramp-login-args (("%h")))
(tramp-async-args (("-q")))
(tramp-remote-shell "/bin/sh")
@stephenwithav
stephenwithav / setup-gitlab-for-magit-in-doom-emacs.md
Created May 20, 2023 18:52 — forked from Azeirah/setup-gitlab-for-magit-in-doom-emacs.md
Setting up magit forge for gitlab in Doom Emacs

Magit forge for Gitlab in Doom Emacs

This guide assumes you're working on a Unix-like environment. I'm using Linux Mint (Ubuntu). It should work on Macs, and might on Windows.

These are the four steps you can use as a checklist, see the headings below for the details on each step.

  • Enable forge support
  • Create a Gitlab API key
  • Add your gitlab credentials to ~/.authinfo.gpg
  • Set-up forge in emacs
@stephenwithav
stephenwithav / sdl_render-text-with-direction.cpp
Created January 2, 2022 19:51 — forked from wutipong/sdl_render-text-with-direction.cpp
SDL Render text with Freetype and harfbuzz, using outline render.
#include <iostream>
#include <ft2build.h>
#include FT_FREETYPE_H
#include FT_OUTLINE_H
#include <SDL2/SDL.h>
#include <SDL2/SDL_main.h>
#include <string>
sudo dpkg --add-architecture i386
sudo add-apt-repository -y ppa:wine/wine-builds
sudo add-apt-repository -y ppa:ethanak/milena
sudo apt-get update
sudo apt-get -y upgrade
sudo apt-get install -y --install-recommends winehq-devel
sudo apt-get install -y sapi4linux python-pyspda python-sapilektor libsapilektor-utils
#download das vozes
#wget http://150.165.205.9/players/ivona/ivona-full.tar.gz
@stephenwithav
stephenwithav / README.md
Created December 2, 2016 12:04 — forked from fhernand/README.md
Visualization of passes in a soccer game

A graph of passes done between players of Real Madrid in the 1st half of the 23.09.2014 game vs. Elche.

@stephenwithav
stephenwithav / gist:262ae03755c314465a47
Last active September 1, 2015 11:17 — forked from bradleypeabody/gist:185b1d7ed6c0c2ab6cec
golang, convert UTF-16 to UTF-8 string
package main
// http://play.golang.org/p/fVf7duRtdH
import "fmt"
import "unicode/utf16"
import "encoding/binary"
func main() {
@stephenwithav
stephenwithav / main.go
Last active August 29, 2015 14:18
example of using text/template
package main
import (
"os"
"text/template"
)
var peoplePage *template.Template
var peopleTemplate string = `{{range .}}