yonaskolb / yonaskolb/XcodeGen

Sources that are a syncedFolder are named for their full path

Open
#1,571 0 comments 9 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Swift
Stars
8.8k
Forks
908
Avg merge
17d 14h
Merged PRs (30d)
2

Description

In our project, we group related targets together in folders. When using syncedFolder it is removing the folders structure and naming the folder for the full path.

Expected

Previously it would produce the following group structure. The full folder structure was preserved by adding Modules to the fileGroups.

Using syncedFolder it was expected that the project would have the same structure, the only change would be that Sources would change from the group to a folder.

Image

Actual

It creates a folder with the name Modules/Example/Sources regardless of whether fileGroups is set or not.

When Modules is added to fileGroups, it also adds groups for Modules, Example, and Sources.

Image

Steps to reproduce

#!/bin/bash

# Create a folder for the project
mkdir -p example-project
cd example-project

# Create the folder structure and sources
mkdir -p Modules/Example/Sources
touch Modules/Example/Sources/main.swift

# Create the project.yml file
cat > project.yml << 'EOF'
name: Example
targets:
  example:
    platform: iOS
    type: framework
    sources:
    - path: "Modules/Example/Sources"
      type: syncedFolder
fileGroups:
- Modules
EOF

xcodegen

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by running the provided project.yml reproduction with xcodegen and inspect how syncedFolder sources and fileGroups are converted into the generated Xcode project. Done means the Sources folder preserves the Modules/Example hierarchy without creating redundant groups or naming a folder with the full path.

Written by the indexing model from the issue text.

Assessment

Tech stack
swift
Domain
build-system
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.