Commit a07f3660 authored by Drew's avatar Drew

Add nop, a tool that has no effect

parent deaf1ec9
Pipeline #654 passed with stage
// Nop.swift
// © 2016 Anarchy Tools Contributors.
// This file is part of atbuild. It is subject to the license terms in the LICENSE
// file found in the top level of this distribution
// No part of atbuild, including this file, may be copied, modified,
// propagated, or distributed except according to the terms contained
// in the LICENSE file.
import Foundation
///Nop is a tool that has no effect
final class Nop: Tool {
func run(args: [Yaml : Yaml]) throws {
//nothing
}
}
\ No newline at end of file
......@@ -13,7 +13,7 @@ protocol Tool {
}
///The builtin tools.
let tools : [String: Tool] = ["shell":Shell(),"atllbuild":ATllbuild()]
let tools : [String: Tool] = ["shell":Shell(),"atllbuild":ATllbuild(), "nop":Nop()]
///Look up a tool by name. Throws if there is no such tool.
func toolByName(name: String) throws -> Tool {
......
......@@ -10,17 +10,17 @@ commands:
<atllbuild-swiftc>:
tool: swift-compiler
executable: "/Library/Developer/Toolchains/swift-latest.xctoolchain/usr/bin/swiftc"
inputs: ["cli/src/atllbuild.swift", "cli/src/config.swift", "cli/src/errors.swift", "cli/src/main.swift", "cli/src/PlatformPaths.swift", "cli/src/Shell.swift", "cli/src/Task.swift", "cli/src/Tools.swift", "parsers/yaml/src/Operators.swift", "parsers/yaml/src/Parser.swift", "parsers/yaml/src/Regex.swift", "parsers/yaml/src/Result.swift", "parsers/yaml/src/Tokenizer.swift", "parsers/yaml/src/Yaml.swift"]
sources: ["cli/src/atllbuild.swift", "cli/src/config.swift", "cli/src/errors.swift", "cli/src/main.swift", "cli/src/PlatformPaths.swift", "cli/src/Shell.swift", "cli/src/Task.swift", "cli/src/Tools.swift", "parsers/yaml/src/Operators.swift", "parsers/yaml/src/Parser.swift", "parsers/yaml/src/Regex.swift", "parsers/yaml/src/Result.swift", "parsers/yaml/src/Tokenizer.swift", "parsers/yaml/src/Yaml.swift"]
objects: [".atllbuild/atllbuild.swift.o", ".atllbuild/config.swift.o", ".atllbuild/errors.swift.o", ".atllbuild/main.swift.o", ".atllbuild/PlatformPaths.swift.o", ".atllbuild/Shell.swift.o", ".atllbuild/Task.swift.o", ".atllbuild/Tools.swift.o", ".atllbuild/Operators.swift.o", ".atllbuild/Parser.swift.o", ".atllbuild/Regex.swift.o", ".atllbuild/Result.swift.o", ".atllbuild/Tokenizer.swift.o", ".atllbuild/Yaml.swift.o"]
outputs: ["<atllbuild-swiftc>", ".atllbuild/atllbuild.swift.o", ".atllbuild/config.swift.o", ".atllbuild/errors.swift.o", ".atllbuild/main.swift.o", ".atllbuild/PlatformPaths.swift.o", ".atllbuild/Shell.swift.o", ".atllbuild/Task.swift.o", ".atllbuild/Tools.swift.o", ".atllbuild/Operators.swift.o", ".atllbuild/Parser.swift.o", ".atllbuild/Regex.swift.o", ".atllbuild/Result.swift.o", ".atllbuild/Tokenizer.swift.o", ".atllbuild/Yaml.swift.o"]
inputs: ["cli/src/atllbuild.swift", "cli/src/config.swift", "cli/src/errors.swift", "cli/src/main.swift", "cli/src/Nop.swift", "cli/src/PlatformPaths.swift", "cli/src/Shell.swift", "cli/src/Task.swift", "cli/src/Tools.swift", "parsers/yaml/src/Operators.swift", "parsers/yaml/src/Parser.swift", "parsers/yaml/src/Regex.swift", "parsers/yaml/src/Result.swift", "parsers/yaml/src/Tokenizer.swift", "parsers/yaml/src/Yaml.swift"]
sources: ["cli/src/atllbuild.swift", "cli/src/config.swift", "cli/src/errors.swift", "cli/src/main.swift", "cli/src/Nop.swift", "cli/src/PlatformPaths.swift", "cli/src/Shell.swift", "cli/src/Task.swift", "cli/src/Tools.swift", "parsers/yaml/src/Operators.swift", "parsers/yaml/src/Parser.swift", "parsers/yaml/src/Regex.swift", "parsers/yaml/src/Result.swift", "parsers/yaml/src/Tokenizer.swift", "parsers/yaml/src/Yaml.swift"]
objects: [".atllbuild/atllbuild.swift.o", ".atllbuild/config.swift.o", ".atllbuild/errors.swift.o", ".atllbuild/main.swift.o", ".atllbuild/Nop.swift.o", ".atllbuild/PlatformPaths.swift.o", ".atllbuild/Shell.swift.o", ".atllbuild/Task.swift.o", ".atllbuild/Tools.swift.o", ".atllbuild/Operators.swift.o", ".atllbuild/Parser.swift.o", ".atllbuild/Regex.swift.o", ".atllbuild/Result.swift.o", ".atllbuild/Tokenizer.swift.o", ".atllbuild/Yaml.swift.o"]
outputs: ["<atllbuild-swiftc>", ".atllbuild/atllbuild.swift.o", ".atllbuild/config.swift.o", ".atllbuild/errors.swift.o", ".atllbuild/main.swift.o", ".atllbuild/Nop.swift.o", ".atllbuild/PlatformPaths.swift.o", ".atllbuild/Shell.swift.o", ".atllbuild/Task.swift.o", ".atllbuild/Tools.swift.o", ".atllbuild/Operators.swift.o", ".atllbuild/Parser.swift.o", ".atllbuild/Regex.swift.o", ".atllbuild/Result.swift.o", ".atllbuild/Tokenizer.swift.o", ".atllbuild/Yaml.swift.o"]
module-name: atbuild
module-output-path: .atllbuild/atbuild.swiftmodule
temps-path: .atllbuild//llbuildtmp
other-args: ["-j8", "-sdk", "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk"]
<atllbuild>:
tool: shell
inputs: ["<atllbuild-swiftc>", ".atllbuild/atllbuild.swift.o", ".atllbuild/config.swift.o", ".atllbuild/errors.swift.o", ".atllbuild/main.swift.o", ".atllbuild/PlatformPaths.swift.o", ".atllbuild/Shell.swift.o", ".atllbuild/Task.swift.o", ".atllbuild/Tools.swift.o", ".atllbuild/Operators.swift.o", ".atllbuild/Parser.swift.o", ".atllbuild/Regex.swift.o", ".atllbuild/Result.swift.o", ".atllbuild/Tokenizer.swift.o", ".atllbuild/Yaml.swift.o"]
inputs: ["<atllbuild-swiftc>", ".atllbuild/atllbuild.swift.o", ".atllbuild/config.swift.o", ".atllbuild/errors.swift.o", ".atllbuild/main.swift.o", ".atllbuild/Nop.swift.o", ".atllbuild/PlatformPaths.swift.o", ".atllbuild/Shell.swift.o", ".atllbuild/Task.swift.o", ".atllbuild/Tools.swift.o", ".atllbuild/Operators.swift.o", ".atllbuild/Parser.swift.o", ".atllbuild/Regex.swift.o", ".atllbuild/Result.swift.o", ".atllbuild/Tokenizer.swift.o", ".atllbuild/Yaml.swift.o"]
outputs: ["<atllbuild>", ".atllbuild/atbuild"]
args: ["/Library/Developer/Toolchains/swift-latest.xctoolchain/usr/bin/swiftc", "-o", ".atllbuild/atbuild", ".atllbuild/atllbuild.swift.o", ".atllbuild/config.swift.o", ".atllbuild/errors.swift.o", ".atllbuild/main.swift.o", ".atllbuild/PlatformPaths.swift.o", ".atllbuild/Shell.swift.o", ".atllbuild/Task.swift.o", ".atllbuild/Tools.swift.o", ".atllbuild/Operators.swift.o", ".atllbuild/Parser.swift.o", ".atllbuild/Regex.swift.o", ".atllbuild/Result.swift.o", ".atllbuild/Tokenizer.swift.o", ".atllbuild/Yaml.swift.o"]
args: ["/Library/Developer/Toolchains/swift-latest.xctoolchain/usr/bin/swiftc", "-o", ".atllbuild/atbuild", ".atllbuild/atllbuild.swift.o", ".atllbuild/config.swift.o", ".atllbuild/errors.swift.o", ".atllbuild/main.swift.o", ".atllbuild/Nop.swift.o", ".atllbuild/PlatformPaths.swift.o", ".atllbuild/Shell.swift.o", ".atllbuild/Task.swift.o", ".atllbuild/Tools.swift.o", ".atllbuild/Operators.swift.o", ".atllbuild/Parser.swift.o", ".atllbuild/Regex.swift.o", ".atllbuild/Result.swift.o", ".atllbuild/Tokenizer.swift.o", ".atllbuild/Yaml.swift.o"]
description: Linking executable atbuild
......@@ -7,6 +7,7 @@
objects = {
/* Begin PBXBuildFile section */
3A8AF7041C48571F00D8495D /* Nop.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3A8AF7031C48571F00D8495D /* Nop.swift */; };
3AE6852B1C466DC400444852 /* main.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3AE6852A1C466DC400444852 /* main.swift */; };
3AED49881C466DFD00AC56A8 /* Operators.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3AED49821C466DFD00AC56A8 /* Operators.swift */; };
3AED49891C466DFD00AC56A8 /* Parser.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3AED49831C466DFD00AC56A8 /* Parser.swift */; };
......@@ -36,6 +37,7 @@
/* End PBXCopyFilesBuildPhase section */
/* Begin PBXFileReference section */
3A8AF7031C48571F00D8495D /* Nop.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = Nop.swift; path = ../cli/src/Nop.swift; sourceTree = SOURCE_ROOT; };
3AE685101C466CDE00444852 /* AnarchyToolsXcode */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = AnarchyToolsXcode; sourceTree = BUILT_PRODUCTS_DIR; };
3AE6852A1C466DC400444852 /* main.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = main.swift; path = ../cli/src/main.swift; sourceTree = SOURCE_ROOT; };
3AED49821C466DFD00AC56A8 /* Operators.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = Operators.swift; path = ../parsers/yaml/src/Operators.swift; sourceTree = SOURCE_ROOT; };
......@@ -92,6 +94,7 @@
3AED49981C4681F600AC56A8 /* atllbuild.swift */,
3AED499A1C46923A00AC56A8 /* PlatformPaths.swift */,
3AED499C1C4698BC00AC56A8 /* config.swift */,
3A8AF7031C48571F00D8495D /* Nop.swift */,
);
path = AnarchyToolsXcode;
sourceTree = "<group>";
......@@ -168,6 +171,7 @@
buildActionMask = 2147483647;
files = (
3AE6852B1C466DC400444852 /* main.swift in Sources */,
3A8AF7041C48571F00D8495D /* Nop.swift in Sources */,
3AED499B1C46923A00AC56A8 /* PlatformPaths.swift in Sources */,
3AED498C1C466DFD00AC56A8 /* Tokenizer.swift in Sources */,
3AED49951C467C2300AC56A8 /* Tools.swift in Sources */,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment