Skip to content

Instantly share code, notes, and snippets.

View jgwill's full-sized avatar

Guillaume Descoteaux-Isabelle jgwill

View GitHub Profile
@jgwill
jgwill / ai-tf2-setup.sh
Last active November 22, 2020 17:42
Linux platform build by steps (Matching Docker images)
#!/bin/env bash
pip3 install IPython
pip3 install matplotlib
@jgwill
jgwill / gui-run-on-docker.md
Last active November 9, 2020 14:51
Run GUI app on docker local or remote

How to run a GUI app from a docker image ?

Summary

  • X server install on windows (VcXsrv)
  • Sample docker file build (firefox)
  • Environment setup and launch (Powershell)

Prerequisite

//Lire un fichier et imprimer son contenu
var fs = require('fs');
fs.readFile('README.md', 'utf8', function(err, contents) {
console.log(contents);
//contents object has the data
});
#!/bin/bash
export rendercmd="/opt/hfs18.0/bin/hbatch-bin"
export end_cmd=";quit";
cd ~/nad.previz/x/x__for_fun__191122
#volcano_smoke_column.hiplc
@jgwill
jgwill / config.yml
Created February 16, 2020 21:44
CI: get Latest commit message in a Workflow
version: 2
jobs:
build:
docker:
- image: circleci/node:10.0.0
steps:
- checkout
@jgwill
jgwill / houBatch.py
Created November 21, 2019 02:59 — forked from crydalch/houBatch.py
houBatch helper script
"""
A simple script to kick off a certain ROP remotely, optionally
with a given framerange.
Usage: hython path/to/script/houBatch.py /path/to/hipfile /hou/path/to/rop
TODO: Add options for multiple ROPs, hperf.
"""
import hou, sys
@jgwill
jgwill / git-save-credential-http.sh
Created May 21, 2019 00:00
GIT Bash - credentials - How to save username and password in GIT?
# credentials - How to save username and password in GIT? - Stack Overflow
#Run :
git config credential.helper store
#then
git pull
@jgwill
jgwill / count-files-bash.aliases.sh
Last active May 12, 2019 14:32
Count files in the current dir
#@STCGoal Count files in the current dir
alias countfiles="du -a . | wc -l"
@jgwill
jgwill / bash-command-not-installed.sh
Created April 29, 2019 20:02
Echo a command was not found in the BASH environment
#!/bin/bash
command -v foo >/dev/null 2>&1 || { echo >&2 "I require foo but it's not installed. Aborting."; exit 1; }
@jgwill
jgwill / dropbox-file-from-url.js
Created April 28, 2019 13:26
A File URL is posted to the CHAT in the Resolution Field and the server render the content to the browser with the file content
//@cr A File URL is posted to the CHAT in the Resolution Field and the server render the content to the browser with the file content
var fetch = require('isomorphic-fetch'); // or another library of choice.
var fs = require('fs');
var Dropbox = require('dropbox').Dropbox;
var token = process.env.DROPBOX_TOKEN;
var dbx = new Dropbox({ accessToken: token, fetch: fetch });
var annoter_file = "9c6a35efe357580f32e759908430643d.annoter.txt";
var annoter_folder_path = '/x/_/_db/annoter';
var annoter_file_path = annoter_folder_path + '/' + annoter_file;