<commit_before>###############################################################################
# Define everything needed to create .dmg files for OSX Julia binaries
###############################################################################

# Add a dependent scheduler for OSX packaging
julia_dmg_packagers = ["package_" + z for z in ["osx10.9-x64"]]
osx_package_scheduler = Dependent(name="Julia OSX package", builderNames=julia_dmg_packagers, upstream=quickbuild_scheduler)
c['schedulers'].append(osx_package_scheduler)

# Steps to build an OSX .dmg Julia package
julia_dmg_factory = BuildFactory()
julia_dmg_factory.useProgress = True
julia_dmg_factory.addSteps([
    # Clone julia
    Git(
    	name="Julia checkout",
    	repourl=Property('repository', default='git://github.com/JuliaLang/julia.git'),
    	mode='incremental',
    	method='clean',
    	submodules=True,
    	clobberOnFailure=True,
    	progress=True
    ),
    # Fetch so that remote branches get updated as well.
    ShellCommand(
    	name="git fetch",
    	command=["git", "fetch"],
    	flunkOnFailure=False
    ),

    # Unlink brew dependencies
    ShellCommand(
    	name="Unlink brew dependencies",
    	command=["brew", "unlink", "llvm33-julia", "arpack-julia", "suite-sparse-julia", "openblas-julia", "gettext"],
    	flunkOnFailure=False
    ),
    # Make sure gcc and cmake are installed though!
    ShellCommand(
    	name="Install necessary brew dependencies",
    	command=["brew", "install", "gcc", "cmake"],
        flunkOnFailure=False
    ),

    # make clean first
    ShellCommand(
    	name="make cleanall",
    	command=["/bin/bash", "-c", Interpolate("make %(prop:flags)s cleanall")]
    ),
    
    # Make!
    ShellCommand(
    	name="make",
    	command=["/bin/bash", "-c", Interpolate("make %(prop:flags)s")],
    	haltOnFailure=True
    ),

    # Set a bunch of properties that everyone will need
    SetPropertyFromCommand(
    	name="Get major/minor version",
    	command=["./julia", "-e", "println(\"$(VERSION.major).$(VERSION.minor)\")"],
    	property="majmin"
    ),
    SetPropertyFromCommand(
    	name="Get major/minor/patch version",
    	command=["./julia", "-e", "println(\"$(VERSION.major).$(VERSION.minor).$(VERSION.patch)\")"],
    	property="version"
    ),
    SetPropertyFromCommand(
    	name="Get shortcommit",
    	command=["./julia", "-e", "println(Base.GIT_VERSION_INFO.commit[1:10])"],
    	property="shortcommit"
    ),

    # Actually package the darn thing
    ShellCommand(
    	name="Unlock keychain",
    	command=["/bin/bash", "/Users/vagrant/unlock_keychain.sh"]
    ),
    ShellCommand(
    	name="make .app",
    	command=["/bin/bash", "-c", Interpolate("make %(prop:flags)s -C contrib/mac/app")],
    	haltOnFailure=True
    ),

    # Upload the package to the host!
    SetPropertyFromCommand(
    	name="Get dmg filename",
    	command=["/bin/bash", "-c", "cd contrib/mac/app && echo *.dmg"],
    	property="filename"
    ),
    MasterShellCommand(
    	name="mkdir julia_package",
    	command=["mkdir", "-p", "/tmp/julia_package"]
    ),
    FileUpload(<commit_msg>More better home path<commit_after>###############################################################################
# Define everything needed to create .dmg files for OSX Julia binaries
###############################################################################

# Add a dependent scheduler for OSX packaging
julia_dmg_packagers = ["package_" + z for z in ["osx10.9-x64"]]
osx_package_scheduler = Dependent(name="Julia OSX package", builderNames=julia_dmg_packagers, upstream=quickbuild_scheduler)
c['schedulers'].append(osx_package_scheduler)

# Steps to build an OSX .dmg Julia package
julia_dmg_factory = BuildFactory()
julia_dmg_factory.useProgress = True
julia_dmg_factory.addSteps([
    # Clone julia
    Git(
    	name="Julia checkout",
    	repourl=Property('repository', default='git://github.com/JuliaLang/julia.git'),
    	mode='incremental',
    	method='clean',
    	submodules=True,
    	clobberOnFailure=True,
    	progress=True
    ),
    # Fetch so that remote branches get updated as well.
    ShellCommand(
    	name="git fetch",
    	command=["git", "fetch"],
    	flunkOnFailure=False
    ),

    # Unlink brew dependencies
    ShellCommand(
    	name="Unlink brew dependencies",
    	command=["brew", "unlink", "llvm33-julia", "arpack-julia", "suite-sparse-julia", "openblas-julia", "gettext"],
    	flunkOnFailure=False
    ),
    # Make sure gcc and cmake are installed though!
    ShellCommand(
    	name="Install necessary brew dependencies",
    	command=["brew", "install", "gcc", "cmake"],
        flunkOnFailure=False
    ),

    # make clean first
    ShellCommand(
    	name="make cleanall",
    	command=["/bin/bash", "-c", Interpolate("make %(prop:flags)s cleanall")]
    ),
    
    # Make!
    ShellCommand(
    	name="make",
    	command=["/bin/bash", "-c", Interpolate("make %(prop:flags)s")],
    	haltOnFailure=True
    ),

    # Set a bunch of properties that everyone will need
    SetPropertyFromCommand(
    	name="Get major/minor version",
    	command=["./julia", "-e", "println(\"$(VERSION.major).$(VERSION.minor)\")"],
    	property="majmin"
    ),
    SetPropertyFromCommand(
    	name="Get major/minor/patch version",
    	command=["./julia", "-e", "println(\"$(VERSION.major).$(VERSION.minor).$(VERSION.patch)\")"],
    	property="version"
    ),
    SetPropertyFromCommand(
    	name="Get shortcommit",
    	command=["./julia", "-e", "println(Base.GIT_VERSION_INFO.commit[1:10])"],
    	property="shortcommit"
    ),

    # Actually package the darn thing
    ShellCommand(
        name="Unlock keychain",
        command=["/bin/bash", "~/unlock_keychain.sh"]
    ),
    ShellCommand(
    	name="make .app",
    	command=["/bin/bash", "-c", Interpolate("make %(prop:flags)s -C contrib/mac/app")],
    	haltOnFailure=True
    ),

    # Upload the package to the host!
    SetPropertyFromCommand(
    	name="Get dmg filename",
    	command=["/bin/bash", "-c", "cd contrib/mac/app && echo *.dmg"],
    	property="filename"
    ),
    MasterShellCommand(
    	name="mkdir julia_package",
    	command=["mkdir", "-p", "/tmp/julia_package"]
    ),
    FileUpload(
{'fraction_non_alphanumeric': 0.19678714859437751, 'fraction_numerical': 0.00321285140562249, 'mean_word_length': 3.660179640718563, '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': '2319489', 'n_tokens_mistral': 2078, 'n_tokens_neox': 1999, 'n_words': 404}