Commit Graph
210 Commits
Author SHA1 Message Date
Stan Wu 72bdc6bc0f Use static framework as prebuilt release for FacebookSDK.podspec
Summary:
* Use FacebookSDK_static.zip as prebuilt release
* Update release script to include LICENSE file in zip file
* Added `EXCLUDED_ARCHS` to make sure prebuilt release could still build in 3rd party apps
* Use `FBSDKCoreKit` for `FacebookSDK/CoreKit` to avoid conflicts caused by `Basics`

Reviewed By: joesus

Differential Revision: D26365101

fbshipit-source-id: 6915db7a6a924bd1309465b3e7a19545468273fe
2021-02-10 10:32:58 -08:00
Stan Wu 98c0e37892 Fix FBSDKCoreKit_Basics.zip (#1558)
Summary:
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1558

`release_basics ` was the last job for releasing, however, due to the cache in `BUILD_ROOT`, it's actually `FBSDKCoreKit.framework` from `BuildAllKits` ended up with being shipped as Basics module.

Reviewed By: Oliverccccct

Differential Revision: D24724966

fbshipit-source-id: f48ba01b86a08c973dc374e88a13997973e7f8a9
2020-11-04 11:35:46 -08:00
Joe Susnick fd86ddce8a Back out "Make Basics an actual dependency 2/n"
Summary: Original commit changeset: 32a9332a2d03

Reviewed By: dreamolight

Differential Revision: D24542238

fbshipit-source-id: bb55b9eeb9fba7e73080fb2cdfa33d16594acb0c
2020-10-26 12:15:30 -07:00
Joe Susnick 203b5ca02b Update Reference Doc Generation Script
Summary: For some reason Jazzy freaks out if there's an existing build in any one of the 'kit' directories. This makes sure existing build artifacts are deleted before generating the documentation.

Differential Revision: D24402710

fbshipit-source-id: 10a860d4ad6bdd8cd66a114154d047ae703740fa
2020-10-20 11:52:41 -07:00
Joe Susnick 1a8aa34081 Make Basics an actual dependency 2/n (#1526)
Summary:
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1526

## Context:

In terms of BUCK, CocoaPods and Swift Package Manager, CoreKitBasics is its own module.

Even in terms of xcodeproj it's its own target. This formalizes that dependency relationship.

## Why do this?

This allows us to avoid a lot of the messiness where we have something like:

```
#if defined FBSDKCOCOAPODS
 #import <FBSDKCoreKit/FBSDKCoreKit_Basics.h>
#elif defined BUCK
 #import <FBSDKCoreKit_Basics/FBSDKCoreKit_Basics.h>
#else
 #import "FBSDKCoreKit_Basics.h"
#endif
```
Now we can just do:
```
#import <FBSDKCoreKit_Basics/FBSDKCoreKit_Basics.h>
```
and it will "just work"

**Correction**: CocoaPods considers anything in a podspec to be part of the same module. Either future work will be needed to publish basics as its own module or we'll have to live with fragmented header imports.

So really the why do this comes down to having the correct code boundaries. In CocoaPods this is a subspec but in other areas it's on the module/product/target level.

## This diff

Adds FBSDKCoreKit basics as a linked dependency to the other kits. This relationship is not new but it was previously hidden by having Basics source files added to the other CoreKit targets. This also fixes the CoreKit+Internal dependency to depend on the library instead of just importing the header.

Reviewed By: dreamolight

Differential Revision: D24179749

fbshipit-source-id: 32a9332a2d0319c1d7579a28895d9d102dec0505
2020-10-16 08:47:31 -07:00
Joe Susnick 6dedbbd5b3 Fix Rsync Step (#1525)
Summary:
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1525

I made some faulty assumptions about why I was getting an rsync warning so I gated it behind a file check. This led to a false positive where it appeared that the files were being synced when they were not.

This updated code ignores the output of the step when it fails since it will fail for GamingServicesKit (because it contains no Swift files at the moment).

Reviewed By: tianqibt, dreamolight

Differential Revision: D24339344

fbshipit-source-id: fe5eccaf4e6bf379eb8b2f2ceffbf3d11fd0e65f
2020-10-15 13:18:32 -07:00
Joe Susnick 44694182e5 Fix Carthage for Xcode 12 (#1517)
Summary:
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1517

Fixes Carthage build for Xcode 12 by following script proposed in
https://github.com/Carthage/Carthage/blob/master/Documentation/Xcode12Workaround.md

Reviewed By: d16r

Differential Revision: D24227997

fbshipit-source-id: 475b6dcff7347e895b0ae40a90169580310dad40
2020-10-14 11:22:52 -07:00
Joe Susnick cc9f67162c Bump v8.0.0 (#1497)
Summary:
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1497

$title

Reviewed By: robtimp

Differential Revision: D23857192

fbshipit-source-id: b15055daee5a981abc88a55af7abf838f22fbe50
2020-09-23 15:43:34 -07:00
Joe Susnick 7a2f482441 Update Xcode Integration Project Path (#1418)
Summary:
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1418

Moves the `TestXcodeIntegration` project so that it can be built with Circle CI.

Reviewed By: Nathaaaalie

Differential Revision: D22309632

fbshipit-source-id: bce957c83961d017905566b4d97822d8842ab5f4
2020-06-30 15:46:31 -07:00
Joe Susnick ec5901336a Fixing documentation script (#1416)
Summary:
Thanks for proposing a pull request!

To help us review the request, please complete the following:

- [x] sign [contributor license agreement](https://developers.facebook.com/opensource/cla)
- [x] I've ensured that all existing tests pass and added tests (when/where necessary)
- [x] I've updated the documentation (when/where necessary) and [Changelog](CHANGELOG.md) (when/where necessary)
- [x] I've added the proper label to this pull request (e.g. `bug` for bug fixes)

## Pull Request Details

Fixes docs generation script.
Required adding back non-dynamic schemes.

Also fixes swiftlint job.

Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1416

Test Plan: `ruby ./scripts/genDocs.rb FBSDKCoreKit` for each of the kits

Reviewed By: dreamolight

Differential Revision: D22303500

Pulled By: joesus

fbshipit-source-id: b021a24655286c69b731c00c5f2740d48ee86b90
2020-06-30 12:24:47 -07:00
Joe Susnick 95ea647d4a Add CircleCI (#1406)
Summary:
Moves to CircleCI since Travis was timing out for release builds.

New release job is 2x faster (down from ~60 min to ~30 min)
New test job is 3x faster! (down from ~45 min to ~15 min)

* removing Travis CI and associated scripts
* updating `run.sh` to remove unused method
* updating `run.sh` to use alternative to realpath to avoid having to import coreutils on CircleCI
* removing Brewfile since we are not using it correctly
* adds CircleCI status badge to readme
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1406

Test Plan:
Ran release job with cocoapods checking trunk for existing versions instead of pushing to trunk.
https://app.circleci.com/pipelines/github/facebook/facebook-ios-sdk/167/workflows/a11ad0fd-c403-4f20-9077-4ee8951643dc
Github showed a draft release with the expected artifacts added.

{F240514523}

Checked that it only runs the test workflow on pushes to the expected branches. (currently master and circle-ci branches)

Checked that it only runs the release workflow on adding tags.  (will delete tag after this merges so that the draft release can be checked)

Reviewed By: dreamolight

Differential Revision: D22096602

Pulled By: joesus

fbshipit-source-id: 5e2a3b868f81721e59b217245ff886b73a20bf8a
2020-06-17 12:27:00 -07:00
Joe Susnick d5dc7380dd Travis building with Catalina to support Catalyst
Summary:
We should be building on Catalina so that we can provide support for mac catalyst.

The travis catalina machines only support xcode11.4 but there's no harm building on that instead of 11.3.

* Needed to add Swift version to GamingServices podspec to pass pod linting step
* Also needed split the release job into two jobs so that it will not time out. (the added time from building for Mac pushed it over the edge ~50 min)
* Also added `draft: true` to the deploy step since I'm not sure if having two deploy jobs will conflict and I don't want to publish the release if they do. Once we know this works I'll open another diff to remove this.

Reviewed By: dreamolight

Differential Revision: D21897349

fbshipit-source-id: 91e77f3b7491103be4e58364fcd1563128e139b6
2020-06-04 19:40:44 -07:00
Joe Susnick 7620ff537f Fix release binaries
Summary:
Outlined in this issue:
https://github.com/facebook/facebook-ios-sdk/issues/1380

tldr;  we are missing a build flag that lets xcode know it should include the `.swiftinterface` files.
We are also not copying it to the universal framework.

Reviewed By: dreamolight

Differential Revision: D21848386

fbshipit-source-id: 40c35bee648d9e58938af32975552e8480df0bbe
2020-06-04 14:06:10 -07:00
Joe Susnick 657c7bb907 Formatting for build script
Summary: Simple cleanup

Reviewed By: jingping2015

Differential Revision: D21887439

fbshipit-source-id: bfdb146fb9b8396f3626e4a953165bb63e2a9d05
2020-06-04 13:05:16 -07:00
Daniel Loomb d1da7e417b Adding a test to catch when GamingServicesKit doesn't compile
Summary: Adding new testing command.

Reviewed By: joesus

Differential Revision: D21734438

fbshipit-source-id: 02c9dd747468fe47f4ba796b19479970be7333b6
2020-05-28 15:46:52 -07:00
Zilin Zhang b30d302123 Deprecate MarketingKit in Podspec (#1389)
Summary:
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1389

As title

Reviewed By: joesus

Differential Revision: D21636890

fbshipit-source-id: a1aa0f225bf57b83d610cbad62981bb507de6c43
2020-05-19 13:20:15 -07:00
joesusnick ebdfec2c8e Adding release config check to CI (#1372)
Summary:
Thanks for proposing a pull request!

To help us review the request, please complete the following:

- [x] sign [contributor license agreement](https://developers.facebook.com/opensource/cla)
- [x] I've ensured that all existing tests pass and added tests (when/where necessary)
- [x] I've updated the documentation (when/where necessary) and [Changelog](CHANGELOG.md) (when/where necessary)
- [x] I've added the proper label to this pull request (e.g. `bug` for bug fixes)

## Pull Request Details

Travis CI does not support Catalina at this point. We need to make sure that it does not try to build Catalyst or it will fail.
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1372

Test Plan: Added CI test in order to test the portion of the release that was failing.

Reviewed By: KylinChang

Differential Revision: D21434764

Pulled By: joesus

fbshipit-source-id: 233a57fbbc45245c49a4eedb49b3cf41e7586068
2020-05-06 14:39:40 -07:00
joesusnick da76059698 Consolidating Swift and ObjC Targets (#1355)
Summary:
Thanks for proposing a pull request!

To help us review the request, please complete the following:

- [x] sign [contributor license agreement](https://developers.facebook.com/opensource/cla)
- [x] I've ensured that all existing tests pass and added tests (when/where necessary)
- [x] I've updated the documentation (when/where necessary) and [Changelog](CHANGELOG.md) (when/where necessary)
- [x] I've added the proper label to this pull request (e.g. `bug` for bug fixes)

## Pull Request Details

Updates for v7.0.

Main change is that the SDK can not be developed using Swift. Default will be to build and distribute with Xcode11 using Swift5.

**Migration Concerns**
* CocoaPods
If you were using the 'Swift'  subspec of CocoaPods, ex:
`pod 'FBSDKCoreKit/Swift'`
you can now simply use:
`pod 'FBSDKCoreKit`
* Carthage
You will need to use Xcode 11 or later but no other changes should be necessary. The binaries will include the enhanced Swift interfaces by default.
* SPM
No changes
* xcodebuild
No real changes. The '-Swift' targets are deleted. ex:
target `FBSDKCoreKitSwift-Dynamic` is gone. You can simply use `FBSDKCoreKit-Dynamic` and it will include Swift files
* BUCK
Buck will continue to exclude Swift files for the moment. This is an ongoing effort.
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1355

Test Plan: CI and extensive manual testing to make sure we haven't broken any channels.

Reviewed By: dreamolight

Differential Revision: D21239951

Pulled By: joesus

fbshipit-source-id: 325e2049c5fb1b55769c066998dd4b50e0ccaccc
2020-05-04 11:09:55 -07:00
joesusnick 609f21af28 Adding release check to CI (#1364)
Summary:
Thanks for proposing a pull request!

To help us review the request, please complete the following:

- [x] sign [contributor license agreement](https://developers.facebook.com/opensource/cla)
- [x] I've ensured that all existing tests pass and added tests (when/where necessary)
- [x] I've updated the documentation (when/where necessary) and [Changelog](CHANGELOG.md) (when/where necessary)
- [x] I've added the proper label to this pull request (e.g. `bug` for bug fixes)

## Pull Request Details

Adds common sanity checks to release to save time.
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1364

Test Plan:
`sh scripts/run.sh check-release-status`
Make sure it defaults to latest release.

`sh scripts/run.sh check-release-status 5.0.0`
Make sure you can set the release to verify.

Reviewed By: jingping2015

Differential Revision: D21329435

Pulled By: joesus

fbshipit-source-id: 80833ae7e7f397d782588a6185152b4d1c281208
2020-05-01 10:56:32 -07:00
joesusnick e005e4b58c Release CocoaPod CI Fixes (#1351)
Summary:
Thanks for proposing a pull request!

To help us review the request, please complete the following:

- [x] sign [contributor license agreement](https://developers.facebook.com/opensource/cla)
- [x] I've ensured that all existing tests pass and added tests (when/where necessary)
- [x] I've updated the documentation (when/where necessary) and [Changelog](CHANGELOG.md) (when/where necessary)
- [x] I've added the proper label to this pull request (e.g. `bug` for bug fixes)

## Pull Request Details

CocoaPods need to be released in three stages

Stage 1:
FBSDKCoreKit

Stage 2:
FBSDKLoginKit - depends on FBSDKCoreKit
FBSDKShareKit - depends on FBSDKCoreKit

Stage 3:
FBSDKGamingServicesKit - depends on FBSDKShareKit
FBSDKTVOSKit - depends on FBSDKCoreKit,FBSDKShareKit,FBSDKLoginKit

If you try to push these as part of the same release job they fail even with a somewhat significant  timeout. If you let it fail and try to retrigger it will fail because some pods are already pushed.

The other approach would be to allow the individual pushes to fail silently - we had this before but then there was no clear signal when we needed to rerun the job.
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1351

Test Plan:
Should print the correct commands in [this CI job](https://travis-ci.org/github/facebook/facebook-ios-sdk/builds/677772000):

Stage 1:
pod trunk push --allow-warnings FBSDKCoreKit.podspec

Stage 2:
pod trunk push --allow-warnings FBSDKLoginKit.podspec
pod trunk push --allow-warnings FBSDKShareKit.podspec

Stage 3:
pod trunk push --allow-warnings FBSDKGamingServicesKit.podspec
pod trunk push --allow-warnings FBSDKTVOSKit.podspec

Reviewed By: Nathaaaalie

Differential Revision: D21158325

Pulled By: joesus

fbshipit-source-id: 1a390b75f059657184dc5b116aa88bb3b7bb37b1
2020-04-23 10:18:42 -07:00
Joe Susnick 03aff2b6bb SPM Integration fix (#1339)
Summary:
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1339

Revision: my Bash is fine. My reading skills suck. In case anyone else runs into this.

From the travis docs:
"TRAVIS_PULL_REQUEST is set to the pull request number if the current job is a pull request build, or **false** if it’s not."

Reviewed By: KylinChang

Differential Revision: D21024971

fbshipit-source-id: 5dac28eb5844fd3eb1a9960ccd52d10e761eaad4
2020-04-14 13:33:55 -07:00
joesusnick d8beae9b6c Allow for building spm integration on either pr merge ref or master (#1336)
Summary:
Thanks for proposing a pull request!

To help us review the request, please complete the following:

- [x] sign [contributor license agreement](https://developers.facebook.com/opensource/cla)
- [x] I've ensured that all existing tests pass and added tests (when/where necessary)
- [x] I've updated the documentation (when/where necessary) and [Changelog](CHANGELOG.md) (when/where necessary)
- [x] I've added the proper label to this pull request (e.g. `bug` for bug fixes)

## Pull Request Details

We need to provide a valid branch to build the SPM  Integration project. In the case of PRs we want to use the merge ref provided by github. In the case that we're building master (after a merge) then we want to use the master branch.
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1336

Test Plan: CI

Reviewed By: KylinChang

Differential Revision: D20997655

Pulled By: joesus

fbshipit-source-id: 43f63e2f4a56f7f6b9a73ffa17a4e32221e3e12a
2020-04-13 21:30:09 -07:00
joesusnick 826fc90386 Point package integration to merge commit ref (#1327)
Summary:
Thanks for proposing a pull request!

To help us review the request, please complete the following:

- [x] sign [contributor license agreement](https://developers.facebook.com/opensource/cla)
- [x] I've ensured that all existing tests pass and added tests (when/where necessary)
- [x] I've updated the documentation (when/where necessary) and [Changelog](CHANGELOG.md) (when/where necessary)
- [x] I've added the proper label to this pull request (e.g. `bug` for bug fixes)

## Pull Request Details

The previous implementation would not work for forked repos because of how secrets are handled in Travis CI. This implementation should work for both and has the benefit of being simpler all around.
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1327

Test Plan: CI

Reviewed By: jingping2015

Differential Revision: D20928340

Pulled By: joesus

fbshipit-source-id: 3f87a6759428b46130f23385b8275e840423478e
2020-04-08 14:59:26 -07:00
Joe Susnick 4907715ee6 Fix Travis - Swift Package Job (#1326)
Summary:
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1326

It appears from [this run](https://travis-ci.org/github/facebook/facebook-ios-sdk/jobs/672585538) that the job failed because the logs were too verbose. This should fix that.

Reviewed By: Mxiim

Differential Revision: D20925373

fbshipit-source-id: ecb96d969489d8b19200ebf407d6dc64ca0719f7
2020-04-08 13:21:05 -07:00
Joe Susnick 5014562e46 Fail Cocoapod push job on failure (#1299)
Summary:
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1299

CocoaPods deploy job should fail properly when pods fail to push so that it can be rerun easily.

Reviewed By: Mxiim

Differential Revision: D20679020

fbshipit-source-id: 135148575d807e46e4c2d30131a99dd5a5d2eda7
2020-03-27 10:36:30 -07:00
Zilin Zhang 51557171db Fix pod lint issue in run.sh (#1296)
Summary:
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1296

As title
issue: https://travis-ci.org/github/facebook/facebook-ios-sdk/jobs/667066551?utm_medium=notification&utm_source=github_status

Reviewed By: joesus

Differential Revision: D20666429

fbshipit-source-id: 328641802664e05861582e395eb6c4ffc939bee3
2020-03-26 11:25:46 -07:00
joesusnick ce6be9e2a6 Hacky fix for pod release script (#1279)
Summary:
Thanks for proposing a pull request!

To help us review the request, please complete the following:

- [x] sign [contributor license agreement](https://developers.facebook.com/opensource/cla)
- [x] I've ensured that all existing tests pass and added tests (when/where necessary)
- [x] I've updated the documentation (when/where necessary) and [Changelog](CHANGELOG.md) (when/where necessary)
- [x] I've added the proper label to this pull request (e.g. `bug` for bug fixes)

## Pull Request Details

Describes situation in code comments.
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1279

Test Plan: Hard to test. We will know if we were successful on the next release.

Reviewed By: iquintero, KylinChang

Differential Revision: D20355152

Pulled By: joesus

fbshipit-source-id: 6386ab078fe84047cf37b0d084666d3fae1afcbe
2020-03-10 09:15:29 -07:00
joesusnick ec46fbc92b Adds dependent ShareKit podspec to linting for GamingServicesKit (#1278)
Summary:
Thanks for proposing a pull request!

To help us review the request, please complete the following:

- [x] sign [contributor license agreement](https://developers.facebook.com/opensource/cla)
- [x] I've ensured that all existing tests pass and added tests (when/where necessary)
- [x] I've updated the documentation (when/where necessary) and [Changelog](CHANGELOG.md) (when/where necessary)
- [x] I've added the proper label to this pull request (e.g. `bug` for bug fixes)

## Pull Request Details

GamingServicesKit has two podspec linting dependencies. Core and Share. This change accounts for that.
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1278

Test Plan: CI

Reviewed By: KylinChang, dreamolight

Differential Revision: D20353191

Pulled By: joesus

fbshipit-source-id: ce1bdd9ebe616ea87f770083a30ae1e6f214d4ab
2020-03-09 18:13:54 -07:00
joesusnick 69c4b33c1f Fix spm integration (#1272)
Summary:
Thanks for proposing a pull request!

To help us review the request, please complete the following:

- [x] sign [contributor license agreement](https://developers.facebook.com/opensource/cla)
- [x] I've ensured that all existing tests pass and added tests (when/where necessary)
- [x] I've updated the documentation (when/where necessary) and [Changelog](CHANGELOG.md) (when/where necessary)
- [x] I've added the proper label to this pull request (e.g. `bug` for bug fixes)

## Pull Request Details

I found there are two possible ways of setting up an integration test for SPM

First way would be to point to this repo. From there we can test the branch we're trying to merge in, or we can test master. We cannot point to the merge commit because Travis CI doesn’t actually push the merge commit to any branch (which is good normally but in this case we want it to). I opted to solve this by force-pushing the merge commit to a dummy branch and then testing against that.

The alternate way to set this up would be to point to the package with a file URL. This works locally but on both Travis CI and Github Workflows it results in an error that looks like:

```
xcodebuild: error: Could not resolve package dependencies:
An unknown error occurred. '/Users/runner/Library/Developer/Xcode/DerivedData/SmoketestSPM-bkrljbedpiwridakhqlllisyfeas/SourcePackages/checkouts/facebook-ios-sdk'
 exists and is not an empty directory (-4)
```
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1272

Test Plan: CI

Reviewed By: jingping2015

Differential Revision: D20283034

Pulled By: joesus

fbshipit-source-id: 246aadd6ee0ed456c13240aa37129374cd456e96
2020-03-05 15:08:37 -08:00
Joe Susnick 6fcfac60e9 Removing AccountKit
Summary: Removing deprecated AccountKit code.

Reviewed By: ct2mak

Differential Revision: D20229229

fbshipit-source-id: cb8a28284e4ed5930918c3b7db57cff94ad3acdf
2020-03-04 09:09:06 -08:00
Joe Susnick 21648fa738 GamingServicesKit Release Support (#1256)
Summary:
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1256

Adds support for releasing FBSDKGamingServicesKit

Additionally adds support for crash monitoring and remote feature management.

Reviewed By: iquintero

Differential Revision: D20080956

fbshipit-source-id: 837053dbdd7a0a6f9dc188b79a8fb5d1a068350c
2020-02-24 18:47:14 -08:00
Joe Susnick d4c13d48a5 Remove FBSDKPlacesKit
Summary:
PlacesKit is predicated on the existence of two endpoints:
`GET /search?type=place`
and
`GET /{place-information-id}`

These endpoints were removed in GraphAPI v6.0 so this kit is entirely non-functioning.

Reviewed By: jingping2015

Differential Revision: D19858088

fbshipit-source-id: 5cde7f04c6d6d6229175c75557d26043da546ec1
2020-02-13 13:28:52 -08:00
joesusnick 83c9eb143d Including GraphAPI headers for doc generation (#1223)
Summary:
Thanks for proposing a pull request!

To help us review the request, please complete the following:

- [x] sign [contributor license agreement](https://developers.facebook.com/opensource/cla)
- [x] I've ensured that all existing tests pass and added tests (when/where necessary)
- [x] I've updated the documentation (when/where necessary) and [Changelog](CHANGELOG.md) (when/where necessary)
- [x] I've added the proper label to this pull request (e.g. `bug` for bug fixes)

## Pull Request Details

Fixes doc generation script.
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1223

Test Plan: `sh scripts/run.sh release docs` then check that the docs are generated and available in the `docs` directory.

Reviewed By: jingping2015

Differential Revision: D19791197

Pulled By: joesus

fbshipit-source-id: 97d7b93a4c4f84f604cca5ea48111295d32e22ee
2020-02-07 17:25:18 -08:00
Joe Susnick 1b4dc3fd9c Cleanup script for SPM Headers (#1224)
Summary:
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1224

Script will fail for new kits that do not have an 'include' directory.

Reviewed By: jingping2015

Differential Revision: D19755345

fbshipit-source-id: 0455aa406921fa00bafbd23dc3013e322c708056
2020-02-06 09:44:26 -08:00
joesusnick 5d5de15f6a Fix release (#1222)
Summary:
Thanks for proposing a pull request!

To help us review the request, please complete the following:

- [x] sign [contributor license agreement](https://developers.facebook.com/opensource/cla)
- [x] I've ensured that all existing tests pass and added tests (when/where necessary)
- [x] I've updated the documentation (when/where necessary) and [Changelog](CHANGELOG.md) (when/where necessary)
- [x] I've added the proper label to this pull request (e.g. `bug` for bug fixes)

## Pull Request Details

Podspec dependencies were hardcoded to ~> 5.0. This fixes that.
Swift targets require headers to be declared public in Xcode. I removed some files and added them back without updating their visibility. This fixes that.
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1222

Test Plan: CI

Reviewed By: jingping2015

Differential Revision: D19737835

Pulled By: joesus

fbshipit-source-id: 13ec65f70c788ab78c535484aa5db96872fd5cc8
2020-02-04 22:28:21 -08:00
joesusnick 93d173a762 Only reporting errors in Travis release job (#1209)
Summary:
Thanks for proposing a pull request!

To help us review the request, please complete the following:

- [x] sign [contributor license agreement](https://developers.facebook.com/opensource/cla)
- [x] I've ensured that all existing tests pass and added tests (when/where necessary)
- [x] I've updated the documentation (when/where necessary) and [Changelog](CHANGELOG.md) (when/where necessary)
- [x] I've added the proper label to this pull request (e.g. `bug` for bug fixes)

## Pull Request Details

Previous release's xcodebuild command drowned Travis' logs and caused the build to fail. This should prevent this on the next release.

Note: There is a possibility that Travis will time out due to a LACK of output. If this happens we may need to add back xcpretty or find some other way to truncate output. Tried adding the '-quiet' flag to xcodebuild but this did not quiet output enough.
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1209

Test Plan: run `sh scripts/run.sh release github` this will not  actually push anything to github. You should see that there is minimal output. Also you can change something to fail and make sure that there is output as expected.

Reviewed By: Nathaaaalie

Differential Revision: D19628541

Pulled By: joesus

fbshipit-source-id: c08d4b921fa5a1a9d42ce2e859f9c5837608cf8a
2020-01-30 09:56:35 -08:00
joesusnick c5145f2e02 Updating CocoaPods release script (#1195)
Summary:
Thanks for proposing a pull request!

To help us review the request, please complete the following:

- [x] sign [contributor license agreement](https://developers.facebook.com/opensource/cla)
- [x] I've ensured that all existing tests pass and added tests (when/where necessary)
- [x] I've updated the documentation (when/where necessary) and [Changelog](CHANGELOG.md) (when/where necessary)
- [x] I've added the proper label to this pull request (e.g. `bug` for bug fixes)

## Pull Request Details

Manipulating output of `pod trunk push` was swallowing errors. Also was pointless since we were adding the `verbose` but then also had code to make it less verbose.

This should make the job fail when any pod fails to push.
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1195

Test Plan:
First off, do not worry. You will not overwrite the pod on trunk. Either you will not have permission to push or you will get an error because the version exists there already. In both cases the push will fail so you can test safely.

Old:
`pod trunk push --allow-warnings | tee pod.log | ruby -e 'ARGF.each{ print "." }'`
`echo $?` -> should be 1 but is 0

New:
`pod trunk push --allow-warnings`
`echo $?` -> should be 1 and is 1

Reviewed By: robtimp

Differential Revision: D19517035

Pulled By: joesus

fbshipit-source-id: 90db839a004194d3a619a25ca403ffa63b5c0fa8
2020-01-27 17:23:50 -08:00
joesusnick 90793e1248 Only installing gems on jobs that require gems (#1196)
Summary:
Thanks for proposing a pull request!

To help us review the request, please complete the following:

- [x] sign [contributor license agreement](https://developers.facebook.com/opensource/cla)
- [x] I've ensured that all existing tests pass and added tests (when/where necessary)
- [x] I've updated the documentation (when/where necessary) and [Changelog](CHANGELOG.md) (when/where necessary)
- [x] I've added the proper label to this pull request (e.g. `bug` for bug fixes)

## Pull Request Details

Attempting to only install gems on jobs that require gems.
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1196

Test Plan: Passing travis build

Reviewed By: jingping2015

Differential Revision: D19543203

Pulled By: joesus

fbshipit-source-id: 1dd85bc124e78ce71202d33a98bb010473f99e8c
2020-01-27 11:27:50 -08:00
joesusnick 365538e961 Stabilize flaky static podspec linting (#1199)
Summary:
Thanks for proposing a pull request!

To help us review the request, please complete the following:

- [x] sign [contributor license agreement](https://developers.facebook.com/opensource/cla)
- [x] I've ensured that all existing tests pass and added tests (when/where necessary)
- [x] I've updated the documentation (when/where necessary) and [Changelog](CHANGELOG.md) (when/where necessary)
- [x] I've added the proper label to this pull request (e.g. `bug` for bug fixes)

## Pull Request Details

Pretty sure there is no reason to ever lint FBSDKCoreKit by itself since it is linted as a dependent podspec by all of the other podspecs.

That said, for the extra safety it seems we can still lint it if it does not include itself as a dependent spec.
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1199

Test Plan: Travis

Reviewed By: ZebingZong

Differential Revision: D19524637

Pulled By: joesus

fbshipit-source-id: 3bc6d68ed0c6a1f49f881fbd00869a5a8bb9300a
2020-01-24 08:06:39 -08:00
joesusnick 888c8fcdee Updates CI to lint CocoaPod static libraries (#1178)
Summary:
Thanks for proposing a pull request!

To help us review the request, please complete the following:

- [x] sign [contributor license agreement](https://developers.facebook.com/opensource/cla)
- [x] I've ensured that all existing tests pass and added tests (when/where necessary)
- [x] I've updated the documentation (when/where necessary) and [Changelog](CHANGELOG.md) (when/where necessary)
- [x] I've added the proper label to this pull request (e.g. `bug` for bug fixes)

## Pull Request Details

Follow-up to [https://github.com/facebook/facebook-ios-sdk/issues/1173](https://github.com/facebook/facebook-ios-sdk/pull/1173).
Lints CocoaPod static libraries to make sure pods work when `use_frameworks!` is excluded from the Podfile.
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1178

Test Plan:
Travis job passes.
Or can do:
`./scripts/run.sh lint cocoapods`

Reviewed By: ZebingZong

Differential Revision: D19374242

Pulled By: joesus

fbshipit-source-id: b25e0ff0122b76dfdec26a5bd91562c4616c9b02
2020-01-18 16:48:25 -08:00
joesusnick 25114a85bb Adding integration test. (#1094)
Summary:
Thanks for proposing a pull request!

To help us review the request, please complete the following:

- [x] sign [contributor license agreement](https://developers.facebook.com/opensource/cla)
- [x] I've ensured that all existing tests pass and added tests (when/where necessary)
- [x] I've updated the documentation (when/where necessary) and [Changelog](CHANGELOG.md) (when/where necessary)
- [x] I've added the proper label to this pull request (e.g. `bug` for bug fixes)

## Pull Request Details

Probably a few pathing kinks to work out but the idea is to have a basic smoke test to make sure we don't break Swift Package Manager support.
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1094

Test Plan: Travis build.

Reviewed By: jingping2015

Differential Revision: D19289953

Pulled By: joesus

fbshipit-source-id: 277693372ce48dab3e6542d77987e419e2bea81c
2020-01-08 14:12:21 -08:00
joesusnick c2693116dd Updating script to check for bad symlinks (#1166)
Summary:
Thanks for proposing a pull request!

To help us review the request, please complete the following:

- [x] sign [contributor license agreement](https://developers.facebook.com/opensource/cla)
- [x] I've ensured that all existing tests pass and added tests (when/where necessary)
- [x] I've updated the documentation (when/where necessary) and [Changelog](CHANGELOG.md) (when/where necessary)
- [x] I've added the proper label to this pull request (e.g. `bug` for bug fixes)

## Pull Request Details

This fixes the an issue I saw earlier where a bad symlink resulted in a header not being exposed to projects that consume the SDK using Swift Package Manager
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1166

Test Plan:
Break one of the symlinks in the include directory by having it point to a missing file. You can do this by running
`cd FBSDKCoreKit/FBSDKCoreKit`
`ln -s FBSDKAccessToken.h include`

This will create a symlink in the include directory that points to itself.

from the project root run
`./scripts/run.sh verify-spm-headers`

It will log an error message and fail.

Reviewed By: jingping2015

Differential Revision: D19269125

Pulled By: joesus

fbshipit-source-id: 144d527694c6cf68cff898066e655edc834aa8cb
2020-01-06 14:47:19 -08:00
Tianqi Li ba7776adfa add version in Basics
Reviewed By: dreamolight

Differential Revision: D19003744

fbshipit-source-id: d1f8703807d760063ab8e2f7d6ff37c870a0667b
2019-12-14 14:25:39 -08:00
joesusnick fa5a8d1e13 Fixes for releasing Swift binaries (#1117)
Summary:
* Fixing dyanamic targets to have dynamic dependencies.

Thanks for proposing a pull request!

To help us review the request, please complete the following:

- [x] sign [contributor license agreement](https://developers.facebook.com/opensource/cla)
- [x] I've ensured that all existing tests pass and added tests (when/where necessary)
- [x] I've updated the documentation (when/where necessary) and [Changelog](CHANGELOG.md) (when/where necessary)
- [x] I've added the proper label to this pull request (e.g. `bug` for bug fixes)

## Pull Request Details

* Cleans up script so that only Swift targets are built
* Updates dynamic targets to have dynamic dependencies
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1117

Test Plan:
Run:
> sh scripts/run.sh release github swift
Note: You will need to clean your working copy as running this will move a bunch of schemes around.

Reviewed By: jingping2015

Differential Revision: D18529696

Pulled By: joesus

fbshipit-source-id: 91e4c6e758a584034f1595e0ad14030c3c51dadf
2019-11-15 13:30:36 -08:00
Joe Susnick 938200e0e0 Symlink verification for public headers (#1115)
Summary:
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1115

SPM requires that C headers exist in an 'include' directory in order to be visible to consuming libraries.

This is similar to how CocoaPods' podspecs use the "public_header_files" argument.

In CocoaPods we can use a list of directories that have public headers. SPM is much more prescriptive in that it wants all of the public headers in one directory. We are using directory of symlinks to meet this requirement.

This Travis job should prevent us from mistakenly shipping new features that have not been exposed through this symlinking mechanism.

Reviewed By: jingping2015

Differential Revision: D18513231

fbshipit-source-id: 08a3277cdb55e54eb858f1c0d94621b71ae70fce
2019-11-15 07:22:51 -08:00
Joe Susnick d8f56744e4 CI Improvements (#1112)
Summary:
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1112

Updates the Swift kits release job to use carthage for building. This is convenient because it allows us to include more architecture slices with less code. See:
https://github.com/facebook/facebook-ios-sdk/issues/1107

Also updates jazzy to take advantage of improvements to mixed Swift and ObjC projects. See:
https://github.com/realm/jazzy/releases/tag/v0.12.0

Reviewed By: jingping2015

Differential Revision: D18483488

fbshipit-source-id: ed989086d6b64f78b9818d0407473300537ad7e5
2019-11-14 17:37:13 -08:00
joesusnick d51be290ea Making it easier to run unit tests (#1095)
Summary:
Thanks for proposing a pull request!

To help us review the request, please complete the following:

- [x] sign [contributor license agreement](https://developers.facebook.com/opensource/cla)
- [x] I've ensured that all existing tests pass and added tests (when/where necessary)
- [x] I've updated the documentation (when/where necessary) and [Changelog](CHANGELOG.md) (when/where necessary)
- [x] I've added the proper label to this pull request (e.g. `bug` for bug fixes)

## Pull Request Details

Before the unit tests were building the Swift Targets. This meant that trying to run tests on the shared dynamic schemes did not work.

It makes more sense to add unit tests later that are specifically targeting the added Swift functionality and that are associated with the Swift targets.

Once we drop support for Xcode 10.2 this distinction can be erased but for now it's a better experience to be able to easily run the tests for the target being worked on.
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1095

Test Plan:
Open workspace in Xcode. Run the unit tests for the schemes:
FBSDKCoreKit-Dynamic
FBSDKLoginKit-Dynamic
FBSDKShareKit-Dynamic

Reviewed By: jingping2015

Differential Revision: D18307413

Pulled By: joesus

fbshipit-source-id: c55829eae42ec350aee2fd54267aa1c20cdc6937
2019-11-05 18:49:37 -08:00
Joe Susnick 4c463cdfa4 Adding SPM test job to Travis (#1091)
Summary:
Pull Request resolved: https://github.com/facebook/facebook-ios-sdk/pull/1091

We should make sure that new code does not break the Swift packages.

Reviewed By: jingping2015

Differential Revision: D18248148

fbshipit-source-id: 05064bd1ea3d7bfd60ad82d6c184b559871ff9e8
2019-10-31 18:28:56 -07:00
Joe Susnick 22c96898c5 Remove Carthage support for Swift.
Summary: Supporting carthage requires messy workarounds that are not worth the effort and confusion. These libraries are uploaded to the release and can be consumed from there. They can also be consumed by cocoapods and in the future also Swift Package Manager.

Reviewed By: dreamolight

Differential Revision: D17729833

fbshipit-source-id: 6863ada36128ef566e4a1af86e9c3f8468acbb7d
2019-10-03 08:43:39 -07:00
Stan Wu d27b2282c1 Fix doc update script
Summary: The script used to try to upload reference doc before it gets generated which actually did nothing.

Reviewed By: joesus

Differential Revision: D17728818

fbshipit-source-id: 448214cde306cf6765fb11d705c8c54c89ef0e38
2019-10-02 16:58:15 -07:00