Procrastiblog

September 7, 2008

Monotonix

Filed under: Music — Chris @ 10:54 pm

I’ve never seen a band try harder or better succeed at re-contextualizing rock and roll as a visceral experience and forcing an audience to respond in kind than Monotonix tonight at the Bowery Ballroom. We’re talking serious any-more-and-you’d-be-GG-Allin stuff, here. They got New York indie rock nerds to mosh. It looked something like this, only much more crowded:

Oddly, they were opening up for the Silver Jews, who were resolutely un-rock-and-roll, un-visceral, and dissapointingly uninteresting.

September 2, 2008

WINE Paths

Filed under: Linux — Chris @ 11:02 pm

If you try to run a Windows command-line app on Linux under WINE, you may find that filename arguments yield errors like the following:

$ wine z3.exe -smt /tmp/smtlib2b129a.smt

Error: invalid command line option: /tmp/smtlib2b129a.smt
For usage information: z3 /h

The problem here is that the ‘/’ at the beginning of an absolute path can be interpreted as the beginning of a Windows-style command-line argument. The following script takes a Windows command-line and Windows-ifies Unix path arguments.

#! /bin/bash

if [ "${1+set}" != "set" ]
then
  echo "Usage; winewrap EXEC [ARGS...]"
  exit 1
fi

EXEC="$1"
shift

for p in "$@";
do
  if [ -e "$p" ];
  then
    p=$(winepath -w "$p")
  fi
  ARGS="$ARGS $p"
done

wine "$EXEC" $ARGS

The script can be used thus:

$ winewrap z3.exe -smt /tmp/smtlib2b129a.smt

Which will execute

wine z3.exe -smt Z:\tmp\smtlib2b129a.smt

P.S. You can also just use the WINE drive mapping (in this case / == Z:\), but I’d rather keep my Unix mindset and let the script do the work.

Create a free website or blog at WordPress.com.