Skip to content

Instantly share code, notes, and snippets.

View pol's full-sized avatar

pol llovet pol

View GitHub Profile
@pol
pol / diagram.html
Last active March 25, 2017 17:20
mediawiki diagram test
<table style='border-spacing:0;font-weight:bold;font-family:monospace;color:#C0C0C0;background:#000;table-layout:fixed'><tbody>
<tr style='padding:0;border:0'>
<td style='padding:0'><div class='c' style='height: 12px; width=12px'> </div></td><td style='padding:0'><div class='c' style='height: 12px; width=12px'> </div></td><td style='padding:0'><div class='c' style='height: 12px; width=12px'> </div></td><td style='padding:0'><div class='c' style='height: 12px; width=12px'> </div></td><td style='padding:0'><div class='c' style='height: 12px; width=12px'> </div></td><td style='padding:0'><div class='c' style='height: 12px; width=12px'> </div></td><td style='padding:0'><div class='c' style='height: 12px; width=12px'>B</div></td><td style='padding:0'><div class='c' style='height: 12px; width=12px'>a</div></td><td style='padding:0'><div class='c' style='height: 12px; width=12px'>s</div></td><td style='padding:0'><div class='c' style='height: 12px; width=12px'>e</div></td><td style='padding:0'><div class='c' style='
rank user volume spc_used count avg_size
2 m15s383 64608678787687 64648608903168 15610634 4138761
3 f76d645 32155369894074 32157428359168 0 46926800
4 w94w693 24857322102161 24858396635136 474658 52368910
5 h55z482 22892518496713 22921352867840 10559084 2168040
6 f35x971 17276095757137 17276136099840 6926 2494382870
7 j24x165 14340829268268 14341061804032 69332 206842861
8 r19b115 10915238875875 10915817496576 237647 45930472
9 s44t628 10470412526111 10470522220544 114830 91181856
10 z58j114 7468083765750 7472243970048 1650783 4523965
@pol
pol / df-strategy-test.md
Last active March 16, 2017 17:34
example of markdown paragraph split

Yes, there are many detailed, comprehensive resources for Dwarf Fortress on this wiki, and very illustrative video tutorials and playthrough guides elsewhere. I have relied on them extensively (thanks, Captain Duck!), and so will you - this strategy guide is not intended to be in any way definitive or a replacement for other resources. Rather, the intention of this guide is to be as linear and straightforward as a video walkthrough, while providing sufficiently detailed context and reasoning that players can grasp the underlying principles, and generalise them to other contexts. The intended audience is beginner to intermediate players with some experience with the basics of Dwarf Fortress. Beginner players usually wish to begin playing immediately, and this guide provides a structured approach which helps them learn the game. Intermediate players will understand the basics, but this guide may help to sort

@pol
pol / matlab-log.txt
Created December 10, 2015 19:59
matlab parallel pool failure
[d86r845@hyalite ~]$ ssh compute002
Last login: Fri Dec 4 10:27:28 2015 from hyalite.global.cluster
[d86r845@compute002 ~]$ module load matlab
[d86r845@compute002 ~]$ matlab -nodisplay -nosplash
< M A T L A B (R) >
Copyright 1984-2015 The MathWorks, Inc.
R2015a (8.5.0.197613) 64-bit (glnxa64)
February 12, 2015
@pol
pol / rsync-incremental-backup.sh
Last active February 7, 2016 20:54
Novel (?) incremental backup using rsync without hardlinks.
#!/bin/sh
#
# Novel (?) rsync incremental backup without hardlinks
# Pol Llovet <pol.llovet@montana.edu>
case "$2" in
'')
;&
'-h')
;&
@pol
pol / root_tmux.sh
Last active December 8, 2015 18:15
sudo into root with a tmux session, default to a new session named with the date. Otherwise, do sensible things (ls will list root tmux sessions).
# this will open up a root prompt inside a tmux session
# if nothing is given, open up a new tmux session with current datetime
# if a string is given, attach or new depending on if the session already exists
# Note: this will probably cause trouble if multiple people are using it. Recommend
# namespacing the sessions with your username.
function root () {
name=$1
session="new -s"
if [ -z "$name" ]; then
@pol
pol / dbn-partitioned-none_class.slurm.sh
Created October 23, 2015 17:39
Hasari SLURM Batch file.
#!/bin/bash
#----------------------------------------------------
# Hasari SLURM Batch Job
# Usage: put this file somewhere in your $STORE. It is recommended to create job-specific folders,
# and to put your batch files in those folders. Then your batch, output, error, etc will
# all be in one folder.
#----------------------------------------------------
#SLURM SBATCH Parameters
#----------------------------------------------------
#SBATCH -J dbn-partitioned-none_class # Job name
@pol
pol / nginx.conf
Last active October 6, 2015 15:50
upstream unicorn_server {
server unix:/var/rails/shared/pids/unicorn.sock fail_timeout=0;
}
server {
listen 80;
server_name foo.edu bar.edu;
return 301 https://bar.edu$request_uri;
}
#!/bin/sh
#
# Novel (?) rsync incremental backup without hardlinks
# Pol Llovet <pol.llovet@montana.edu>
BACKUP_NAME=`date +%Y-%m-%d-%H%M%S`
BASE="$WORK/backup"
BACKUP="$BASE/$BACKUP_NAME"
MANIFEST="$BASE/manifest"
Write restart file '/mnt/lustrefs/w94w693/output/rcp26/CESM1-CAM5/spinup/restart0.lpj'.
Simulation ended.
/home/zhen.zhang/LPJ/lpj terminated, 4 grid cells processed.
Wall clock time: 118 sec, 0.029 sec/cell/year.
real 1m58.939s
user 0m4.912s
sys 1m53.775s