How to Use The `$ swift build -C` Option πŸ’ƒ #swiftlang

πŸ₯ž
1 min readApr 8, 2016

--

https://www.pakutaso.com/20150501127post-5473.html

The Swift Package Manager has some options.

You can see the usage using `$ swift build --help` command.

The `-C`option makes `$ swift build` available for your project in another directory.

OPTIONS:

β€” chdir <value> Change working directory before any other operation [-C]

Example

Let's suppose your current directory is not the root of your project.

To build your project with `$ swift build`, run the following command in the current directory.

$ swift build -C <PathToRootOfYourProject>

You don't need to run `$ cd <PathToRootOfYourProject>` command. πŸ˜‡

--

--