[swift-build-dev] Questions about the SwiftPM `--update`

Martha JP jpmartha.jp at gmail.com
Fri Apr 1 15:07:52 CDT 2016


Hi, I'm JPMartha.

I mentioned the following questions on
https://github.com/apple/swift-package-manager/pull/228. But, I send that
to the mailing lists again.
Because I feel questions might be mentioned on the mailing list better than
GitHub PR.

----------

I understand the SwiftPM don't support running `--fetch` twice in the
current implementation.
-
https://lists.swift.org/pipermail/swift-build-dev/Week-of-Mon-20160328/000380.html

Then, can I ask any questions about `--update`?

Let's suppose the following situation:
- `MyApp` depends on `PackageA` and `B`.
- `PackageB` depends on `C`.

```
MyApp
├── Package A
└── Package B
    └── Package C
```

##### Questions #####

1. If `PackageA` requires update, then SwitPM should fetch `PackageA` only,
or all packages?
2. If `PackageB` requires update, then SwitPM should fetch both `PackageB`
and `C`?
3. if `PackageA-1.0.0` requires update to `2.0.0`, then SwiftPM shoud
remain `PackageA-1.0.0` directory, or remove?

- - -

#### P.S.

It seems the SwiftPM gets current package version from a part of directory
name in the `Packages` directory.
If `Lockfile` is supported, is it planned to change?

-
https://github.com/apple/swift-package-manager/blob/swift-DEVELOPMENT-SNAPSHOT-2016-03-24-a/Sources/Get/Fetcher.swift#L76-L86
-
https://github.com/apple/swift-package-manager/blob/swift-DEVELOPMENT-SNAPSHOT-2016-03-24-a/Sources/Get/Package.swift#L32-L34

Best regards,
JPMartha
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-build-dev/attachments/20160402/c5574307/attachment.html>


More information about the swift-build-dev mailing list