This repository has been archived by the owner on Oct 5, 2019. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Kate Lee
committed
Dec 14, 2017
0 parents
commit b6eb49d
Showing
1,949 changed files
with
230,553 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
.DS_Store | ||
__RELEASES__ | ||
bin/ | ||
|
||
# Xcode | ||
build/ | ||
DerivedData | ||
dist | ||
*.xccheckout | ||
*.xcuserdatad | ||
*.xcuserstate | ||
project.xcworkspace/ | ||
xcuserdata/ | ||
*.o | ||
*.Plo | ||
*.lo | ||
config.log | ||
config.status | ||
*.xcscmblueprint | ||
|
||
*.gcda | ||
*.gcno | ||
|
||
!**/Carthage/Build | ||
Artifacts | ||
DemoApp/Config.xcconfig | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
# How to Contribute | ||
|
||
We welcome your contributions to improve the SDKs — whether adding new features, creating your own framework that uses Twitter Kit, or fixing bugs you find in the code. We'd love to work with you so that Twitter Kit grows with your needs. | ||
|
||
If you have anything you'd like to contribute, we recommend discussing it with the core team before writing it. | ||
|
||
## Workflow | ||
|
||
The workflow that we support: | ||
|
||
1. Fork twitter-kit-ios | ||
2. Check out the `master` branch | ||
3. Make a feature branch | ||
4. Make your cool new feature or bugfix on your branch | ||
5. Write a test for your change | ||
6. From your branch, make a pull request against `twitter/twitter-kit-ios/master` | ||
7. Work with repo maintainers to get your change reviewed | ||
8. Wait for your change to be merged internally by staff | ||
9. Delete your feature branch | ||
|
||
## Testing | ||
|
||
We've written unit tests in both TwitterKit and TwitterCore. Running them on XCode will perform the needed tests. | ||
|
||
## Styleguide | ||
|
||
* checkstyle and lint will be used to help enforce code style. | ||
|
||
### iOS Style Guide | ||
https://developer.apple.com/library/content/documentation/Cocoa/Conceptual/CodingGuidelines/CodingGuidelines.html | ||
|
||
See style guide, in particular, when documenting methods: | ||
|
||
* Use 3rd person (descriptive) not 2nd person (prescriptive). | ||
* Method descriptions begin with a verb phrase. | ||
* Add description beyond the API name. | ||
* Avoid descriptions that say nothing beyond what you know from reading the method name. | ||
|
||
|
||
### Git Commit Message Style Guide | ||
http://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html | ||
|
||
http://who-t.blogspot.de/2009/12/on-commit-messages.html | ||
|
||
* Commit message should describe why the change is being made with a high level overview of significant changes made. | ||
|
||
* The first line of commit message should be no more than 65 characters long. This should be a short summary of your commit. Wrap subsequent lines to 80 columns. | ||
|
||
* Write commit message in the imperative: "Fix bug" and not "Fixed bug" | ||
or "Fixes bug." This convention matches up with commit messages generated | ||
by commands like git merge and git revert. | ||
|
||
## Code Review | ||
|
||
The twitter-kit-ios repository on GitHub is kept in sync with an internal repository at | ||
Twitter. For the most part this process should be transparent to twitter-kit-ios users, | ||
but it does have some implications for how pull requests are merged into the | ||
codebase. | ||
|
||
When you submit a pull request on GitHub, it will be reviewed by the | ||
twitter-kit-ios community (both inside and outside of Twitter), and once the changes are | ||
approved, your commits will be brought into the internal system for additional | ||
testing. Once the changes are merged internally, they will be pushed back to | ||
GitHub with the next release. | ||
|
||
This process means that the pull request will not be merged in the usual way. | ||
Instead a member of the twitter-kit-ios team will post a message in the pull request | ||
thread when your changes have made their way back to GitHub, and the pull | ||
request will be closed. The changes | ||
in the pull request will be collapsed into a single commit, but the authorship | ||
metadata will be preserved. | ||
|
||
Please let us know if you have any questions about this process! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
// | ||
// Config.xcconfig | ||
// DemoApp | ||
// | ||
// Copyright © 2017 Twitter. All rights reserved. | ||
// | ||
|
||
TWITTER_CONSUMER_KEY = EDIT_THIS | ||
TWITTER_CONSUMER_SECRET = EDIT_THIS | ||
MOPUB_AD_UNIT_ID = EDIT_THIS |
Large diffs are not rendered by default.
Oops, something went wrong.
130 changes: 130 additions & 0 deletions
130
DemoApp/DemoApp.xcodeproj/xcshareddata/xcschemes/DemoApp.xcscheme
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,130 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<Scheme | ||
LastUpgradeVersion = "0830" | ||
version = "1.3"> | ||
<BuildAction | ||
parallelizeBuildables = "YES" | ||
buildImplicitDependencies = "YES"> | ||
<BuildActionEntries> | ||
<BuildActionEntry | ||
buildForTesting = "YES" | ||
buildForRunning = "YES" | ||
buildForProfiling = "YES" | ||
buildForArchiving = "YES" | ||
buildForAnalyzing = "YES"> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "379A6CA61E95B47300625984" | ||
BuildableName = "DemoApp.app" | ||
BlueprintName = "DemoApp" | ||
ReferencedContainer = "container:DemoApp.xcodeproj"> | ||
</BuildableReference> | ||
</BuildActionEntry> | ||
</BuildActionEntries> | ||
</BuildAction> | ||
<TestAction | ||
buildConfiguration = "Debug" | ||
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" | ||
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" | ||
language = "" | ||
shouldUseLaunchSchemeArgsEnv = "YES"> | ||
<Testables> | ||
<TestableReference | ||
skipped = "NO"> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "9D5A922B1AAA89730039EFCC" | ||
BuildableName = "TwitterCoreTests.xctest" | ||
BlueprintName = "TwitterCoreTests" | ||
ReferencedContainer = "container:../TwitterCore/TwitterCore.xcodeproj"> | ||
</BuildableReference> | ||
</TestableReference> | ||
<TestableReference | ||
skipped = "NO"> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "A966541318EB687000B61CEE" | ||
BuildableName = "TwitterKitTests.xctest" | ||
BlueprintName = "TwitterKit Tests" | ||
ReferencedContainer = "container:../TwitterKit/TwitterKit.xcodeproj"> | ||
</BuildableReference> | ||
</TestableReference> | ||
<TestableReference | ||
skipped = "NO"> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "379A6CC21E95B47300625984" | ||
BuildableName = "DemoAppTests.xctest" | ||
BlueprintName = "DemoAppTests" | ||
ReferencedContainer = "container:DemoApp.xcodeproj"> | ||
</BuildableReference> | ||
</TestableReference> | ||
</Testables> | ||
<MacroExpansion> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "379A6CA61E95B47300625984" | ||
BuildableName = "DemoApp.app" | ||
BlueprintName = "DemoApp" | ||
ReferencedContainer = "container:DemoApp.xcodeproj"> | ||
</BuildableReference> | ||
</MacroExpansion> | ||
<AdditionalOptions> | ||
</AdditionalOptions> | ||
</TestAction> | ||
<LaunchAction | ||
buildConfiguration = "Debug" | ||
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" | ||
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" | ||
language = "" | ||
launchStyle = "0" | ||
useCustomWorkingDirectory = "NO" | ||
ignoresPersistentStateOnLaunch = "NO" | ||
debugDocumentVersioning = "YES" | ||
debugServiceExtension = "internal" | ||
allowLocationSimulation = "YES"> | ||
<BuildableProductRunnable | ||
runnableDebuggingMode = "0"> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "379A6CA61E95B47300625984" | ||
BuildableName = "DemoApp.app" | ||
BlueprintName = "DemoApp" | ||
ReferencedContainer = "container:DemoApp.xcodeproj"> | ||
</BuildableReference> | ||
</BuildableProductRunnable> | ||
<EnvironmentVariables> | ||
<EnvironmentVariable | ||
key = "OS_ACTIVITY_MODE" | ||
value = "disable" | ||
isEnabled = "YES"> | ||
</EnvironmentVariable> | ||
</EnvironmentVariables> | ||
<AdditionalOptions> | ||
</AdditionalOptions> | ||
</LaunchAction> | ||
<ProfileAction | ||
buildConfiguration = "Release" | ||
shouldUseLaunchSchemeArgsEnv = "YES" | ||
savedToolIdentifier = "" | ||
useCustomWorkingDirectory = "NO" | ||
debugDocumentVersioning = "YES"> | ||
<BuildableProductRunnable | ||
runnableDebuggingMode = "0"> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "379A6CA61E95B47300625984" | ||
BuildableName = "DemoApp.app" | ||
BlueprintName = "DemoApp" | ||
ReferencedContainer = "container:DemoApp.xcodeproj"> | ||
</BuildableReference> | ||
</BuildableProductRunnable> | ||
</ProfileAction> | ||
<AnalyzeAction | ||
buildConfiguration = "Debug"> | ||
</AnalyzeAction> | ||
<ArchiveAction | ||
buildConfiguration = "Release" | ||
revealArchiveInOrganizer = "YES"> | ||
</ArchiveAction> | ||
</Scheme> |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
// | ||
// AppDelegate.h | ||
// DemoApp | ||
// | ||
// Created by Steven Hepting on 4/5/17. | ||
// Copyright © 2017 Twitter. All rights reserved. | ||
// | ||
|
||
#import <UIKit/UIKit.h> | ||
|
||
@interface AppDelegate : UIResponder <UIApplicationDelegate> | ||
|
||
@property (strong, nonatomic) UIWindow *window; | ||
|
||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
// | ||
// AppDelegate.m | ||
// DemoApp | ||
// | ||
// Created by Steven Hepting on 4/5/17. | ||
// Copyright © 2017 Twitter. All rights reserved. | ||
// | ||
|
||
#import "AppDelegate.h" | ||
#import <DCIntrospect_ARC/DCIntrospect.h> | ||
#import <FLEX/FLEX.h> | ||
#import <TwitterKit/TWTRKit.h> | ||
#import "DemoApp-Swift.h" | ||
|
||
@interface AppDelegate () | ||
|
||
@end | ||
|
||
@implementation AppDelegate | ||
|
||
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions | ||
{ | ||
NSDictionary *info = [[NSBundle mainBundle] infoDictionary]; | ||
NSString *twitterConsumerKey = [info objectForKey:@"TwitterConsumerKey"]; | ||
NSString *twitterConsumerSecret = [info objectForKey:@"TwitterConsumerSecret"]; | ||
|
||
[[Twitter sharedInstance] startWithConsumerKey:twitterConsumerKey consumerSecret:twitterConsumerSecret]; | ||
|
||
self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]]; | ||
self.window.rootViewController = [[RootViewController alloc] init]; | ||
self.window.backgroundColor = [UIColor whiteColor]; | ||
[self.window makeKeyAndVisible]; | ||
|
||
#if TARGET_IPHONE_SIMULATOR | ||
[[DCIntrospect sharedIntrospector] start]; | ||
#endif | ||
|
||
return YES; | ||
} | ||
|
||
- (BOOL)application:(UIApplication *)app openURL:(NSURL *)url options:(NSDictionary<NSString *, id> *)options | ||
{ | ||
return [[Twitter sharedInstance] application:app openURL:url options:options]; | ||
} | ||
|
||
- (void)applicationWillResignActive:(UIApplication *)application | ||
{ | ||
// Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state. | ||
// Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game. | ||
} | ||
|
||
- (void)applicationDidEnterBackground:(UIApplication *)application | ||
{ | ||
// Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later. | ||
// If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. | ||
} | ||
|
||
- (void)applicationWillEnterForeground:(UIApplication *)application | ||
{ | ||
// Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background. | ||
} | ||
|
||
- (void)applicationDidBecomeActive:(UIApplication *)application | ||
{ | ||
// Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface. | ||
} | ||
|
||
- (void)applicationWillTerminate:(UIApplication *)application | ||
{ | ||
// Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. | ||
} | ||
|
||
@end |
Oops, something went wrong.