Skip to content

Instantly share code, notes, and snippets.

View thomasantony's full-sized avatar

Thomas Antony thomasantony

View GitHub Profile
@thomasantony
thomasantony / .bash_profile
Last active August 29, 2015 14:08
Bash Profile for Carter Server
module load cuda
module load matlab/R2014a
module load mathematica
unset SSH_ASKPASS
screen -p 0 -X stuff "export DISPLAY=$DISPLAY$(printf \\r)"
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/apps/rhel6/Wolfram/Mathematica/9.0/SystemFiles/Links/MathLink/DeveloperKit/Linux-x86-64/CompilerAdditions
export PATH=$PATH:/apps/rhel6/Wolfram/Mathematica/9.0/Executables
#!/bin/bash
# Place in ~/Library/TexShop/Engines/LatBibNomTex/engine
pdflatex "$1"
for file in *.aux ; do
bibtex $file
bfname=$(dirname "$1")/"`basename "$1" .tex`"
makeindex "$bfname".nlo -s nomencl.ist -o "$bfname".nls
done
pdflatex "$1"
# pdflatex "$1"
#!/bin/bash
# Place in ~/Library/TexShop/Engines
# LatNomLat.engine
bfname=$(dirname "$1")/"`basename "$1" .tex`"
makeindex "$bfname".nlo -s nomencl.ist -o "$bfname".nls
done
pdflatex "$1"
# pdflatex "$1"
@thomasantony
thomasantony / ezproxify
Created December 11, 2014 20:33
Ezproxify bookmarklet
javascript:void(window.location.host += '.ezproxy.lib.purdue.edu')
@thomasantony
thomasantony / hw09.py
Created October 28, 2012 06:40
AAE 532 - Hohmann Transfer gone bad
# AAE 532 - HW09 - Q02
# Author : Thomas Antony ( tantony (at) purdue (dot) edu )
# Code re-purposed from from Udacity.com CS222 - HW02-Q02
# Original code author : Miriam "Swords" Kalk ?? ( I think )
# The simulation starts with the spacecraft in an earth-centered
# circular orbit at 175 km altitude, just after finishing a burn which sends it on a
# Hohmann trajectory to the moon.
#
# The purpose of the simulation was to examine what happens to the orbit if a capture
# burn was not performed after reaching the moon
@thomasantony
thomasantony / index.js
Created September 2, 2016 02:25
requirebin sketch
// Welcome! require() some modules from npm (like you were using browserify)
// and then hit Run Code to run your code on the right side.
// Modules get downloaded from browserify-cdn and bundled in your browser.
require('virtual-dom')
var h = require('virtual-dom/h');
var diff = require('virtual-dom/diff');
var patch = require('virtual-dom/patch');
var createElement = require('virtual-dom/create-element');
@thomasantony
thomasantony / client.py
Created June 10, 2017 03:30 — forked from marvin/client.py
simple python client/server socket binary stream
import socket
HOST = 'localhost'
PORT = 9876
ADDR = (HOST,PORT)
BUFSIZE = 4096
videofile = "videos/royalty-free_footage_wien_18_640x360.mp4"
bytes = open(videofile).read()
@thomasantony
thomasantony / qcl.rb
Last active April 4, 2019 20:44
Installs qcl tool using Homebrew for communicating with QNX OS devices
# Download file and run `brew install qcl.rb`
class Qcl < Formula
desc "A command line tool to transfer files into Qconn-enabled remote device"
homepage "https://github.com/TheHipbot/weather"
url "https://github.com/thomasantony/qcl/archive/master.zip"
sha256 "db762174cd29e827007d97333853e64a8e39210ac4fad23f3083d9912a5ba3ce"
version "1.0.0"
depends_on "perl"
@thomasantony
thomasantony / settings.json
Created December 1, 2019 19:39
My VSCode settings
{
"atomKeymap.promptV3Features": true,
"editor.multiCursorModifier": "ctrlCmd",
"editor.formatOnPaste": true,
"[markdown]": {
},
"workbench.startupEditor": "newUntitledFile",
"files.exclude": {
"node_modules": true
@thomasantony
thomasantony / mqtt_client.rs
Created January 17, 2020 16:24
Rust rumqtt client example
use rumqtt::{MqttClient, MqttOptions, QoS, Notification};
use std::{thread, time::Duration};
use std::collections::HashMap;
use std::sync::Arc;
fn foo(payload: Arc<Vec<u8>>)
{
println!("Got foo message: {:?}", payload);
}
fn bar(payload: Arc<Vec<u8>>)