`skip create` uses the term "project" incorrectly
Nobody has claimed this yet.
- Dominant language
- Swift
- Stars
- 3.2k
- Forks
- 106
- Avg merge
- 6d 13h
- Merged PRs (30d)
- 1
Description
% skip create
Welcome to Skip 1.6.5!
Select type of project to create:
1: App: mobile application for Android and iOS
2: Library: library project with one or more modules
Enter selection (default: App) [1..2]
Select the mode of the project:
1: Skip Fuse: natively compiled project
2: Skip Lite: transpiled project
Enter selection (default: Skip Fuse) [1..2]
Enter the project-name for the App: project-name
Enter the CamelCase name of the App module: ModuleName
Optionally enter additional module names:
Enter the app bundle identifier: bundle.id
- It starts by asking what kind of "project" I want to create, but SwiftPM packages are not projects. (A "project" is an
.xcodeprojfolder.) It's incorrect to call a SwiftPM "package name" a "project name." - When you generate the app, the generated workspace is named
Project.xcworkspace, but that's a workspace, not a project. skip createprompts the user for a "module name" and then names the generated Xcode project after the module, giving two different things the same name, which is confusing.
I think it's really important to use the right terms for these things, because it's very difficult to Google for questions about Xcode structure when we're vague/approximate with the terms.
Here's my ideal conversation with skip create:
What do you want to create?
1: App: mobile application for Android and iOS
2: Library: SwiftPM library package with one or more modules
Enter selection (default: App) [1..2]
Select the mode of the app:
1: Skip Fuse: natively compiled
2: Skip Lite: transpiled to Kotlin
Enter selection (default: Skip Fuse) [1..2]
Enter an app bundle identifier in reverse-DNS format, e.g. com.mycompany.appname
App bundle identifier: com.mycompany.appname
Enter a CamelCase name for the Xcode workspace: WorkspaceName
Enter a CamelCase name for the Xcode app project [WorkspaceNameApp]: WorkspaceNameApp
The WorkspaceNameApp app project will depend on a "core" SwiftPM package.
Enter a CamelCase name for the app's core library module [WorkspaceNameAppCore]:
Enter a hyphenated-name for the app's core SwiftPM package [workspace-name-app-core]:
You can optionally create additional SwiftPM library modules in the workspace-name-app-core package.
(You can also add additional SwiftPM packages to the workspace, by running `skip create` in the WorkspaceName directory.)
Optionally enter additional CamelCase library module names: AdditionalLibraryName
Optionally enter additional CamelCase library module names:
The output would look like this, in a folder named after the workspace:
WorkspaceName/WorkspaceName.xcworkspace
WorkspaceName/Darwin/WorkspaceNameApp.xcodeproj
WorkspaceName/Darwin/Sources/Main.swift
WorkspaceName/Package.swift
WorkspaceName/Sources/WorkspaceNameAppCore/WorkspaceNameAppCore.swift
WorkspaceName/Sources/AdditionalLibraryName/ViewModel.swift
Or, apropos #453, it would be even better if it looked like this:
WorkspaceName/WorkspaceName.xcworkspace
WorkspaceName/Darwin/WorkspaceNameApp.xcodeproj
WorkspaceName/Darwin/Sources/Main.swift
WorkspaceName/workspace-name-app-core/Package.swift
WorkspaceName/workspace-name-app-core/Sources/WorkspaceNameAppCore/WorkspaceNameAppCore.swift
WorkspaceName/workspace-name-app-core/Sources/AdditionalLibraryName/ViewModel.swift
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the skip create command and inspect the prompts and generated paths shown in the issue. Compare the current terminology and layout with the proposed conversation and directory structure; the work is done when the generated workspace, Xcode app project, SwiftPM package, and module names are consistently presented.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- swift
- Domain
- cli, mobile
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100