Skip to content

Instantly share code, notes, and snippets.

@avinoamsn
avinoamsn / wslTerminator.vbs
Last active July 3, 2022 16:31
VBScript for quietly launching a Terminator window in WSL with VcXsrv. Code comments link to the guides I referenced while writing the script.
' NOTE: additional discussion & implementations can be found here: https://gist.github.com/ropnop/10800fb5066bd5144d9aaad55a8a4d18
' https://medium.com/@bhupathy/install-terminator-on-windows-with-wsl-2826591d2156
set shell = WScript.CreateObject("Shell.Application")
if not IsProcessRunning("vcxsrv.exe") then
shell.shellExecute "vcxsrv.exe", ":0 -ac -terminate -lesspointer -multiwindow -clipboard -wgl -dpi auto", "C:\Program Files\VcXsrv\", "", 0
end if
shell.ShellExecute "bash", "-c -l ""DISPLAY=:0 terminator""", "", "open", 0
' https://stackoverflow.com/questions/19794726/vb-script-how-to-tell-if-a-program-is-already-running
@ropnop
ropnop / startTerminator.vbs
Created September 29, 2017 00:02
VBS Script to Launch Terminator through WSL
args = "-c" & " -l " & """DISPLAY=:0 terminator"""
WScript.CreateObject("Shell.Application").ShellExecute "bash", args, "", "open", 0
@malzantot
malzantot / frozenlake8x8_valueiteration.py
Created July 9, 2017 01:49
Solution of FrozenLake8x8 environment using Value Iteration.
"""
Solving FrozenLake8x8 environment using Value-Itertion.
Author : Moustafa Alzantot (malzantot@ucla.edu)
"""
import numpy as np
import gym
from gym import wrappers
@dsci
dsci / gist:1347672
Created November 8, 2011 12:52
Delete commits from repository.
# First, check out the commit you wish to go back to (get sha-1 from git log)
git reset --hard 9d3c3a0caa7f7b35ef15adb96fc80fcbb59ac72a
# Then do a forced update.
git push origin +9d3c3a0caa7f7b35ef15adb96fc80fcbb59ac72a^:develop
# Push specific commit
git push origin 9d3c3a0caa7f7b35ef15adb96fc80fcbb59ac72a:develop -f