This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <regex.h> | |
#include <string.h> | |
#include <stdlib.h> | |
#define NUM_TOKENS_DEFS 10 | |
#define WHITESPACE "WHITESPACE" | |
typedef struct tokendef { | |
char *pattern; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/ruby | |
require 'pty' | |
def generate_permutations cmd_template, lists, vars=[] | |
if lists.empty? | |
cmd = String.new(cmd_template) | |
vars.each_with_index { |var, i| cmd.gsub! "{#{i}}", var } | |
if $preview | |
puts cmd |