xcsize 1.0.0 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 0d86f0fe7c228c1c06cbb79130d170d87f3268f06b11fa73dc235f0d403bfaf2
4
- data.tar.gz: 3a2e220065e60cb8b5415c722d9fe7f4ddfb6c4d8b8fc2aa6dfb5b5f2b22c44c
3
+ metadata.gz: 1ce69483252bebcda8d879291e7e1521649894e0837e9c334123e04b71c512e0
4
+ data.tar.gz: 24ad243222c320c84dc4c2fe83c78c9044bbbb9274886b91c7cdf76332b909ae
5
5
  SHA512:
6
- metadata.gz: c0732e5fc2794a03ae60f56234d25097f047a20237bc8a39506c6e2b9c15ba7ca9ab6b40702851d9df668f6fde733b45395901bf5fc42a1b59afeb74e5b88b18
7
- data.tar.gz: 01f87c29009a16dd0f2c969182813be17934895c68259ff05e2db16d1dec59cffde428ed8aeebafe09afeb99b1cbf85a3621f22cb85d9a86fbf109db46c69271
6
+ metadata.gz: c8aedfd3e52b9708deadca84e52a183b979666f0aad92d60a8cf3ac3222ebe17ab7856fd7520a6becb6c44d8b1aa29b3a0b2bad47747a954baee073b080138d0
7
+ data.tar.gz: 13cf35bccb2a22a17abd770308534a0cb6b3d15d01ed8ae39379f771319e8d50195d2effd6f987b7d360b144e122e1fdef6cb1cf566ba46f6b3556f912b7e0f0
data/CHANGELOG.md ADDED
@@ -0,0 +1,28 @@
1
+ # XCSize Changelog
2
+
3
+ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
4
+
5
+ ## [1.2.0](https://github.com/testableapple/xcsize/releases/tag/1.2.0)
6
+
7
+ _November 10, 2025_
8
+
9
+ ### 🐛 Fixed
10
+
11
+ - Resolved an issue where the linkmap parser was not correctly handling invalid UTF-8 sequences in the linkmap file
12
+
13
+
14
+ ## [1.1.0](https://github.com/testableapple/xcsize/releases/tag/1.1.0)
15
+
16
+ _October 09, 2025_
17
+
18
+ ### 🐛 Fixed
19
+
20
+ - Resolved an issue where the fastlane plugin could trigger fastlane to run twice due to a conflict with the Ruby Commander gem
21
+
22
+ ## [1.0.0](https://github.com/testableapple/xcsize/releases/tag/1.0.0)
23
+
24
+ _October 08, 2025_
25
+
26
+ ### ✅ Added
27
+
28
+ - xcsize profile and compare commands
data/README.md CHANGED
@@ -27,7 +27,7 @@ $ gem install xcsize
27
27
  ### Profile a single linkmap
28
28
 
29
29
  ```bash
30
- xcsize profile --linkmap path/to/your/app.linkmap
30
+ xcsize profile --linkmap path/to/your/linkmap.txt
31
31
  ```
32
32
 
33
33
  Options:
@@ -37,7 +37,7 @@ Options:
37
37
  ### Compare two linkmaps
38
38
 
39
39
  ```bash
40
- xcsize compare --old-linkmap old.linkmap --new-linkmap new.linkmap
40
+ xcsize compare --old-linkmap old_linkmap.txt --new-linkmap new_linkmap.txt
41
41
  ```
42
42
 
43
43
  Options:
@@ -57,9 +57,9 @@ fastlane add_plugin xcsize
57
57
 
58
58
  ```ruby
59
59
  lane :test do
60
- xcsize(linkmap: 'path/to/your/app.linkmap')
60
+ xcsize(linkmap: 'path/to/your/linkmap.txt')
61
61
 
62
- xcsize_diff(old_linkmap: 'path/to/your/old.linkmap', new_linkmap: 'path/to/your/new.linkmap')
62
+ xcsize_diff(old_linkmap: 'path/to/your/old_linkmap.txt', new_linkmap: 'path/to/your/new_linkmap.txt')
63
63
  end
64
64
  ```
65
65
 
data/bin/xcsize CHANGED
@@ -3,5 +3,6 @@
3
3
 
4
4
  $LOAD_PATH.unshift(File.expand_path('../lib', __dir__))
5
5
  require 'xcsize'
6
+ require 'xcsize/cli'
6
7
 
7
8
  Xcsize::CLI.run
data/lib/xcsize/cli.rb CHANGED
@@ -1,5 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
+ require 'commander/import'
4
+
3
5
  module Xcsize
4
6
  class CLI
5
7
  def self.run
data/lib/xcsize/reader.rb CHANGED
@@ -90,17 +90,17 @@ module Xcsize
90
90
  end
91
91
 
92
92
  def self.parse_linkmap(path)
93
- unless File.exist?(path)
94
- puts("Error: linkmap file not found: #{path}")
95
- exit(1)
96
- end
93
+ raise "Linkmap file not found: #{path}" unless File.exist?(path)
97
94
 
98
95
  files = {}
99
96
  in_objects = false
100
97
  in_symbols = false
101
98
  id_to_path = {}
102
99
 
103
- File.foreach(path, chomp: true) do |line|
100
+ File.foreach(path, chomp: true, encoding: 'ASCII-8BIT') do |line|
101
+ # Convert to UTF-8, replacing invalid sequences
102
+ line = line.encode('UTF-8', 'ASCII-8BIT', invalid: :replace, undef: :replace)
103
+
104
104
  if line.start_with?('# Object files:')
105
105
  in_objects = true
106
106
  next
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Xcsize
4
- VERSION = '1.0.0'
4
+ VERSION = '1.2.0'
5
5
  end
data/lib/xcsize.rb CHANGED
@@ -4,8 +4,6 @@ require_relative 'xcsize/version'
4
4
  require_relative 'xcsize/profiler'
5
5
  require_relative 'xcsize/comparator'
6
6
  require_relative 'xcsize/reader'
7
- require_relative 'xcsize/cli'
8
- require 'commander/import'
9
7
  require 'json'
10
8
 
11
9
  module Xcsize
data/xcsize.gemspec CHANGED
@@ -24,7 +24,7 @@ Gem::Specification.new do |spec|
24
24
  spec.require_paths = ['lib']
25
25
  spec.required_ruby_version = '>= 2.4'
26
26
 
27
- spec.add_dependency('commander', '~> 4.6')
27
+ spec.add_dependency('commander', '>= 4.6', '< 6.0')
28
28
 
29
29
  spec.metadata['rubygems_mfa_required'] = 'true'
30
30
  end
metadata CHANGED
@@ -1,29 +1,35 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: xcsize
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alexey Alter-Pesotskiy
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2025-10-08 00:00:00.000000000 Z
11
+ date: 2025-11-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: commander
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - "~>"
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
19
  version: '4.6'
20
+ - - "<"
21
+ - !ruby/object:Gem::Version
22
+ version: '6.0'
20
23
  type: :runtime
21
24
  prerelease: false
22
25
  version_requirements: !ruby/object:Gem::Requirement
23
26
  requirements:
24
- - - "~>"
27
+ - - ">="
25
28
  - !ruby/object:Gem::Version
26
29
  version: '4.6'
30
+ - - "<"
31
+ - !ruby/object:Gem::Version
32
+ version: '6.0'
27
33
  description: A Ruby gem to profile iOS and macOS app and framework sizes from linkmap
28
34
  files, providing detailed breakdowns and insights.
29
35
  email:
@@ -38,7 +44,7 @@ files:
38
44
  - ".github/dependabot.yml"
39
45
  - ".gitignore"
40
46
  - ".rubocop.yml"
41
- - CHANGELOG
47
+ - CHANGELOG.md
42
48
  - Gemfile
43
49
  - LICENSE
44
50
  - README.md
data/CHANGELOG DELETED
@@ -1,11 +0,0 @@
1
- # XCSize Changelog
2
-
3
- The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
4
-
5
- ## [1.0.0](https://github.com/testableapple/xcsize/releases/tag/1.0.0)
6
-
7
- _October 08, 2025_
8
-
9
- ### ✅ Added
10
-
11
- - xcsize profile and compare commands