Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 12 additions & 4 deletions V2er.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -203,6 +203,7 @@
5D2B2B3926FF5DF800446F93 /* AccountInfo.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AccountInfo.swift; sourceTree = "<group>"; };
5D2B2B3B26FF754F00446F93 /* Persist.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Persist.swift; sourceTree = "<group>"; };
5D2B2B3D26FF797600446F93 /* AccountState.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AccountState.swift; sourceTree = "<group>"; };
5DA0000000000000000001 /* Version.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = Version.xcconfig; sourceTree = "<group>"; };
5D2DD00726FB353C0001C85A /* DefaultReducer.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DefaultReducer.swift; sourceTree = "<group>"; };
5D2DD00926FB443D0001C85A /* GlobalActions.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = GlobalActions.swift; sourceTree = "<group>"; };
5D368C8726C419D000794B8E /* APIService.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = APIService.swift; sourceTree = "<group>"; };
Expand Down Expand Up @@ -342,6 +343,14 @@
/* End PBXFrameworksBuildPhase section */

/* Begin PBXGroup section */
5DA0000000000000000002 /* Config */ = {
isa = PBXGroup;
children = (
5DA0000000000000000001 /* Version.xcconfig */,
);
path = Config;
sourceTree = "<group>";
};
5D179BFD2496F6EC00E40E90 /* Widget */ = {
isa = PBXGroup;
children = (
Expand Down Expand Up @@ -448,6 +457,7 @@
5D436FE724791C2C00FFA37E /* V2er */ = {
isa = PBXGroup;
children = (
5DA0000000000000000002 /* Config */,
5DE5C577249D90690004DCC6 /* General */,
5DE5B4C826845F4F00569684 /* View */,
5DA2AD3326C17E7F007FB1EF /* State */,
Expand Down Expand Up @@ -1011,6 +1021,7 @@
/* Begin XCBuildConfiguration section */
5D43700D24791C2D00FFA37E /* Debug */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = 5DA0000000000000000001 /* Version.xcconfig */;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_NONNULL = YES;
Expand Down Expand Up @@ -1061,19 +1072,18 @@
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 15.0;
MARKETING_VERSION = 1.1.2;
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
CURRENT_PROJECT_VERSION = 29;
};
name = Debug;
};
5D43700E24791C2D00FFA37E /* Release */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = 5DA0000000000000000001 /* Version.xcconfig */;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_NONNULL = YES;
Expand Down Expand Up @@ -1118,14 +1128,12 @@
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 15.0;
MARKETING_VERSION = 1.1.2;
MTL_ENABLE_DEBUG_INFO = NO;
MTL_FAST_MATH = YES;
SDKROOT = iphoneos;
SWIFT_COMPILATION_MODE = wholemodule;
SWIFT_OPTIMIZATION_LEVEL = "-O";
VALIDATE_PRODUCT = YES;
CURRENT_PROJECT_VERSION = 29;
};
name = Release;
};
Expand Down
2 changes: 1 addition & 1 deletion V2er/Config/Version.xcconfig
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@
MARKETING_VERSION = 1.1.2

// VERSION_CODE - Internal build number (e.g., 29, 30, 31...)
CURRENT_PROJECT_VERSION = 29
CURRENT_PROJECT_VERSION = 30
25 changes: 9 additions & 16 deletions VERSIONING.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,31 +20,24 @@ This project uses two version identifiers:

**Versions are now defined in ONE place only!**

The version numbers are defined at the project level and automatically inherited by all targets (Debug and Release).

### How to Update Versions

To update versions, you only need to modify **2 locations** in `V2er.xcodeproj/project.pbxproj`:
To update versions, simply edit the file `V2er/Config/Version.xcconfig`:

1. Search for the **Debug** project configuration and update:
```
/* Debug project configuration */
MARKETING_VERSION = 1.1.2; /* VERSION_NAME */
CURRENT_PROJECT_VERSION = 29; /* VERSION_CODE */
```
```bash
# Open the file
V2er/Config/Version.xcconfig

2. Search for the **Release** project configuration and update:
```
/* Release project configuration */
MARKETING_VERSION = 1.1.2; /* VERSION_NAME */
CURRENT_PROJECT_VERSION = 29; /* VERSION_CODE */
# Update these two lines:
MARKETING_VERSION = 1.1.2 # VERSION_NAME (user-facing version)
CURRENT_PROJECT_VERSION = 29 # VERSION_CODE (build number)
Copy link

Copilot AI Sep 22, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The documentation shows VERSION_CODE as 29, but the actual Version.xcconfig file was updated to 30. This creates inconsistency between the documentation example and the actual configuration.

Suggested change
CURRENT_PROJECT_VERSION = 29 # VERSION_CODE (build number)
CURRENT_PROJECT_VERSION = 30 # VERSION_CODE (build number)

Copilot uses AI. Check for mistakes.
```

That's it! The target configurations will automatically inherit these values.
**That's it!** No need to edit project.pbxproj or any other files. The xcconfig file is automatically loaded by Xcode and applies to all build configurations.

## Important Notes

1. **Both values must be updated** in both Debug and Release configurations
1. **Only update Version.xcconfig** - Never modify version numbers in project.pbxproj
2. **VERSION_CODE must always increase** - even for the same VERSION_NAME
3. **Fastlane auto-increment**: Our Fastlane setup automatically increments VERSION_CODE for TestFlight builds
4. **Info.plist**: Automatically uses these values via:
Expand Down
Loading