Commit graph

28 commits

Author SHA1 Message Date
Kent Sutherland
3cd3a111dd Update deployment targets to silence Xcode 14 warnings (#1573)
Summary:
## Changes in this pull request

Xcode 14 changed the minimum deployment target to iOS/tvOS 11.0 and macOS 10.13. This PR moves up the deployment targets so that a warning isn't shown on every build.

I also silenced the development region and base localization warnings.

### Checklist

- [x] All tests pass. Demo project builds and runs.
- [x] I added tests, an experiment, or detailed why my change isn't tested.
- [x] I added an entry to the `CHANGELOG.md` for any breaking changes, enhancements, or bug fixes.
- [x] I have reviewed the [contributing guide](https://github.com/Instagram/IGListKit/blob/main/.github/CONTRIBUTING.md)

Pull Request resolved: https://github.com/Instagram/IGListKit/pull/1573

Differential Revision: D45223095

Pulled By: TimOliver

fbshipit-source-id: 57fbd284809c09f86a9731d0676332de35fbe0df
2023-05-01 22:48:23 -07:00
Tim Oliver
f92b9339ee Standarize the copyright notice in all source files
Summary:
The standardized Meta copyright notice is "Copyright (c) Meta Platforms, Inc. and affiliates." and not "Copyright (c) Meta Platforms, Inc. and its affiliates." (Dropping the "its")

This diff updates the copyright notice in each source file to the correct this.

Reviewed By: willbailey

Differential Revision: D44737667

fbshipit-source-id: 643bf36df76723e70d9d826c53cf8f29b8a0c8cc
2023-04-06 02:44:16 -07:00
Lvv.me
c9e045c942 Improve SwiftPM support (#1546)
Summary:
This diff imports and refines the PR made by cntrump on GitHub.

The PR introduces the following:

* Sample apps now use SPM instead of CocoaPods to import IGListKit.
* Adds Mac Catalyst as an example target.
* Adds C++ flags to the CocoaPods specs.
* Fixes a script issue that was discovered when regenerating the symlinks.

The PR originally aimed to remove the need for symlinked references to the IGListKit and IGListDiffKit source files, but in testing, I couldn't get it working. It's possible SPM being too strict [on where the headers can be placed to be discovered](https://forums.swift.org/t/how-do-i-specify-the-headers-directory-for-a-objc-target-in-swift-package-managers-package-swift/58531/3).

Additionally, another issue was that the original PR changed all of the `#import` statements to the the modular `import` statements, which is fine for the sample apps, but ended up breaking compatibility for any apps that had modules disabled.

## Changes in this pull request

Improve SwiftPM support:

Build module `IGListDiffKit` and `IGListKit` as Objective-C++.

module `IGListDiffKit`:
    - Source/IGListDiffKit
    - module defined in `Source/IGListDiffKit/modulemap/module.modulemap`
    - requires `-fmodules` and `-fcxx-modules`

module `IGListKit`:
    - depend on `IGListDiffKit`, use `import IGListDiffKit;`
    - Source/IGListKit
    - module defined in `Source/IGListKit/modulemap/module.modulemap`
    - requires `-fmodules` and `-fcxx-modules`

module `IGListSwiftKit`:
    - depend on `IGListKit`, use `import IGListKit`
    - Source/IGListSwiftKit

Deleted `spm/` and `scripts/generate_spm_sources_layout.sh`, it is unnecessary.

Updated `.podspec`, add `'OTHER_CFLAGS' => '-fmodules'` and `'OTHER_CPLUSPLUSFLAGS' => '-fcxx-modules'`.

Add missing swift files for `IGListSwiftKit` in `IGListKit.xcodeproj`

### How to use

Replace `#import <IGListDiffKit/IGListDiffKit.h>` with `import IGListDiffKit;`, because `IGListDiffKit.h` isn't exist in `modulemap/`, Or create a symbol link by `ln -sf ../IGListDiffKit.h` for support it ?

### Examples

Use SwiftPM for building examples.

### Checklist

- [x] All tests pass. Demo project builds and runs.
- [x] I added tests, an experiment, or detailed why my change isn't tested.
- [ ] I added an entry to the `CHANGELOG.md` for any breaking changes, enhancements, or bug fixes.
- [x] I have reviewed the [contributing guide](https://github.com/Instagram/IGListKit/blob/master/.github/CONTRIBUTING.md)

Pull Request resolved: https://github.com/Instagram/IGListKit/pull/1546

Test Plan: Test PR showing running tests: https://github.com/TimOliver/IGListKit/actions/runs/4339956050/jobs/7578047058

Reviewed By: lorixx

Differential Revision: D33592395

Pulled By: TimOliver

fbshipit-source-id: 8f7b1873f2b1c6a80908bb55b123e31bea13bb0c
2023-03-06 23:29:41 -08:00
Tim Oliver
a1b9c2ddb3 Updated corporate branding in IGListKit source files
Summary:
A quick push to fix something I noticed while studying how IGListKit works. This simply replaces "Facebook, Inc" with "Meta Platforms, Inc" in all of the source files where the company copyright notice is posted. This should help bring our external facing projects more in line with our new corporate branding.

There's still a lot more references to "Facebook" as a company in the library (especially around linking to other Meta sponsored open source libraries), but this might need additional scrutiny and review on a case-by-case basis, so let's handle those ones separately.

Reviewed By: lorixx

Differential Revision: D41207363

fbshipit-source-id: 57cdbf5eb1023b41a5f32c0c05e01628686a19fe
2022-11-15 21:47:29 -08:00
Nate Stedman
1a44045dce Run lint on IGListKit
Differential Revision: D19141253

fbshipit-source-id: 9ed4c278a91bb48a1f6d33cafa9ce8f21861573d
2019-12-19 09:34:42 -08:00
Nate Stedman
f367b455a6 Properly split IGListDiffKit and IGListKit podspecs (#1385)
Summary:
Pull Request resolved: https://github.com/Instagram/IGListKit/pull/1385

I attempted to work the two frameworks into a single podspec, but it didn't really work that well. Instead, let's just split them into two podspec files - this should work fine, and more closely follows the Carthage/Xcode behavior.

This should address #1382. Note that the attached project does need to be edited, because we also need to manually specify the `IGListDiffKit` pod location. This issue will go away with the release of 4.0.

Reviewed By: iperry90

Differential Revision: D18449843

fbshipit-source-id: 2750aee1ba39d21b9f1b3521ea8911929ae728b1
2019-11-13 05:30:28 -08:00
Nate Stedman
c9aab95df8 Use script to fetch version for podspec
Summary: This allows us to have a single declaration of the version in the `Info.plist`, and have it automatically synced to the podspec. I'm going to split the podspecs as I did it wrong (#1382) when splitting the libraries, so this avoids having three places where the version is declared.

Reviewed By: iperry90

Differential Revision: D18449842

fbshipit-source-id: 2991180ee14003b8ebe1f4ef601036404315dfd6
2019-11-13 05:30:27 -08:00
Ian Perry
2fa963bfa3 Drop support for iOS 8 (#1381)
Summary:
Pull Request resolved: https://github.com/Instagram/IGListKit/pull/1381

https://github.com/Instagram/IGListKit/issues/1078

Dropping support for iOS 8
- Removed checks for iOS 8
- Updated xcodeproj file
- Updated Travis
- Updated podspec

Reviewed By: bdotdub, lorixx

Differential Revision: D18249291

fbshipit-source-id: eba9814b71e67fdc0ef50fcbc809189d86e8c5fb
2019-11-01 12:40:19 -07:00
Nate Stedman
e4c60650f2 Split IGListKit and IGListDiffKit (#1377)
Summary:
Pull Request resolved: https://github.com/Instagram/IGListKit/pull/1377

This splits the diffing-only components from `IGListKit` out into a separate library, `IGListDiffKit`, allowing them to be used independently of the rest of `IGListKit`. We've found that the diffing components of the library are useful independently of the rest of the `UICollectionView` infrastructure, and separating the libraries allows apps to take advantage of those components without paying the full binary size cost of `IGListKit`. The diffing components are available as a subspec in Cocoapods, and as an independent framework in Carthage and direct Xcode project import (i.e. Git submodules).

This is a breaking change, necessitating a major version bump, although it should have only minor impact for projects using the umbrella header `IGListKit.h`, as that header continues to import the diffing utilities. In particular, for a project using Cocoapods and importing `IGListKit.h`, there should be no code changes required.

Reviewed By: calimarkus

Differential Revision: D18114249

fbshipit-source-id: 363b5a427e32800bbc6e82f897230963b4167245
2019-10-31 08:26:12 -07:00
Ryan Nystrom
5c33c88024 Update README and podspec with new license, bump version to 3.4
Summary:
See title
Closes https://github.com/Instagram/IGListKit/pull/1162

Differential Revision: D7836821

Pulled By: rnystrom

fbshipit-source-id: ebab8ec40a62ea467ae82546587bf49ae3a7d577
2018-05-01 16:10:19 -07:00
Ryan Nystrom
e0984202e7 Bump version to 3.3.0
Summary:
Updating the pod and project version to 3.3.0 in preparation for a new release.
Closes https://github.com/Instagram/IGListKit/pull/1150

Differential Revision: D7691115

Pulled By: rnystrom

fbshipit-source-id: 145bc0930eb4a04809f0f4a0e7fc2a326fbd366c
2018-04-19 14:06:20 -07:00
Ryan Nystrom
96445ef2a0 Update podspec, project, and examples to 3.2
Summary: Closes https://github.com/Instagram/IGListKit/pull/1087

Differential Revision: D6917772

Pulled By: rnystrom

fbshipit-source-id: a1e965c58d6da6ef5b32a3bc3c2f23f37fc64794
2018-02-06 15:47:20 -08:00
Ryan Nystrom
37c798ac78 Bump min macOS version to 10.11 #trivial
Summary:
Followup from #1068

The `NSIndexPath` methods we use **are not** available <10.11. In theory this has always been "broken" b/c older macOS versions would crash at runtime when trying to use these methods.

Normally this would be breaking change, but I can't imagine anyone is using IGListKit on the mac targeting 10.10 and shipping a working app.

cc jessesquires for thoughts

This should be the last remaining item before we get a green badge.

(note that 10.11 was released 9/30/15 which is about 2 weeks before the public IGListKit release)
Closes https://github.com/Instagram/IGListKit/pull/1080

Differential Revision: D6894369

Pulled By: rnystrom

fbshipit-source-id: e5992c7bba68b21704af6bc8fb889b5427266954
2018-02-03 08:31:28 -08:00
Ryan Nystrom
65a5e6de05 Fix binding SC deselection crash and publish 3.1.1
Summary:
- Fixed #918 by checking `respondsToSelector:` (boo optionals)
- Cut 3.1.1 for immediate publish

- [x] All tests pass. Demo project builds and runs.
- [x] I added tests, an experiment, or detailed why my change isn't tested.
- [x] I added an entry to the `CHANGELOG.md` for any breaking changes, enhancements, or bug fixes.
Closes https://github.com/Instagram/IGListKit/pull/921

Differential Revision: D5748009

Pulled By: rnystrom

fbshipit-source-id: b387b3988abc785f312bc47ac003851283972d7a
2017-08-31 12:51:10 -07:00
Ryan Nystrom
d936d79b93 Bump versions to 3.1.0
Summary:
Bumping project, pod, and doc versions to 3.1.0
Closes https://github.com/Instagram/IGListKit/pull/908

Differential Revision: D5689815

Pulled By: rnystrom

fbshipit-source-id: 30345f12538f57efb467bf8159ec9645fe8aea96
2017-08-23 11:33:50 -07:00
Ryan Nystrom
d1cd23b3d0 Bump pod and project version to 3.0.0
Summary:
Part of #707
Closes https://github.com/Instagram/IGListKit/pull/731

Reviewed By: rnystrom

Differential Revision: D5036877

Pulled By: jessesquires

fbshipit-source-id: f63ce3369019870df87ebde59d6f6b0e95c8ad87
2017-05-10 12:32:05 -07:00
Jesse Squires
c19379eeda Release 2.1.0 prep
Summary:
Prepping for `2.1.0`

- [x] Bump version numbers
- [x] Rebase this branch after remaining PRs are closed
- [ ] Run `pod install` (**must be done internally**)
- [x] Re-gen docs
Closes https://github.com/Instagram/IGListKit/pull/380

Reviewed By: rnystrom

Differential Revision: D4381222

Pulled By: jessesquires

fbshipit-source-id: 04646168d3c84d0dd2c08f0a357836b9326f8963
2017-01-04 10:14:37 -08:00
Sherlock
a748e6f6c7 Changed minimum macOS deployment target to 10.10
Summary:
Worth noting that while we support 10.8 and newer, Swift support is only 10.9 and newer. There were only a few more errors for 10.9 deployment target, but I'm not familiar with how it all works.

Using an `available` to disable row actions for users on 10.10 (only available for 10.11 and newer).
Closes https://github.com/Instagram/IGListKit/pull/374

Differential Revision: D4372977

Pulled By: jessesquires

fbshipit-source-id: 19f4b50c8eb4aa92f80241d69c44a367e854f5e8
2016-12-29 11:13:57 -08:00
James Sherlock
5cd771b546 Added Subspec for Diffing
Summary:
So the main Podspec file now has two Subspecs, `Diffing` and for lack of better name `Default`. `Diffing` is purely the files within the common directories (used for Diffing, if in the future we support MacOS NSCollectionView then this may need changing). `Default` depends on `Diffing` but also adds all the non-common files.

To use it via CocoaPods, nothing changes. You `import IGListKit` and you will only have access to the files in the pod you use. (So if you use `IGListKit/Diffing` in your Podfile, then you will only get access to the diffing files). If you do a manual installation, or I assume via Carthage, then you will need to import the correct header file (either `IGListDiffKit.h` or `IGListKit.h` depending on what you want).

Turns out CocoaPods creates it's own umbrella header (unless you tell it otherwise) meaning our ones are unused by it.

Just to confirm `IGListKit` in your Podfile will give you everything, only if you add `/Diffing` will you "opt-out" o
Closes https://github.com/Instagram/IGListKit/pull/368

Differential Revision: D4367438

Pulled By: jessesquires

fbshipit-source-id: 272318ca551e7e8c4177ca3ca501fde23bd9705a
2016-12-27 12:44:27 -08:00
Jesse Squires
4e42712e5b fixup common files and podspec, #270
Summary:
- Add missing common files
- Fix podspec for common files
- Pod install all examples

Reviewed By: rnystrom

Differential Revision: D4350871

fbshipit-source-id: 708ebe6ce66caed75af5b2ac18920dcf45567d16
2016-12-19 21:44:13 -08:00
Jesse Squires
9600c23d15 run pod install everywhere, gen docs.
Summary:
- Project fixes for macOS support, #270
- Podspec fixes for macOS, #270
- Project test target fixes
- Pod install all examples
- Re-gen docs

Differential Revision: D4327169

fbshipit-source-id: bbe7896f8f50aaf3b8da03d0c21a0fb6f775c7cd
2016-12-14 14:44:10 -08:00
Jesse Squires
b52510559d Fix podspec for macOS support
Summary: Closes https://github.com/Instagram/IGListKit/pull/330

Differential Revision: D4327087

Pulled By: jessesquires

fbshipit-source-id: a63ad7770763d95de1333be130673732706b7e36
2016-12-14 09:44:08 -08:00
Jesse Squires
69c3cc73e7 macOS support follow-up work, #270
Summary:
Progress on #270.

- Setup basic, empty example project
- Setup test target and add tests that work for macOS
- Update changelog
- Update travis-ci
Closes https://github.com/Instagram/IGListKit/pull/328

Differential Revision: D4325876

Pulled By: jessesquires

fbshipit-source-id: 342963ce5103d3980c697655e1f1a9b6f3f1c520
2016-12-13 23:14:07 -08:00
Guilherme Rambo
3da0a6bf84 macOS support
Summary:
Added support for macOS. The macOS target includes only the core diffing functionality so `IGListDiff` can be used on macOS apps.

I have not added the tests because I don't know how you're setting them up, maybe the same tests can be used by adding some `#if os(...)`s to the test files.

I have tested integration on iOS, tvOS and macOS using both Carthage and Cocoapods.
Closes https://github.com/Instagram/IGListKit/pull/235

Differential Revision: D4325423

Pulled By: jessesquires

fbshipit-source-id: 871bf08410061306004872f5feb7a09d362b6bc1
2016-12-13 20:44:07 -08:00
Ryan Nystrom
7f56e0fec0 Update podspec and project version to 2.0.0
Summary:
This needs to land and be part of #307 before that gets merged, right?

Part of #306
Closes https://github.com/Instagram/IGListKit/pull/308

Differential Revision: D4306594

Pulled By: rnystrom

fbshipit-source-id: 59314d669f2d42f7dc7856249cf53b81ca001466
2016-12-09 10:44:02 -08:00
Jesse Squires
e4a47193c1 Add tvOS support. Close #118
Summary:
Closes #118.

- Add tvOS framework + test targets
- Add shared scheme `IGListKit-tvOS`
- Update `Podfile` and `.podspec`
- Update `.travis.yml`
- Update `CHANGELOG`
- Update `README`
- Run `pod install` and check-in updates

- [x] All tests pass. Demo project builds and runs.
- [x] I added tests, an experiment, or detailed why my change isn't tested.
- [x] I have reviewed the [contributing guide](https://github.com/Instagram/IGListKit/blob/master/CONTRIBUTING.md)
Closes https://github.com/Instagram/IGListKit/pull/137

Differential Revision: D4101583

Pulled By: rnystrom

fbshipit-source-id: f2736f16ad9f61ad5348c5e93571f3b752deec98
2016-10-29 14:44:11 -07:00
Ryan Nystrom
e2d11d95f6 Update podspec version tag
Summary: Title

Reviewed By: jeremycohen

Differential Revision: D4002326

fbshipit-source-id: 9761bf7938b09603abb0f6597974613cbc7b593b
2016-10-11 10:59:11 -07:00
FBShipIt
cdc796746a Initial commit
fbshipit-source-id: c38b897b9e2b87c782e0e01b0145d9189dc7f9d8
2016-10-11 10:12:17 -04:00