<commit_before># global port routines
package provide portextract 1.0
package require portutil 1.0

register com.apple.extract target build extract_main 
register com.apple.extract provides extract
register com.apple.extract requires fetch checksum

global extract_opts

# define options
options extract_opts extract.only extract.cmd extract.before_args extract.after_args

proc extract_main {args} {
    global portname portpath portpath workdir distname distpath distfiles use_bzip2 extract.only extract.cmd extract.before_args extract.after_args

    # Set up defaults
    default extract.only $distfiles
    default extract.cmd gzip
    default extract.before_args -dc
    default extract.after_args "| tar -xf -"

    if [info exists use_bzip2] {
	set extract.cmd bzip2
    } elseif [info exists use_zip] {
	set extract.cmd unzip
	set extract.before_args -q
	set extract.after_args "-d $portpath/$workdir"
    }

    puts "Extracting for $distname"
    if [file exists $workdir] {
	file delete -force $portpath/$workdir
    }

    file mkdir $portpath/$workdir
    cd $portpath/$workdir
    foreach distfile ${extract.only} {
	puts -nonewline "$distfile: "
	flush stdout
	set cmd "${extract.cmd} ${extract.before_args} $distpath/$distfile ${extract.after_args}"<commit_msg>Join list of arguments to a scalar.<commit_after># global port routines
package provide portextract 1.0
package require portutil 1.0

register com.apple.extract target build extract_main 
register com.apple.extract provides extract
register com.apple.extract requires fetch checksum

global extract_opts

# define options
options extract_opts extract.only extract.cmd extract.before_args extract.after_args

proc extract_main {args} {
    global portname portpath portpath workdir distname distpath distfiles use_bzip2 extract.only extract.cmd extract.before_args extract.after_args

    # Set up defaults
    default extract.only $distfiles
    default extract.cmd gzip
    default extract.before_args -dc
    default extract.after_args "| tar -xf -"

    if [info exists use_bzip2] {
	set extract.cmd bzip2
    } elseif [info exists use_zip] {
	set extract.cmd unzip
	set extract.before_args -q
	set extract.after_args "-d $portpath/$workdir"
    }

    puts "Extracting for $distname"
    if [file exists $workdir] {
	file delete -force $portpath/$workdir
    }

    file mkdir $portpath/$workdir
    cd $portpath/$workdir
    foreach distfile ${extract.only} {
	puts -nonewline "$distfile: "
	flush stdout
	set cmd "${extract.cmd} [join ${extract.before_args}] $distpath/$distfile [join ${extract.after_args}]"
{'fraction_non_alphanumeric': 0.07908950617283951, 'fraction_numerical': 0.005401234567901234, 'mean_word_length': 4.104330708661418, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4482447', 'n_tokens_mistral': 780, 'n_tokens_neox': 769, 'n_words': 247}