Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release 2.0 #3374

Merged
merged 60 commits into from Oct 2, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
60 commits
Select commit Hold shift + click to select a range
bae01a2
[release-2.0] Merge branch 'main' into release-2.0
laxmorek Aug 29, 2021
3a9f24f
[release-2.0] Merge branch 'main' into release-2.0
laxmorek Aug 30, 2021
f48769b
[2.0] Remove cocoapods dependency (#3369)
Aug 30, 2021
5ae9ef6
[2.0] Remove support for deprecated names of manifests (#3373)
laxmorek Aug 31, 2021
5dc432e
chore: remove deprecated methods (#3381)
danieleformichelli Sep 1, 2021
6a57bed
Merge remote-tracking branch 'origin/main' into release-2.0
Sep 2, 2021
a0a2bf8
[2.0] Simplify TestAction's API (#3375)
Sep 3, 2021
cf5dc2e
[2.0] Remove "tuist doc" (#3401)
Sep 4, 2021
6d3c280
Update cocoapods to version 1.11.0 (#3397)
depfu[bot] Sep 4, 2021
434ae00
Update autoprefixer to version 10.3.4 (#3403)
depfu[bot] Sep 5, 2021
00a4732
Update gatsby-plugin-robots-txt to version 1.6.10 (#3404)
depfu[bot] Sep 5, 2021
9df1685
Merge branch 'main' into release-2.0
Sep 7, 2021
625795a
Improve tests of LinkGeneratorTests (#3409)
adellibovi Sep 8, 2021
6432738
docs: add MarvinNazari as a contributor for code (#3422)
allcontributors[bot] Sep 9, 2021
8f531a8
📦[Dependencies][SPM] Wire exclude to resources (#3305)
apps4everyone Sep 10, 2021
b4f2be8
Update tailwindcss to version 2.2.14 (#3428)
depfu[bot] Sep 10, 2021
c8bdc12
Update tailwindcss to version 2.2.15 (#3434)
depfu[bot] Sep 11, 2021
275c08b
Added Xcode 12.5.1 to tests and also made this version the default on…
fortmarek Sep 11, 2021
5b839f5
Update prettier to version 2.4.0 (#3429)
depfu[bot] Sep 11, 2021
6373518
[fix-acceptance-tests] fix - `Feature: Tuist dependencies.` (#3426)
laxmorek Sep 11, 2021
26950f5
feat: add support for .tuistignore in tuist edit command (#3415)
danieleformichelli Sep 12, 2021
157141e
Improve manifest detection and `tuist edit` performance by inspecting…
adellibovi Sep 12, 2021
bcb3288
Improve execution time for Acceptance Tests on CI (#3435)
adellibovi Sep 12, 2021
74453a4
Fix compilation issue
Sep 12, 2021
3236947
Merge remote-tracking branch 'origin/main' into release-2.0
Sep 13, 2021
4b6e035
Merge branch 'main' into release-2.0
danieleformichelli Sep 14, 2021
9fc1586
[2.0] Remove PresetBuildConfiguration in favour of ConfigurationName …
Sep 15, 2021
52e0120
[2.0] Remove up (#3443)
Sep 16, 2021
9ff42a4
Merge remote-tracking branch 'origin/main' into release-2.0
Sep 20, 2021
9ea6585
[2.0] Move test action options from `TestAction` to `TestActionOption…
Sep 21, 2021
b25e5cd
Merge remote-tracking branch 'origin/main' into release-2.0
Sep 22, 2021
d304730
Start writing the blog post about 2.0 release
Sep 22, 2021
6283cdb
Add more content to the blog post
Sep 22, 2021
8198b14
Merge branch 'main' into release-2.0
danieleformichelli Sep 22, 2021
8391063
Finish up the blog post for the 2.0 release
Sep 23, 2021
b192392
Remove yarn.lock
Sep 23, 2021
7559178
Add excerpt
Sep 23, 2021
1ba1830
feat: remove automatic bundles and tests focus (#3501)
danieleformichelli Sep 23, 2021
1142837
refactor: remove deprecated environment variables (#3493)
danieleformichelli Sep 25, 2021
d2b12d8
2.0 Flat configuration and custom configuration (#3457)
Sep 28, 2021
48b7f5a
Fix missing test property (#3520)
kwridan Sep 29, 2021
8f124be
Update projects/website/markdown/posts/2021-09-21-tuist-2.0/post.mdx
Sep 29, 2021
276990f
Update projects/website/markdown/posts/2021-09-21-tuist-2.0/post.mdx
Sep 29, 2021
57fca5c
Update projects/website/markdown/posts/2021-09-21-tuist-2.0/post.mdx
Sep 29, 2021
6f025ec
Update projects/website/markdown/posts/2021-09-21-tuist-2.0/post.mdx
Sep 29, 2021
ae44674
Address comment
Sep 29, 2021
c0eb806
Merge remote-tracking branch 'origin/main' into release-2.0
Sep 29, 2021
ab9300e
Version the documentation
Sep 29, 2021
0bd3ff8
Remove secrets
Sep 29, 2021
ac88207
Remove CocoaPods from the documentation
Sep 29, 2021
c0bbd92
Rename targetAction to targetScript
Oct 1, 2021
1eaa738
Update rubocop to version 1.22.0 (#3525)
depfu[bot] Sep 30, 2021
d7d1521
feat: improve performance loading Package.swift in parallel (#3529)
danieleformichelli Oct 1, 2021
43c781f
Update the CHANGELOG
Oct 1, 2021
46b6836
Merge remote-tracking branch 'origin/main' into release-2.0
Oct 2, 2021
272b7f4
Revert Package.resolved changes
Oct 2, 2021
abe8790
Fix building the website
Oct 2, 2021
6b3a28d
Some renames to scripts
Oct 2, 2021
315526e
Fix tests
Oct 2, 2021
08ed6bc
Update the style of the header
Oct 2, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
1 change: 0 additions & 1 deletion .github/workflows/tuist.yml
Expand Up @@ -114,7 +114,6 @@ jobs:
'run',
'scaffold',
'test',
'up',
'graph',
'tasks',
]
Expand Down
108 changes: 108 additions & 0 deletions CHANGELOG.md
Expand Up @@ -4,6 +4,114 @@ Please, check out guidelines: https://keepachangelog.com/en/1.0.0/

## Next

## 2.0 - Ikigai

### Changed

- **Breaking** made constructors from scheme action models internal and exposed static methods for initializing them instead. For example, `TestAction.init(..)` becomes `TestAction.testAction(...)`. [#3400](https://github.com/tuist/tuist/pull/3400) by [@pepibumur](https://github.com/pepibumur):
- **Motivation:**: Using static initializers gives us the flexibility to introduce improvements without breaking the API.
- **Migration:** Update all the action initializers to use the static methods instead. The name of the static method matches the name of the class but starting with a lowercase.
- **Breaking** `tuist focus` no longer includes automatically related tests and bundle targets as sources. [#3501](https://github.com/tuist/tuist/pull/3501) by [@danyf90](https://github.com/danyf90).
- **Motivation:** the behavior might cause to include unwanted targets in some scenario
- **Migration:** if you need to include tests and bundle targets as sources, specify them as arguments of the `tuist focus` command

### Removed

- **Breaking** `.cocoapods` target dependency
- **Motivation:** `.cocoapods`'s API led users to believe their integration issues were Tuist's fault. Therefore we decided to remove it and make it an explicit action developers need to run after the generation of Xcode projects through Tuist.
- **Migration:** we recommend wrapping the the generation of projects in a script that runs `pod install` right after generating the project: `tuist generate && pod install`. Alternatively, you might consider adopting Swift Package Manager and using our built-in support for package dependencies through the `Dependencies.swift` manifes tfile.
- **Breaking** Support for deprecated `TuistConfig.swift` has been ended. Define your configuration using `Config.swift`. Check [documentation](https://docs.tuist.io/manifests/config) for details. [#3373](https://github.com/tuist/tuist/pull/3373) by [@laxmorek](https://github.com/laxmorek)
- **Breaking** Support for deprecated `Template.swift` has been ended. Define your templates using any name that describes them (`name_of_template.swift`). Check [documentation](https://docs.tuist.io/commands/scaffold) for details. [#3373](https://github.com/tuist/tuist/pull/3373) by [@laxmorek](https://github.com/laxmorek)
- **Migration:** we recommend wrapping the generation of projects in a script that runs `pod install` right after generating the project: `tuist generate && pod install`. Alternatively, you might consider adopting Swift Package Manager and using our built-in support for package dependencies through the `Dependencies.swift` manifest file.
- **Breaking** simplified `TestAction`'s methods for creating an instance. [#3375](https://github.com/tuist/tuist/pull/3375) by [@pepibumur](https://github.com/pepibumur):
- **Motivation:** there was some redundancy across all the methods to initialize a `TestAction`. To ease its usage, we've simplified all of them into a single method. It takes the test plans as an array of `Path`s and the configuration as an instance of `PresetBuildConfiguration`. We've also made the `init` constructor internal to have the flexibility to change the signature without introducing breaking changes.
- **Migration:** In those places where you are initializing a `TestAction`, update the code to use either the `.testActions` or the `.targets` methods.
- **Breaking** removed the `tuist doc` command. [#3401](https://github.com/tuist/tuist/pull/3401) by [@pepibumur](https://github.com/pepibumur)
- **Motivation:** the command was barely used so we are removing it to reduce the maintenance burden and reduce the binary size.
- **Migration:** you can use Tuist tasks or [Fastlane](https://github.com/fastlane/fastlane) to run [swift-doc](https://github.com/SwiftDocOrg/swift-doc) and generate documentation from your generated projects.
- **Breaking** removed `PresetBuildConfiguration` in favour of `ConfigurationName`. [#3400](https://github.com/tuist/tuist/pull/3400) by [@pepibumur](https://github.com/pepibumur):
- **Motivation:** Making the configuration a type gives the developers the flexibility to provide their list of configurations through extensions. For example, `ConfigurationName.beta`.
- **Migration:** Scheme actions are now initialized passing a `configuration` argument of type `ConfigurationName`. Note that it conforms `ExpressibleByStringLiteral` so you can initialize it with a string literal.
- **Breaking** removed the `tuist up` command in favour of a sidecar CLI tool, [`tuist-up`](https://github.com/tuist/tuist-up) that can be installed independently.
- **Motivation:** provisioning environments for working with Xcode projects was outside of the scope of the project. Moreover, it added up to our triaging and maintenace work because errors that bubbled up from underlying commands made people think that they were Tuist bugs.
- **Migration:** as suggested [here](https://github.com/tuist/tuist-up), turn your `Setup.swift` into a `up.toml` and use `tuist-up` instead.
- **Breaking** Scheme `TestAction` options have been consolidated together under a new type `TestActionOptions`.
- **Motivation:** This makes the API consistent with some of the other Scheme actions as well as how it appears in the Scheme editor.
- **Migration:** Use `TestAction.targets(options: .options(language:region:codeCoverage:codeCoverageTargets))`
- `TestAction.language` > `TestActionOptions.language`
- `TestAction.region` > `TestActionOptions.region`
- `TestAction.codeCoverage` > `TestActionOptions.codeCoverage`
- `TestAction.codeCoverageTargets` > `TestActionOptions.codeCoverageTargets`
- **Breaking** removed deprecated `TUIST_*` configuration variables. [#3493](https://github.com/tuist/tuist/pull/3493) by [@danyf90](https://github.com/danyf90).
- **Motivation:**: They have been replaced by the corresponding `TUIST_CONFIG_*` variables instead.
- **Migration:** Use the corresponding `TUIST_CONFIG_*` variables instead.

- **Breaking** `Settings` is now publicly initialized via a new static method `.settings()`.
- **Motivation:** Using static initializers gives us the flexibility to introduce improvements without breaking the API.
- **Migration:** Replace `settings: Settings(base: ["setting": "value"])` with `settings: .settings(base: ["setting": "value"])`

- **Breaking** `CustomConfiguration` has been merged with `Configuration`.
- **Motivation:** Simplify the API and reduce confusion between `Configuration` and `CustomConfiguration`.
- **Migration:** Replace `let configurations: [CustomConfiguration] = [ ... ]` with `let configurations: [Configuration] = [ ... ]`.

- **Breaking** Specifying custom build settings files for default configurations via `Settings(base:debug:release:)` has changed.
- **Motivation:** To support the `CustomConfiguration` API simplification.
- **Migration:**
Replace

```swift
let settings = Settings(
debug: Configuration(settings: ["setting": "debug"]),
release: Configuration(settings: ["setting": "release"])
)
```

with:

```swift
let settings: Settings = .settings(
debug: ["setting": "debug"],
release: ["setting": "release"]
)
```

- **Breaking** Specifying xcconfig files for default configurations via `Settings(base:debug:release:)` has changed.
- **Motivation:** To support the `CustomConfiguration` API simplification.
- **Migration:**
Replace

```swift
let settings = Settings(
debug: Configuration(xcconfig: "configs/debug.xcconfig"),
release: Configuration(xcconfig: "configs/release.xcconfig")
)
```

with:

```swift
let settings: Settings = .settings(
configurations: [
.debug(name: .debug, xcconfig: "configs/debug.xcconfig"),
.release(name: .release, xcconfig: "configs/release.xcconfig"),
]
)
```
- **Breaking** Rename target `actions` to `scripts` to align with Xcode's terminology [#3374](https://github.com/tuist/tuist/pull/3374) by [@pepibumur](https://github.com/pepibumur)
- **Motivation** To align with Xcode's terminology used for the build phase counterpart, `scripts`.
- **Migration**
Replace

```swift
let target = Target(actions: [.post(tool: "/bin/echo", arguments: ["rocks"], name: "tuist")])
```

with

```swift
let target = Target(scripts: [.post(tool: "/bin/echo", arguments: ["rocks"], name: "tuist")])
```

## 1.52.0 - Pelae

### Changed
Expand Down
36 changes: 0 additions & 36 deletions Package.swift
Expand Up @@ -110,40 +110,6 @@ let package = Package(
name: "TuistCoreIntegrationTests",
dependencies: ["TuistCore", "TuistSupportTesting"]
),
.target(
name: "TuistDoc",
dependencies: [
swiftToolsSupportDependency,
"TuistCore",
"TuistGraph",
"TuistSupport",
signalsDependency,
rxBlockingDependency,
]
),
.target(
name: "TuistDocTesting",
dependencies: [
"TuistDoc",
swiftToolsSupportDependency,
"TuistCore",
"TuistCoreTesting",
"TuistSupportTesting",
]
),
.testTarget(
name: "TuistDocTests",
dependencies: [
"TuistDoc",
"TuistDocTesting",
swiftToolsSupportDependency,
"TuistSupportTesting",
"TuistCore",
"TuistCoreTesting",
"TuistGraphTesting",
"TuistSupport",
]
),
.target(
name: "TuistKit",
dependencies: [
Expand All @@ -166,7 +132,6 @@ let package = Package(
"TuistDependencies",
"TuistLinting",
"TuistCloud",
"TuistDoc",
"GraphViz",
"TuistMigration",
"TuistAsyncQueue",
Expand Down Expand Up @@ -196,7 +161,6 @@ let package = Package(
"TuistDependenciesTesting",
"TuistLintingTesting",
"TuistMigrationTesting",
"TuistDocTesting",
"TuistAsyncQueueTesting",
"TuistGraphTesting",
"TuistPlugin",
Expand Down
22 changes: 0 additions & 22 deletions Project.swift
Expand Up @@ -111,7 +111,6 @@ func targets() -> [Target] {
.target(name: "TuistDependencies"),
.target(name: "TuistLinting"),
.target(name: "TuistCloud"),
.target(name: "TuistDoc"),
.target(name: "TuistMigration"),
.target(name: "TuistAsyncQueue"),
.target(name: "TuistAnalytics"),
Expand All @@ -135,7 +134,6 @@ func targets() -> [Target] {
.target(name: "TuistDependenciesTesting"),
.target(name: "TuistLintingTesting"),
.target(name: "TuistMigrationTesting"),
.target(name: "TuistDocTesting"),
.target(name: "TuistAsyncQueueTesting"),
.target(name: "TuistGraphTesting"),
.target(name: "TuistPlugin"),
Expand All @@ -152,26 +150,6 @@ func targets() -> [Target] {
.target(name: "TuistGraphTesting"),
]
),
Target.module(
name: "TuistDoc",
dependencies: [
.target(name: "TuistCore"),
.target(name: "TuistGraph"),
.target(name: "TuistSupport"),
],
testDependencies: [
.target(name: "TuistSupportTesting"),
.target(name: "TuistCore"),
.target(name: "TuistCoreTesting"),
.target(name: "TuistGraphTesting"),
.target(name: "TuistSupport"),
],
testingDependencies: [
.target(name: "TuistCore"),
.target(name: "TuistCoreTesting"),
.target(name: "TuistSupportTesting"),
]
),
Target.module(
name: "TuistEnvKit",
hasTesting: false,
Expand Down
13 changes: 8 additions & 5 deletions Sources/ProjectDescription/AnalyzeAction.swift
@@ -1,13 +1,16 @@
import Foundation

public struct AnalyzeAction: Equatable, Codable {
public let configurationName: String
public let configuration: ConfigurationName

public init(configurationName: String) {
self.configurationName = configurationName
init(configuration: ConfigurationName) {
self.configuration = configuration
}

public init(config: PresetBuildConfiguration = .release) {
self.init(configurationName: config.name)
/// Returns an analyze action.
/// - Parameter configuration: Configuration used for analyzing.
/// - Returns: Analyze action.
public static func analyzeAction(configuration: ConfigurationName) -> AnalyzeAction {
return AnalyzeAction(configuration: configuration)
}
}
24 changes: 20 additions & 4 deletions Sources/ProjectDescription/ArchiveAction.swift
@@ -1,23 +1,39 @@
import Foundation

public struct ArchiveAction: Equatable, Codable {
public let configurationName: String
public let configuration: ConfigurationName
public let revealArchiveInOrganizer: Bool
public let customArchiveName: String?
public let preActions: [ExecutionAction]
public let postActions: [ExecutionAction]

public init(
configurationName: String,
init(
configuration: ConfigurationName,
revealArchiveInOrganizer: Bool = true,
customArchiveName: String? = nil,
preActions: [ExecutionAction] = [],
postActions: [ExecutionAction] = []
) {
self.configurationName = configurationName
self.configuration = configuration
self.revealArchiveInOrganizer = revealArchiveInOrganizer
self.customArchiveName = customArchiveName
self.preActions = preActions
self.postActions = postActions
}

public static func archiveAction(
configuration: ConfigurationName,
revealArchiveInOrganizer: Bool = true,
customArchiveName: String? = nil,
preActions: [ExecutionAction] = [],
postActions: [ExecutionAction] = []
) -> ArchiveAction {
return ArchiveAction(
configuration: configuration,
revealArchiveInOrganizer: revealArchiveInOrganizer,
customArchiveName: customArchiveName,
preActions: preActions,
postActions: postActions
)
}
}
9 changes: 0 additions & 9 deletions Sources/ProjectDescription/Arguments.swift
Expand Up @@ -4,15 +4,6 @@ public struct Arguments: Equatable, Codable {
public let environment: [String: String]
public let launchArguments: [LaunchArgument]

@available(*, deprecated, message: "Use init with `launchArguments: [LaunchArgument]` instead")
public init(environment: [String: String] = [:],
launchArguments: [String: Bool])
{
self.environment = environment
self.launchArguments = launchArguments.map(LaunchArgument.init)
.sorted { $0.name < $1.name }
}

public init(environment: [String: String] = [:],
launchArguments: [LaunchArgument] = [])
{
Expand Down
20 changes: 20 additions & 0 deletions Sources/ProjectDescription/BuildAction.swift
Expand Up @@ -16,4 +16,24 @@ public struct BuildAction: Equatable, Codable {
self.postActions = postActions
self.runPostActionsOnFailure = runPostActionsOnFailure
}

/// Returns a build action.
/// - Parameters:
/// - targets: Targets to be built.
/// - preActions: Actions to run before building.
/// - postActions: Actions to run after building.
/// - runPostActionsOnFailure: Whether pre and post actions should run on failure.
/// - Returns: Initialized build action.
public static func buildAction(targets: [TargetReference],
preActions: [ExecutionAction] = [],
postActions: [ExecutionAction] = [],
runPostActionsOnFailure: Bool = false) -> BuildAction
{
return BuildAction(
targets: targets,
preActions: preActions,
postActions: postActions,
runPostActionsOnFailure: runPostActionsOnFailure
)
}
}
2 changes: 0 additions & 2 deletions Sources/ProjectDescription/Config.swift
@@ -1,7 +1,5 @@
import Foundation

public typealias TuistConfig = Config

/// This model allows to configure Tuist.
public struct Config: Codable, Equatable {
/// Contains options related to the project generation.
Expand Down
38 changes: 38 additions & 0 deletions Sources/ProjectDescription/ConfigurationName.swift
@@ -0,0 +1,38 @@
import Foundation

/// It represent's a project configuration.
public struct ConfigurationName: ExpressibleByStringLiteral, Codable, Equatable {
/// Configuration name.
public let rawValue: String

internal init(_ rawValue: String) {
self.rawValue = rawValue
}

/// Initializes a configuration name with its name.
/// - Parameter value: Configuration name.
public init(stringLiteral value: StringLiteralType) {
self.init(value)
}

/// Initializes a configuration name with its name.
/// - Parameter name: Configuration name.
/// - Returns: Initialized configuration name.
public static func configuration(_ name: String) -> ConfigurationName {
self.init(name)
}
}

// Defaults provided by Tuist

public extension ConfigurationName {
/// Returns a configuration named "Debug"
static var debug: ConfigurationName {
ConfigurationName("Debug")
}

// Returns a configuration named "Release"
static var release: ConfigurationName {
ConfigurationName("Release")
}
}