# -*- mode: snippet -*- # key: gsu # contributor: Translated from TextMate Snippet # name: gsub(/../) { |match| .. } # -- gsub(/${1:pattern}/) { ${2/(^(?\s*(?:\*|\*?[a-z_])[a-zA-Z0-9_]*\s*)(,\g)*,?\s*$)|.*/(?1:|)/}${2:match}${2/(^(?\s*(?:\*|\*?[a-z_])[a-zA-Z0-9_]*\s*)(,\g)*,?\s*$)|.*/(?1:| )/}$0 }