xcodeproj-sort 1.0.1 → 1.0.2

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.
Files changed (3) hide show
  1. checksums.yaml +5 -5
  2. data/README.md +27 -1
  3. metadata +5 -5
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: d587209ce990e19a7cb9322e0911ccef4b66e154
4
- data.tar.gz: 9317a56395c8ebca2e78ca2604bee1f2beb2142a
2
+ SHA256:
3
+ metadata.gz: 5bf77888487c0eb7e0ea67e43fa7627642a766c4a706aea13303c87d500145d4
4
+ data.tar.gz: 5e8c14507d9ddb8f347fccc6d9c5b68ede529601c1c35872887b928ca5d20330
5
5
  SHA512:
6
- metadata.gz: 85ca14af77148247b829661e7c646d288e1173ba26052560efe88d130d333a24005050334e6f447443e5c2ddc7ddfc5e4e984f20341289e9384ad11f0966bf85
7
- data.tar.gz: eb4556e3e96db47e3f958bb182516ab10ba898786476dc76ac61f72a15298277442418792c1df49ec13bf484d45b358b4b4fbcfa7e2fed372197715d7c09427e
6
+ metadata.gz: 379183f66837f07eac1a97e2c79002171f985e37bd61a224dc9750106ca8dfd589a0e22aaeb61bfffa68715855290414c95c9182789cdbbfc786ee1bb96bac7e
7
+ data.tar.gz: 840de7e1c7285f832fc2771b21d7e9808e00b3f9dce978b79824e4319950fad4146d0f4be0a5d235e42a6b8aebb4c085a799457a57e76480a938d3237dca7051
data/README.md CHANGED
@@ -1,6 +1,8 @@
1
1
  # xcodeproj-sort-pre-commit-hook
2
2
  A pre-commit hook that sorts your xcodeproj file.
3
3
 
4
+ <img src="https://i.imgur.com/knSvFpV.png" height="700">
5
+
4
6
  ## What is it?
5
7
  This repo provides a ready to use [pre-commit](https://pre-commit.com/) hook for automatically sorting your Xcode project. The hook looks for files ending in .pbxproj that have been modified and sorts their project group hierarchy automatically using the [Xcodeproj](https://github.com/CocoaPods/Xcodeproj/) gem. The effect is that the sort leaves your project file modified if it's not sorted, so that pre-commit won't allow the unsorted file to go through.
6
8
 
@@ -11,9 +13,10 @@ Add the following to your `.pre-commit-config.yaml`:
11
13
 
12
14
  ```
13
15
  - repo: git://github.com/noahsark769/xcodeproj-sort-pre-commit-hook
14
- sha: v1.0.0
16
+ sha: v1.0.2
15
17
  hooks:
16
18
  - id: xcodeproj-sort
19
+ args: [--groups-position=above]
17
20
  ```
18
21
 
19
22
  Then, run:
@@ -22,5 +25,28 @@ Then, run:
22
25
  pre-commit install
23
26
  ```
24
27
 
28
+ ### Options
29
+ Use the `--groups-position` option to specify the position of groups in the sort:
30
+ - `above`: Positions groups above objects in the sort
31
+ - `below`: Positions groups below objects in the sort
32
+
33
+ The default is to interleave groups and objects in the sort.
34
+
35
+ ### Running manually
36
+ The code runs in a rubygem which is build by `pre-commit`. To run a sort manually outside of `pre-commit`, install the gem locally:
37
+
38
+ ```
39
+ gem install xcodeproj-sort
40
+ ```
41
+
42
+ Then, run the gem with the project file as an argument:
43
+
44
+ ```
45
+ xcodeproj-sort MyProject.xcodeproj/project.pbxproj
46
+ ```
47
+
25
48
  ## Contributing
26
49
  I use this in the development of [Trestle](https://appstore.com/trestle), but your mileage might vary. If you notice a bug or have a feature request, please open a github issue or submit a pull request. It's best to open issues first so that work isn't duplicated.
50
+
51
+ ## Development
52
+ After closing the repo, you can run `make install` to build the gem and install locally, after which `xcodeproj-sort` should be in your path.
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: xcodeproj-sort
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
4
+ version: 1.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Noah Gilmore
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-02-12 00:00:00.000000000 Z
11
+ date: 2018-07-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: xcodeproj
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '1.3'
19
+ version: 1.5.9
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '1.3'
26
+ version: 1.5.9
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: claide
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -71,7 +71,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
71
71
  version: '0'
72
72
  requirements: []
73
73
  rubyforge_project:
74
- rubygems_version: 2.6.12
74
+ rubygems_version: 2.7.7
75
75
  signing_key:
76
76
  specification_version: 4
77
77
  summary: Sort your xcodeproj file in a pre-commit hook.